svn commit: r192043 - head/sys/dev/ed

Warner Losh imp at FreeBSD.org
Wed May 13 14:43:27 UTC 2009


Author: imp
Date: Wed May 13 14:43:26 2009
New Revision: 192043
URL: http://svn.freebsd.org/changeset/base/192043

Log:
  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.

Modified:
  head/sys/dev/ed/if_ed.c

Modified: head/sys/dev/ed/if_ed.c
==============================================================================
--- head/sys/dev/ed/if_ed.c	Wed May 13 14:25:55 2009	(r192042)
+++ head/sys/dev/ed/if_ed.c	Wed May 13 14:43:26 2009	(r192043)
@@ -1164,14 +1164,6 @@ ed_ioctl(struct ifnet *ifp, u_long comma
 	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:
 		/*


More information about the svn-src-head mailing list