HEADS UP/STATUS: network locking

From: Sam Leffler <sam_at_errno.com>
Date: Fri, 05 Sep 2003 16:57:00 -0700
I've committed a number of changes to lock the "middlware" parts of the
network subsystem.  There's still more to come; I'm moving slowly to insure
each batch gets exposure.  All the pending changes can be found at:

http://www.freebsd.org/~sam

The major changes that will go in next week are: bridge, dummynet, ipfw,
multicast routing (mroute), and the routing table (rtentry).  I've been
running with all these mods on a variety of machines (desktop, NFS server,
laptop, firewall) for weeks but testing everything is difficult so don't be
surprised if you encounter issues like lock order reversals.  Each patch is
pretty much independent so if you regularly use say dummynet then it would
be useful to try the patch and send me feedback.

In the above directory you'll also find the first tangible benefit of this
work: netisr.patch contains changes to "push Giant up" one level.  Note
however that unless the network drivers mark their interrupt handlers
MPSAFE you're not really going to exercise the locking.  I've been running
em, sis, fxp, wi, and ath drivers this way for several months with no ill
effects (except for a problem running Atheros hardware in HostAP mode).
Many other drivers are locked and appear ready to run MPSAFE.

Shortly I'll have Giant pushed all the way up through the INET protocols.
When that happens it'll be time to remove Giant from the socket layer and
lock IPv6 and UNIX domain sockets.  At some point we'll need to switch over
to a non-Giant top half; at that point drivers and protocols that are not
properly locked will need help or be left behind.

Note that the current plan is to NOT commit any changes to remove Giant
from the socket layer until after 5.2.  Folks interested in trying this
stuff will need to track the work in perforce or apply patches that I'll
make available at "stable points".

If folks want to talk about this work at BSDCon I'll be around Wed-Fri.
I'll also be at the developers summit on Saturday.

	Sam
Received on Fri Sep 05 2003 - 14:57:08 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:37:21 UTC