|
@@ -220,7 +220,7 @@ static inline void wait_for_idle(struct rockchip_spi *rs)
|
|
|
do {
|
|
do {
|
|
|
if (!(readl_relaxed(rs->regs + ROCKCHIP_SPI_SR) & SR_BUSY))
|
|
if (!(readl_relaxed(rs->regs + ROCKCHIP_SPI_SR) & SR_BUSY))
|
|
|
return;
|
|
return;
|
|
|
- } while (time_before(jiffies, timeout));
|
|
|
|
|
|
|
+ } while (!time_after(jiffies, timeout));
|
|
|
|
|
|
|
|
dev_warn(rs->dev, "spi controller is in busy state!\n");
|
|
dev_warn(rs->dev, "spi controller is in busy state!\n");
|
|
|
}
|
|
}
|