Skip to contentSkip to conversation

radio/radio-aimslab: replace

PATCH New Nishanth Aravamudan 1 participant 1 message Jul 26, 2004

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 radio/radio-aimslab: replace

I would appreciate any comments from the janitors list.

Thanks,
Nish

Applys-to: 2.6.7

Description: Uses msleep() instead of a while-loop and schedule(). Thus the CPU is given up for the time desired.

drivers/media/radio/radio-aimslab.c +1 -6
@@ -63,12 +63,7 @@ static void sleep_delay(long n)
 	if(!d)
 		udelay(n);
 	else
-	{
-		/* Yield CPU time */
-		unsigned long x=jiffies;
-		while((jiffies-x)<=d)
-			schedule();
-	}
+		msleep(jiffies_to_msecs(d));
 }
 
 static void rt_decvol(void)

_______________________________________________
Kernel-janitors mailing list
[email protected]
http://lists.osdl.org/mailman/listinfo/kernel-janitors