From: Jaewon Kim Date: Thu, 16 Oct 2014 20:56:52 +0000 (-0700) Subject: Input: max77693-haptic - fix state check in imax77693_haptic_disable() X-Git-Tag: v4.14-rc1~3851^2~151 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=135d916fe8a5fa25ad87a62844acfd3dbb1c9fb9;p=platform%2Fkernel%2Flinux-rpi.git Input: max77693-haptic - fix state check in imax77693_haptic_disable() The check to see whether the device is already disabled in max77693_haptic_disable() was inversed, this change corrects it. Signed-off-by: Jaewon Kim Reviewed-by: Chanwoo Choi Signed-off-by: Dmitry Torokhov --- diff --git a/drivers/input/misc/max77693-haptic.c b/drivers/input/misc/max77693-haptic.c index d605db4d2f39..7b1fde93799e 100644 --- a/drivers/input/misc/max77693-haptic.c +++ b/drivers/input/misc/max77693-haptic.c @@ -152,7 +152,7 @@ static void max77693_haptic_disable(struct max77693_haptic *haptic) { int error; - if (haptic->enabled) + if (!haptic->enabled) return; error = max77693_haptic_configure(haptic, false);