diff options
author | jfv <jfv@FreeBSD.org> | 2011-12-11 09:37:25 +0000 |
---|---|---|
committer | jfv <jfv@FreeBSD.org> | 2011-12-11 09:37:25 +0000 |
commit | 50815bc204802a24b13bd3533d574fec92ea137d (patch) | |
tree | b1b7a6690aa72a00cabefafff3d33c225c4c284a /sys/dev/e1000/if_em.c | |
parent | 0aa55ed72f28d8be4685316a8433831356f53d05 (diff) | |
download | FreeBSD-src-50815bc204802a24b13bd3533d574fec92ea137d.zip FreeBSD-src-50815bc204802a24b13bd3533d574fec92ea137d.tar.gz |
Correct LINT build issues in the ioctl code.
Diffstat (limited to 'sys/dev/e1000/if_em.c')
-rw-r--r-- | sys/dev/e1000/if_em.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/sys/dev/e1000/if_em.c b/sys/dev/e1000/if_em.c index dbb6f42..122c280 100644 --- a/sys/dev/e1000/if_em.c +++ b/sys/dev/e1000/if_em.c @@ -1045,8 +1045,8 @@ em_ioctl(struct ifnet *ifp, u_long command, caddr_t data) struct ifreq *ifr = (struct ifreq *)data; #if defined(INET) || defined(INET6) struct ifaddr *ifa = (struct ifaddr *)data; -#endif bool avoid_reset = FALSE; +#endif int error = 0; if (adapter->in_detach) @@ -1058,6 +1058,11 @@ em_ioctl(struct ifnet *ifp, u_long command, caddr_t data) if (ifa->ifa_addr->sa_family == AF_INET) avoid_reset = TRUE; #endif +#ifdef INET6 + if (ifa->ifa_addr->sa_family == AF_INET6) + avoid_reset = TRUE; +#endif +#if defined(INET) || defined(INET6) /* ** Calling init results in link renegotiation, ** so we avoid doing it when possible. @@ -1066,12 +1071,11 @@ em_ioctl(struct ifnet *ifp, u_long command, caddr_t data) ifp->if_flags |= IFF_UP; if (!(ifp->if_drv_flags & IFF_DRV_RUNNING)) em_init(adapter); -#ifdef INET if (!(ifp->if_flags & IFF_NOARP)) arp_ifinit(ifp, ifa); -#endif } else error = ether_ioctl(ifp, command, data); +#endif break; case SIOCSIFMTU: { |