Skip to contentSkip to conversation

media: tda8083: use time_after_eq() instead of jiffies judgment

PATCH New Qing Wang 1 participant 1 message Feb 10, 2022 Media (V4L/DVB)

lore
Share & tools
lore

Qing Wang

author
#0 lore raw

PATCH 1/1 media: tda8083: use time_after_eq() instead of jiffies judgment

From: Wang Qing <[email protected]>

It is better to use time_xxx() directly instead of jiffies judgment for understanding.

---
 drivers/media/dvb-frontends/tda8083.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/media/dvb-frontends/tda8083.c +1 -1
index 5be11fd..49c4fe1
@@ -162,7 +162,7 @@ static void tda8083_wait_diseqc_fifo (struct tda8083_state* state, int timeout)
 {
 	unsigned long start = jiffies;
 
-	while (jiffies - start < timeout &&
+	while (time_before(jiffies, start + timeout) &&
 	       !(tda8083_readreg(state, 0x02) & 0x80))
 	{
 		msleep(50);
Signature · 1 line
2.7.4