Hi,
 
I have  a kernel thread which needs to be woke-up every 50 mili seconds (un-conditionaly) to be used as
a periodic timer
 
The kernel version I am using is 2.4.18 .
 
I have made a small research and found 2 possibilities:
schedule_timeout
interruptible_sleep_on_timeout.
 
I made some experiements with both of them , and under a medium load (24Mbit) , it seems that
the interruptible is more accurate. The schedule has deviation of several miliseconds  every
50/100 samples (I totally took a batch of 150 samples - each sample is a 50 mili interval ).
The interruptible_sleep, has also that deviation , but less frequent (once per batch), and the overall
picture shows that it is more accurate.
 
On the other hand, I have read that the interruptible_sleep is less stable and gets into race conditions.
The question is : Did everyone tried to work with both of those APIs? If the interruptible_sleep is called unconditionaly , does it still un-recommended for use ?
 
I appreciate any info
 
Chava

Reply via email to