Message ID | CAPgLHd8WBR38qd9VHfazXVTbuoJ=GPOafHzSz8d9XJ-F61a7nQ@mail.gmail.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Am Dienstag, 17. Dezember 2013, 04:27:16 schrieb Wei Yongjun: > From: Wei Yongjun <yongjun_wei@trendmicro.com.cn> > > 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 <yongjun_wei@trendmicro.com.cn> Thanks for the catch. Acked-by: Heiko Stuebner <heiko@sntech.de> -- To unsubscribe from this list: send the line "unsubscribe linux-input" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
On Tue, Dec 17, 2013 at 04:06:49PM +0100, Heiko Stübner wrote: > Am Dienstag, 17. Dezember 2013, 04:27:16 schrieb Wei Yongjun: > > From: Wei Yongjun <yongjun_wei@trendmicro.com.cn> > > > > 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 <yongjun_wei@trendmicro.com.cn> > > Thanks for the catch. > > Acked-by: Heiko Stuebner <heiko@sntech.de> Applied, thank you.
diff --git a/drivers/input/touchscreen/zforce_ts.c b/drivers/input/touchscreen/zforce_ts.c index aa127ba..2175f34 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; }