From: Wei Yongjun Date: Tue, 17 Dec 2013 16:58:18 +0000 (-0800) Subject: Input: zforce - fix error return code in zforce_start() X-Git-Tag: v3.14-rc1~104^2^2~28 X-Git-Url: https://openfabrics.org/gitweb/?a=commitdiff_plain;h=3c4396b434613f653bf95f741a6000e671d1e011;p=~emulex%2Finfiniband.git Input: zforce - fix error return code in zforce_start() The error code was not set if unable to set config, so the error condition wasn't reflected in the return value. Fix to return a negative error code from the error handling case instead of 0. Signed-off-by: Wei Yongjun Acked-by: Heiko Stuebner Signed-off-by: Dmitry Torokhov --- diff --git a/drivers/input/touchscreen/zforce_ts.c b/drivers/input/touchscreen/zforce_ts.c index 75762d6ff3b..4ffe4cc3b23 100644 --- a/drivers/input/touchscreen/zforce_ts.c +++ b/drivers/input/touchscreen/zforce_ts.c @@ -279,7 +279,8 @@ static int zforce_start(struct zforce_ts *ts) goto error; } - if (zforce_setconfig(ts, SETCONFIG_DUALTOUCH)) { + ret = zforce_setconfig(ts, SETCONFIG_DUALTOUCH); + if (ret) { dev_err(&client->dev, "Unable to set config\n"); goto error; }