Subject: Re: SMP re-entrancy in kernel drivers/"bottom half?"
To: None <firstname.lastname@example.org>
From: YAMAMOTO Takashi <email@example.com>
Date: 12/18/2003 08:21:07
> Elementary: we have to maintain the invariant ``at most one CPU at or
> above any given [hardware] prioritly level' or we lose the
> synchronization semantics of SPLs (higher SPls than the hypothetical
> SMP-safe interrupt-routine driver entrypoints).
are you suggesting a "global" SPL? (ie. not per cpu)
> Suppose a NIC interrupt fires, a CPU takes an interrupt and goes into
> a network driver at IPL_NET. Suppose a disk driver fires, goes into
> the kernel at IPL_BIO. Now suppose both of those drivers wants to go
> to splvm() or splhigh(), or ..., to access some data-structure
> synchronized at that level.
> Thats the appeal of this idea. A truly fine-grained-SMP kernel would
> have separate locks for each such data structure, or at least per
> kernel subsystem. By making hardware-priority SPLs acquire a
> spinlock, we can try allowing multiple bottom-half drivers into the
> kernel simultaneously, yet defer implementing the spinlocks for all
> those other data structures to some later date.
how bottom-half drivers works simultaneously while all of them
need to acquire the spinlock corresponding to the lowest SPL?
why not just acquire kernel_lock when accessing the subsystem without
fine grained locks?