mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-27 11:19:37 +00:00
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: Roel Kluin <roel.kluin@gmail.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
This commit is contained in:
parent
4e8718a1f9
commit
bc34496d63
1 changed files with 1 additions and 1 deletions
|
@ -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);
|
||||
|
|
Loading…
Reference in a new issue