Re: [PATCH for 2.5] preemptible kernel

Keith Owens
2001-03-21T09:06:02Z

On Wed, 21 Mar 2001 00:04:56 -0800,
george anzinger <george@mvista.com> wrote:
>Exactly so. The method does not depend on the sum of preemption being
>zip, but on each potential reader (writers take locks) passing thru a
>"sync point". Your notion of waiting for each task to arrive
>"naturally" at schedule() would work. It is, in fact, over kill as you
>could also add arrival at sys call exit as a (the) "sync point". In
>fact, for module unload, isn't this the real "sync point"? After all, a
>module can call schedule, or did I miss a usage counter somewhere?

A module can call schedule but it must do MOD_INC_USE_COUNT first.
Sleeping in module code without incrementing the module use count first
is a shooting offence. It is so full of races that you may as well
call it Daytona.

>By the way, there is a paper on this somewhere on the web. Anyone
>remember where?