Re: flock(fd, LOCK_UN) taking 500ms+ ?

Robert Love (rml@tech9.net)
02 Oct 2002 15:10:29 -0400


On Wed, 2002-10-02 at 14:58, John Levon wrote:

> How will cond_resched() work ? Surely that will only give a chance if
> the current process has reached the end of its timeslice (need_resched)
> ? Isn't "schedule()" the right thing here ?

need_resched is set whenever there is a higher priority process that is
now runnable (it is set on wake_up()). Otherwise cond_resched() would
be fairly worthless.. and kernel preemption, etc.

Robert Love

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