From d47f0d75af4cf9eeeb0fe04ceb6a708bb0670eb3 Mon Sep 17 00:00:00 2001 From: Warner Losh Date: Wed, 13 May 2009 14:43:26 +0000 Subject: [PATCH] ifp->if_softc is managed entirely by the driver. We never set it to NULL or change it. We initialize it before we set if_ioctl. It can therefore never be NULL, and most other drivers don't bother with this sanity check. --- sys/dev/ed/if_ed.c | 8 -------- 1 file changed, 8 deletions(-) diff --git a/sys/dev/ed/if_ed.c b/sys/dev/ed/if_ed.c index 5a60569ff1ef..f94ec8b76806 100644 --- a/sys/dev/ed/if_ed.c +++ b/sys/dev/ed/if_ed.c @@ -1164,14 +1164,6 @@ ed_ioctl(struct ifnet *ifp, u_long command, caddr_t data) struct ifreq *ifr = (struct ifreq *)data; int error = 0; - /* - * XXX really needed? - */ - if (sc == NULL) { - ifp->if_drv_flags &= ~IFF_DRV_RUNNING; - return (ENXIO); - } - switch (command) { case SIOCSIFFLAGS: /*