image->lock is unlocked in some error handling path without take the
lock, so remove those unexpected unlock.
Fixes:
658bcdae9c67 ("vme: Adding Fake VME driver")
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
}
if (size & 0xFFFF) {
- spin_unlock(&image->lock);
pr_err("Invalid size alignment\n");
retval = -EINVAL;
goto err_window;
case VME_D32:
break;
default:
- spin_unlock(&image->lock);
pr_err("Invalid data width\n");
retval = -EINVAL;
goto err_dwidth;
case VME_USER4:
break;
default:
- spin_unlock(&image->lock);
pr_err("Invalid address space\n");
retval = -EINVAL;
goto err_aspace;