summaryrefslogtreecommitdiffstats
path: root/sys/net/if_var.h
diff options
context:
space:
mode:
authorrwatson <rwatson@FreeBSD.org>2009-03-15 14:21:05 +0000
committerrwatson <rwatson@FreeBSD.org>2009-03-15 14:21:05 +0000
commit70b6a8119c02ed07bc12918814c950d358cb1885 (patch)
tree27cbcf88d527d4a8b421eca8e088d73a000fb83f /sys/net/if_var.h
parent0592710988a69ee8c560a0e065d714f7ff578d43 (diff)
downloadFreeBSD-src-70b6a8119c02ed07bc12918814c950d358cb1885.zip
FreeBSD-src-70b6a8119c02ed07bc12918814c950d358cb1885.tar.gz
Remove IFF_NEEDSGIANT, a compatibility infrastructure introduced
in FreeBSD 5.x to allow network device drivers to run with Giant despite the network stack being Giant-free. This significantly simplifies calls into ioctl() on network interfaces, especially in the multicast code, as well as eliminates deferred invocation of interface if_start routines. Disable the build on device drivers still depending on IFF_NEEDSGIANT as they no longer compile. They will be removed in a few weeks if they haven't been made MPSAFE in that time. Disabled drivers: if_ar if_axe if_aue if_cdce if_cue if_kue if_ray if_rue if_rum if_sr if_udav if_ural if_zyd Drivers that were already disabled because of tty changes: if_ppp if_sl Discussed on: arch@
Diffstat (limited to 'sys/net/if_var.h')
-rw-r--r--sys/net/if_var.h11
1 files changed, 0 insertions, 11 deletions
diff --git a/sys/net/if_var.h b/sys/net/if_var.h
index 3ff019f2..7640d78 100644
--- a/sys/net/if_var.h
+++ b/sys/net/if_var.h
@@ -181,7 +181,6 @@ struct ifnet {
void *if_afdata[AF_MAX];
int if_afdata_initialized;
struct rwlock if_afdata_lock;
- struct task if_starttask; /* task for IFF_NEEDSGIANT */
struct task if_linktask; /* task for link change events */
struct mtx if_addr_mtx; /* mutex to protect address lists */
@@ -379,16 +378,6 @@ EVENTHANDLER_DECLARE(group_change_event, group_change_event_handler_t);
#define IF_AFDATA_LOCK_ASSERT(ifp) rw_assert(&(ifp)->if_afdata_lock, RA_LOCKED)
#define IF_AFDATA_UNLOCK_ASSERT(ifp) rw_assert(&(ifp)->if_afdata_lock, RA_UNLOCKED)
-#define IFF_LOCKGIANT(ifp) do { \
- if ((ifp)->if_flags & IFF_NEEDSGIANT) \
- mtx_lock(&Giant); \
-} while (0)
-
-#define IFF_UNLOCKGIANT(ifp) do { \
- if ((ifp)->if_flags & IFF_NEEDSGIANT) \
- mtx_unlock(&Giant); \
-} while (0)
-
int if_handoff(struct ifqueue *ifq, struct mbuf *m, struct ifnet *ifp,
int adjust);
#define IF_HANDOFF(ifq, m, ifp) \
OpenPOWER on IntegriCloud