Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit bc34496d authored by Roel Kluin's avatar Roel Kluin Committed by Dmitry Torokhov
Browse files

Input: pxa930_trkball - fix write timeout handling



With a postfix decrement i reaches -1 rather than 0,
but after the loop it is tested whether it has become 0.

Signed-off-by: default avatarRoel Kluin <roel.kluin@gmail.com>
Signed-off-by: default avatarDmitry Torokhov <dtor@mail.ru>
parent 4e8718a1
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -83,7 +83,7 @@ static int write_tbcr(struct pxa930_trkball *trkball, int v)

	__raw_writel(v, trkball->mmio_base + TBCR);

	while (i--) {
	while (--i) {
		if (__raw_readl(trkball->mmio_base + TBCR) == v)
			break;
		msleep(1);