polling loops: change exit condition to
Subsystems (2)
PATCH 3/21 polling loops: change exit condition to
BLOCK LAYER
P: Jens Axboe
M: [email protected]
Signed-off-by Marcin Slusarz <[email protected]>
drivers/block/sx8.c +3 -2
@@ -570,9 +570,10 @@ static struct carm_request *carm_get_speunsigned long flags;struct carm_request *crq =NULL ;struct request *rq; -int tries =5000 ; +unsigned long end_time; -while (tries-- >0 ) { + end_time = jiffies +msecs_to_jiffies (50000 ); +while (time_before (jiffies, end_time)) {spin_lock_irqsave (&host->lock, flags); crq =carm_get_request (host);spin_unlock_irqrestore (&host->lock, flags);
_______________________________________________
Kernel-janitors mailing list
[email protected]
https://lists.osdl.org/mailman/listinfo/kernel-janitors