{rtasd,rtc,scanlog}.c schedule_timeout() usage

Nishanth Aravamudan nacc at us.ibm.com
Tue Dec 21 12:20:17 EST 2004


On Tue, Dec 21, 2004 at 11:55:35AM +1100, Anton Blanchard wrote:
>  
> Hi,
> 
> > It seems to me, though, that if you really don't want to deal with
> > signals & you really intend to sleep the full second (in rtasd.c, for
> > instance), then it makes perfect sense to use TASK_UNINTERRUPTIBLE
> > (i.e. msleep). Yes it will count to loadavg, but that doesn't mean the
> > code is wrong (maybe the calculation of loadavg is incorrect?).
> > Because the only the thing the task is doing in TASK_UNINTERRUPTIBLE
> > is doing is sleeping. Meaning that while loadavg may go up (by 1 for
> > each TASK_UNINTERRUPTIBLE task?), the CPU stays at idle.
> 
> I agree we dont want to handle signals but having an idle machine at 
> a load average of 1 would be confusing.

Hmm, would you prefer then, having the code block all signals before (and then
restoring them after) the sleep?

-Nish



More information about the Linuxppc64-dev mailing list