linux-input.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] Input: rohm_bu21023 - fix handling of retrying firmware update
@ 2016-01-06 22:51 Dmitry Torokhov
  2016-01-07 10:11 ` Yuasa Yoichi
  0 siblings, 1 reply; 2+ messages in thread
From: Dmitry Torokhov @ 2016-01-06 22:51 UTC (permalink / raw)
  To: linux-input; +Cc: Yoichi Yuasa, linux-kernel

Because of the wrong condition we'd never retry firmware update.

Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
---
 drivers/input/touchscreen/rohm_bu21023.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/input/touchscreen/rohm_bu21023.c b/drivers/input/touchscreen/rohm_bu21023.c
index ba6024f..611156a 100644
--- a/drivers/input/touchscreen/rohm_bu21023.c
+++ b/drivers/input/touchscreen/rohm_bu21023.c
@@ -725,7 +725,7 @@ static int rohm_ts_load_firmware(struct i2c_client *client,
 			break;
 
 		error = -EIO;
-	} while (++retry >= FIRMWARE_RETRY_MAX);
+	} while (++retry <= FIRMWARE_RETRY_MAX);
 
 out:
 	error2 = i2c_smbus_write_byte_data(client, INT_MASK, INT_ALL);
-- 
2.6.0.rc2.230.g3dd15c0


-- 
Dmitry

^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2016-01-07 10:11 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-01-06 22:51 [PATCH] Input: rohm_bu21023 - fix handling of retrying firmware update Dmitry Torokhov
2016-01-07 10:11 ` Yuasa Yoichi

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).