Lines Matching refs:ifp

265 	struct ifnet *ifp = &sc->sc_ethercom.ec_if;
364 strlcpy(ifp->if_xname, device_xname(self), IFNAMSIZ);
365 ifp->if_softc = sc;
366 ifp->if_start = xennet_start;
367 ifp->if_ioctl = xennet_ioctl;
368 ifp->if_watchdog = xennet_watchdog;
369 ifp->if_init = xennet_init;
370 ifp->if_stop = xennet_stop;
371 ifp->if_flags = IFF_BROADCAST|IFF_SIMPLEX|IFF_NOTRAILERS|IFF_MULTICAST;
372 ifp->if_timer = 0;
373 ifp->if_snd.ifq_maxlen = max(ifqmaxlen, NET_TX_RING_SIZE * 2);
374 ifp->if_capabilities = IFCAP_CSUM_TCPv4_Tx | IFCAP_CSUM_UDPv4_Tx;
375 IFQ_SET_READY(&ifp->if_snd);
376 if_attach(ifp);
377 ether_ifattach(ifp, sc->sc_enaddr);
410 pmf_class_network_register(self, ifp);
417 struct ifnet *ifp = &sc->sc_ethercom.ec_if;
423 xennet_stop(ifp, 1);
440 ether_ifdetach(ifp);
441 if_detach(ifp);
914 struct ifnet *ifp = &sc->sc_ethercom.ec_if;
937 ifp->if_oerrors++;
939 ifp->if_opackets++;
950 ifp->if_timer = 0;
955 if (ifp->if_flags & IFF_OACTIVE) {
956 ifp->if_flags &= ~IFF_OACTIVE;
971 struct ifnet *ifp = &sc->sc_ethercom.ec_if;
1017 ifp->if_ierrors++;
1056 if ((ifp->if_flags & IFF_PROMISC) == 0) {
1059 memcmp(CLLADDR(ifp->if_sadl), eh->ether_dhost,
1070 printf("%s: rx no mbuf\n", ifp->if_xname);
1071 ifp->if_ierrors++;
1077 m->m_pkthdr.rcvif = ifp;
1081 printf("%s: rx no buf\n", ifp->if_xname);
1082 ifp->if_ierrors++;
1097 ifp->if_ierrors++;
1106 bpf_mtap(ifp, m);
1108 ifp->if_ipackets++;
1111 (*ifp->if_input)(ifp, m);
1129 xennet_start(struct ifnet *ifp)
1131 struct xennet_xenbus_softc *sc = ifp->if_softc;
1140 (ifp->if_flags & (IFF_RUNNING | IFF_OACTIVE)) != IFF_RUNNING))
1162 struct ifnet *ifp = &sc->sc_ethercom.ec_if;
1173 (ifp->if_flags & (IFF_RUNNING | IFF_OACTIVE)) != IFF_RUNNING)) {
1184 ifp->if_flags |= IFF_OACTIVE;
1187 IFQ_POLL(&ifp->if_snd, m);
1256 ifp->if_flags |= IFF_OACTIVE;
1260 IFQ_DEQUEUE(&ifp->if_snd, m);
1268 ifp->if_flags |= IFF_OACTIVE;
1272 IFQ_DEQUEUE(&ifp->if_snd, m);
1321 bpf_mtap(ifp, m);
1326 ifp->if_timer = 5;
1336 xennet_ioctl(struct ifnet *ifp, u_long cmd, void *data)
1339 struct xennet_xenbus_softc *sc = ifp->if_softc;
1347 error = ether_ioctl(ifp, cmd, data);
1359 xennet_watchdog(struct ifnet *ifp)
1361 aprint_verbose_ifnet(ifp, "xennet_watchdog\n");
1365 xennet_init(struct ifnet *ifp)
1367 struct xennet_xenbus_softc *sc = ifp->if_softc;
1373 if ((ifp->if_flags & IFF_RUNNING) == 0) {
1380 ifp->if_flags |= IFF_RUNNING;
1381 ifp->if_flags &= ~IFF_OACTIVE;
1382 ifp->if_timer = 0;
1388 xennet_stop(struct ifnet *ifp, int disable)
1390 struct xennet_xenbus_softc *sc = ifp->if_softc;
1392 ifp->if_flags &= ~(IFF_RUNNING | IFF_OACTIVE);
1410 struct ifnet *ifp = nd->nd_ifp;
1412 (struct xennet_xenbus_softc *)ifp->if_softc;