lkml.org 
[lkml]   [1999]   [Dec]   [1]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: Q: waiting for a short time and not beeing a resource hog
Date
From
> I do not like the 
>
> while( (jiffies-time_start) < 1 );
>
> since it is too long and blocks the whole cpu from doing sensible stuff.

If its 1/100th of a second or so then its worth delaying using a timer
if this is an irq - add a timer to call the function to read the data. If its
very short times like 50uS or so just use udelay and eat the cost





-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:55    [W:0.377 / U:0.020 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site