Subject: Re: spl ... MP ...
To: Chapman Flack <nblists@anastigmatix.net>
From: Bill Studenmund <wrstuden@netbsd.org>
List: tech-kern
Date: 01/09/2006 09:57:20
--3MwIy2ne0vdjdPXF
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Sat, Jan 07, 2006 at 03:39:31PM -0500, Chapman Flack wrote:
> >On Sat, 7 Jan 2006, Nathan J. Williams wrote:
>=20
> >>Bottom half:
> >>[already at splfoo]
> >>simplelock();
> >>...
> >>simpleunlock();
>=20
> Now in the midi case, we have an MI driver that can attach to
> a bunch of different hardware transports, or to umidi, so I
> wonder if the first line is
>=20
>   [already at spl??? whatever the underlying HW driver is at,
>    or splusb, or splsoftclock if resulting from a callout]
>=20
> I'd assume that /when the bottom receives control because the
> hardware interrupted/, whatever spl it's already at is sufficient
> to prevent being itself interrupted by the same hardware (say,
> after writing the first of several bytes) - but I'm not sure that
> will be true when it gets control from the callout. At splsoftclock
> it surely won't be able to interrupt the top half (if that's at
> splaudio), but once running it could still be interrupted by itself
> triggered by the real hw. So maybe this bottom half should still
> use splaudio in addition to the simplelock.  Assuming splaudio

Yes.

> really is at least as high as the highest of any of the real
> hardware gizmos we could be attached to. I see it's at least as high
> as all three possible values for splusb ... my head's starting to
> hurt.
>=20
> Should I go ahead and include simplelocks now, or is that just
> stealing the fun of the lucky people who get to audit kernel
> sources whenever the biglock is eliminated?

Feel free to add spinlocks now if you want.

Take care,

Bill

--3MwIy2ne0vdjdPXF
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.3 (NetBSD)

iD8DBQFDwqQAWz+3JHUci9cRAmOZAJ94xVCQ4MxEU3ccYIfJJDUm6+07nQCfbGO0
1F9uIVov/ZILezW+oMdyM9Y=
=Zy0s
-----END PGP SIGNATURE-----

--3MwIy2ne0vdjdPXF--