aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/input/misc
diff options
context:
space:
mode:
authorDmitry Torokhov <dmitry.torokhov@gmail.com>2014-01-03 20:54:37 -0800
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2014-02-12 15:09:40 -0800
commitad7647d92f61c6e78bf6dc3804da1e2acf0515b6 (patch)
treed925b6b3719d97b012a2d51a11b6c7473cd1175e /drivers/input/misc
parentInput: uinput - add UI_GET_SYSNAME ioctl to retrieve the sysfs path (diff)
downloadlinux-dev-ad7647d92f61c6e78bf6dc3804da1e2acf0515b6.tar.xz
linux-dev-ad7647d92f61c6e78bf6dc3804da1e2acf0515b6.zip
Input: ims-pcu - fix error unwinding path in application mode
We first create backlight and then input devices so we should destroy them in opposite order when handling errors. Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Diffstat (limited to 'drivers/input/misc')
-rw-r--r--drivers/input/misc/ims-pcu.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/input/misc/ims-pcu.c b/drivers/input/misc/ims-pcu.c
index e204f26b0011..5e8e90260037 100644
--- a/drivers/input/misc/ims-pcu.c
+++ b/drivers/input/misc/ims-pcu.c
@@ -1674,10 +1674,10 @@ static int ims_pcu_init_application_mode(struct ims_pcu *pcu)
return 0;
-err_destroy_backlight:
- ims_pcu_destroy_backlight(pcu);
err_destroy_buttons:
ims_pcu_destroy_buttons(pcu);
+err_destroy_backlight:
+ ims_pcu_destroy_backlight(pcu);
return error;
}