Re: [linux-audio-dev] Re: [announce] [patch] Voluntary Kernel Preemption Patch

Scott Wood
2004-07-22T18:53:57Z

On Thu, Jul 22, 2004 at 09:40:34AM +0200, Ingo Molnar wrote:
> * Scott Wood <scott@timesys.com> wrote:
> > This sort of substitution is what we did in 2.4, though we made this
> > type the default and gave the real spinlocks a new name to be used in
> > those few places where it was really needed. Of course, this resulted
> > in a lot of places using a mutex where a spinlock would have been
> > fine.
>
> what are those few places where a spinlock was really needed?

Places that inherently cannot sleep, such as inside the scheduler,
the unthreadable part of the hard IRQ code, inside the mutex
implementation, etc.

> I'm a bit uneasy about making mutexes the default not due to performance
> but due to e.g. some hardware being very timing-sensitive.

In practice, this didn't turn out to be an issue; most modern
hardware seems to be pretty tolerant of that (and you already have to
deal with things like interrupts getting in the way), and drivers
which do local_irq_disable() or to ensure timing will still work.

Has this sort of problem been seen with RT-Linux and such, which
would cause similar delays?

-Scott