aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/spi/pxa2xx_spi.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/spi/pxa2xx_spi.c b/drivers/spi/pxa2xx_spi.c
index 1a00b415bcc4..885194a07418 100644
--- a/drivers/spi/pxa2xx_spi.c
+++ b/drivers/spi/pxa2xx_spi.c
@@ -213,7 +213,7 @@ static int flush(struct driver_data *drv_data)
213 while (read_SSSR(reg) & SSSR_RNE) { 213 while (read_SSSR(reg) & SSSR_RNE) {
214 read_SSDR(reg); 214 read_SSDR(reg);
215 } 215 }
216 } while ((read_SSSR(reg) & SSSR_BSY) && limit--); 216 } while ((read_SSSR(reg) & SSSR_BSY) && --limit);
217 write_SSSR(SSSR_ROR, reg); 217 write_SSSR(SSSR_ROR, reg);
218 218
219 return limit; 219 return limit;
@@ -484,7 +484,7 @@ static int wait_ssp_rx_stall(void const __iomem *ioaddr)
484{ 484{
485 unsigned long limit = loops_per_jiffy << 1; 485 unsigned long limit = loops_per_jiffy << 1;
486 486
487 while ((read_SSSR(ioaddr) & SSSR_BSY) && limit--) 487 while ((read_SSSR(ioaddr) & SSSR_BSY) && --limit)
488 cpu_relax(); 488 cpu_relax();
489 489
490 return limit; 490 return limit;
@@ -494,7 +494,7 @@ static int wait_dma_channel_stop(int channel)
494{ 494{
495 unsigned long limit = loops_per_jiffy << 1; 495 unsigned long limit = loops_per_jiffy << 1;
496 496
497 while (!(DCSR(channel) & DCSR_STOPSTATE) && limit--) 497 while (!(DCSR(channel) & DCSR_STOPSTATE) && --limit)
498 cpu_relax(); 498 cpu_relax();
499 499
500 return limit; 500 return limit;