Subject: Re: spl ... MP ...
To: Hubert Feyrer <hubert@feyrer.de>
From: Nathan J. Williams <nathanw@wasabisystems.com>
List: tech-kern
Date: 01/07/2006 15:25:45
Hubert Feyrer <hubert@feyrer.de> writes:

> I think I understand what the SPL levels do for UP systems now.
> In the future, would we get rid of them completely, or continue having
> them in effect for UP systems, while MP operation with proper locking?

You still need them, or something like them. Consider what happens if
the top half locks the spinlock, and then the same CPU gets an
interrupt and tries to take the same lock - instant deadlock, as the
CPU stays at high interrupt level waiting for non-interrupt code which
it isn't allowing to run. A form of priority inversion, really.

There are other ways to rearrange things, like making everything run
in preemptable in-kernel threads of different priorites and making the
locks all adaptive sleep locks (sort of like what Solaris did), but
that's vastly different from where we are now or could reasonably
change into with incremental development.

        - Nathan