cvs commit: src/sys/net if.c if.h if_ethersubr.c if_var.h
src/sys/net80211 ieee80211_output.c ieee80211_proto.c
Robert Watson
rwatson at FreeBSD.org
Tue Jul 27 16:20:46 PDT 2004
rwatson 2004-07-27 23:20:45 UTC
FreeBSD src repository
Modified files:
sys/net if.c if.h if_ethersubr.c if_var.h
sys/net80211 ieee80211_output.c ieee80211_proto.c
Log:
Add a new network interface flag, IFF_NEEDSGIANT, which will allow
device drivers to declare that the ifp->if_start() method implemented
by the driver requires Giant in order to operate correctly.
Add a 'struct task' to 'struct ifnet' that can be used to execute a
deferred ifp->if_start() in the event that if_start needs to be called
in a Giant-free environment. To do this, introduce if_start(), a
wrapper function for ifp->if_start(). If the interface can run MPSAFE,
it directly dispatches into the interface start routine. If it can't
run MPSAFE, we're running with debug.mpsafenet != 0, and Giant isn't
currently held, the task is queued to execute in a swi holding Giant
via if_start_deferred().
Modify if_handoff() to use if_start() instead of direct dispatch.
Modify 802.11 to use if_start() instead of direct dispatch.
This is intended to provide increased compatibility for non-MPSAFE
network device drivers in the presence of Giant-free operation via
asynchronous dispatch. However, this commit does not mark any network
interfaces as IFF_NEEDSGIANT.
Revision Changes Path
1.197 +49 -0 src/sys/net/if.c
1.88 +1 -0 src/sys/net/if.h
1.177 +2 -0 src/sys/net/if_ethersubr.c
1.82 +6 -2 src/sys/net/if_var.h
1.11 +1 -1 src/sys/net80211/ieee80211_output.c
1.9 +1 -1 src/sys/net80211/ieee80211_proto.c
More information about the cvs-src
mailing list