]> git.baikalelectronics.ru Git - kernel.git/commit
spi: limit reaches -1, tested 0
authorRoel Kluin <roel.kluin@gmail.com>
Tue, 7 Apr 2009 02:00:54 +0000 (19:00 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Tue, 7 Apr 2009 15:31:07 +0000 (08:31 -0700)
commit20f46f680e63dc5b064113d9a9e901e4e63e8dd6
tree1520389a952ea5f9d624f06d054b7d68f5802b2f
parent7dd38b35f09c6b3f14eabd4baf86d3a1c81ca129
spi: limit reaches -1, tested 0

With a postfix decrement limit will reach -1 rather than 0, so the warning
will not be issued.

Also, add a cpu_relax() into the busy-wait loop.

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Cc: Mariusz Ceier <mceier@gmail.com>
Acked-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
drivers/spi/spi_imx.c