Since if_nge doesn't contain locking or run with INTR_MPSAFE, mark

the interface as IFF_NEEDSGIANT so if_start is run holding Giant.

Note: this driver does declare and occasionally reference mutexes,
but I believe not nearly enough to provide safety.
This commit is contained in:
Robert Watson 2004-08-13 23:22:53 +00:00
parent 361de173a5
commit fc4af83ae9

View File

@ -888,7 +888,8 @@ nge_attach(dev)
ifp->if_softc = sc;
if_initname(ifp, device_get_name(dev), device_get_unit(dev));
ifp->if_mtu = ETHERMTU;
ifp->if_flags = IFF_BROADCAST | IFF_SIMPLEX | IFF_MULTICAST;
ifp->if_flags = IFF_BROADCAST | IFF_SIMPLEX | IFF_MULTICAST |
IFF_NEEDSGIANT;
ifp->if_ioctl = nge_ioctl;
ifp->if_start = nge_start;
ifp->if_watchdog = nge_watchdog;