From: Wei Yongjun Date: Wed, 16 Oct 2013 06:37:44 +0000 (-0700) Subject: Input: nspire-keypad - add missing clk_disable_unprepare() on error path X-Git-Tag: v3.13-rc7~9^2~14^2~18 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=a4da47527d9f2e19a66527379418a5d13de9fff1;p=kernel%2Fkernel-generic.git Input: nspire-keypad - add missing clk_disable_unprepare() on error path Add the missing clk_disable_unprepare() before return from nspire_keypad_open() in the error handling case. Signed-off-by: Wei Yongjun Signed-off-by: Dmitry Torokhov --- diff --git a/drivers/input/keyboard/nspire-keypad.c b/drivers/input/keyboard/nspire-keypad.c index 9981928..b310649 100644 --- a/drivers/input/keyboard/nspire-keypad.c +++ b/drivers/input/keyboard/nspire-keypad.c @@ -143,8 +143,10 @@ static int nspire_keypad_open(struct input_dev *input) return error; error = nspire_keypad_chip_init(keypad); - if (error) + if (error) { + clk_disable_unprepare(keypad->clk); return error; + } return 0; }