Commit 3b5005e9 authored by Dan Carpenter's avatar Dan Carpenter Committed by Dmitry Torokhov

Input: lm8323 - missing error check in lm8323_set_disable()

The missing error handling here is not especially harmful but static
checkers complain that "i" can be used uninitialized.
Signed-off-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: default avatarDmitry Torokhov <dmitry.torokhov@gmail.com>
parent 939ffb17
...@@ -616,6 +616,8 @@ static ssize_t lm8323_set_disable(struct device *dev, ...@@ -616,6 +616,8 @@ static ssize_t lm8323_set_disable(struct device *dev,
unsigned int i; unsigned int i;
ret = kstrtouint(buf, 10, &i); ret = kstrtouint(buf, 10, &i);
if (ret)
return ret;
mutex_lock(&lm->lock); mutex_lock(&lm->lock);
lm->kp_enabled = !i; lm->kp_enabled = !i;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment