提交 bc34496d 编写于 作者: R Roel Kluin 提交者: Dmitry Torokhov

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: NRoel Kluin <roel.kluin@gmail.com>
Signed-off-by: NDmitry Torokhov <dtor@mail.ru>
上级 4e8718a1
......@@ -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);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册