SIOCSIFFLAGS doesn't require an argument in kernel land; instead, flags
are supposed to be set directly in ifnet already. This change fixes a panic when ng_eiface node is attached to ng_fec node and the latter is shut down (ng_fec sets flags and then calls SIOCSIFFLAGS with a NULL argument). MFC after: 3 days
This commit is contained in:
parent
aed8e389c1
commit
3d82b87057
@ -145,7 +145,7 @@ ng_eiface_ioctl(struct ifnet *ifp, u_long command, caddr_t data)
|
||||
* If the interface is marked up and stopped, then start it.
|
||||
* If it is marked down and running, then stop it.
|
||||
*/
|
||||
if (ifr->ifr_flags & IFF_UP) {
|
||||
if (ifp->if_flags & IFF_UP) {
|
||||
if (!(ifp->if_drv_flags & IFF_DRV_RUNNING)) {
|
||||
ifp->if_drv_flags &= ~(IFF_DRV_OACTIVE);
|
||||
ifp->if_drv_flags |= IFF_DRV_RUNNING;
|
||||
|
Loading…
x
Reference in New Issue
Block a user