View | Details | Raw Unified | Return to bug 187203 | Differences between
and this patch

Collapse All | Expand All

(-)sys/dev/hyperv/netvsc/hv_netvsc_drv_freebsd.c (-1 / +10 lines)
Lines 736-742 hn_ioctl(struct ifnet *ifp, u_long cmd, caddr_t da Link Here
736
	switch(cmd) {
736
	switch(cmd) {
737
737
738
	case SIOCSIFADDR:
738
	case SIOCSIFADDR:
739
	case SIOCGIFADDR:
739
#ifdef INET
740
		if (ifa->ifa_addr->sa_family == AF_INET) {
741
			ifp->if_flags |= IFF_UP;
742
			if (!(ifp->if_drv_flags & IFF_DRV_RUNNING))
743
				hn_ifinit(sc);
744
			arp_ifinit(ifp, ifa);
745
		} else
746
#endif
740
		error = ether_ioctl(ifp, cmd, data);
747
		error = ether_ioctl(ifp, cmd, data);
741
		break;
748
		break;
742
	case SIOCSIFMTU:
749
	case SIOCSIFMTU:
Lines 900-905 hn_stop(hn_softc_t *sc) Link Here
900
		printf(" Closing Device ...\n");
907
		printf(" Closing Device ...\n");
901
908
902
	ifp->if_drv_flags &= ~(IFF_DRV_RUNNING | IFF_DRV_OACTIVE);
909
	ifp->if_drv_flags &= ~(IFF_DRV_RUNNING | IFF_DRV_OACTIVE);
910
	if_link_state_change(ifp, LINK_STATE_DOWN);
903
	sc->hn_initdone = 0;
911
	sc->hn_initdone = 0;
904
912
905
	ret = hv_rf_on_close(device_ctx);
913
	ret = hv_rf_on_close(device_ctx);
Lines 949-954 hn_ifinit_locked(hn_softc_t *sc) Link Here
949
	}
957
	}
950
	ifp->if_drv_flags |= IFF_DRV_RUNNING;
958
	ifp->if_drv_flags |= IFF_DRV_RUNNING;
951
	ifp->if_drv_flags &= ~IFF_DRV_OACTIVE;
959
	ifp->if_drv_flags &= ~IFF_DRV_OACTIVE;
960
	if_link_state_change(ifp, LINK_STATE_UP);
952
}
961
}
953
962
954
/*
963
/*

Return to bug 187203