diff options
author | green <green@FreeBSD.org> | 2004-10-01 07:01:38 +0000 |
---|---|---|
committer | green <green@FreeBSD.org> | 2004-10-01 07:01:38 +0000 |
commit | d8d12b2198f171b95ad3a6a00fa0c0f9217affc2 (patch) | |
tree | e6d2d1c71d80a0282fcbd98f363d457670ac2790 /sys/dev/dc | |
parent | 2e5b8b98835509cddd3b2345fbdc9d31180a21d9 (diff) | |
download | FreeBSD-src-d8d12b2198f171b95ad3a6a00fa0c0f9217affc2.zip FreeBSD-src-d8d12b2198f171b95ad3a6a00fa0c0f9217affc2.tar.gz |
Conditionalize IFF_NEEDSGIANT, like everything else here, on IS_MPSAFE.
The driver doesn't look any less safe without Giant than with, and works
with IS_MPSAFE set to 1 here, so others should probably test it as such.
Diffstat (limited to 'sys/dev/dc')
-rw-r--r-- | sys/dev/dc/if_dc.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/dev/dc/if_dc.c b/sys/dev/dc/if_dc.c index 262e947..961c49d 100644 --- a/sys/dev/dc/if_dc.c +++ b/sys/dev/dc/if_dc.c @@ -2191,8 +2191,9 @@ dc_attach(device_t dev) if_initname(ifp, device_get_name(dev), device_get_unit(dev)); /* XXX: bleah, MTU gets overwritten in ether_ifattach() */ ifp->if_mtu = ETHERMTU; - ifp->if_flags = IFF_BROADCAST | IFF_SIMPLEX | IFF_MULTICAST | - IFF_NEEDSGIANT; + ifp->if_flags = IFF_BROADCAST | IFF_SIMPLEX | IFF_MULTICAST; + if (!IS_MPSAFE) + ifp->if_flags |= IFF_NEEDSGIANT; ifp->if_ioctl = dc_ioctl; ifp->if_start = dc_start; ifp->if_watchdog = dc_watchdog; |