Lines Matching refs:ifp
79 /* static void edsc_input(struct ifnet *ifp, struct mbuf *m); would be here */
80 static int edsc_ioctl(struct ifnet *ifp, u_long cmd, caddr_t data);
81 static void edsc_start(struct ifnet *ifp);
95 struct ifnet *ifp;
102 ifp = sc->sc_ifp = if_alloc(IFT_ETHER);
103 if (ifp == NULL) {
108 ifp->if_softc = sc;
113 if_initname(ifp, edscname, unit);
119 ifp->if_flags = IFF_BROADCAST | IFF_MULTICAST | IFF_SIMPLEX;
127 ifp->if_capabilities =
131 ifp->if_capenable = 0;
136 ifp->if_init = edsc_init;
137 /* ifp->if_input = edsc_input; */
138 ifp->if_ioctl = edsc_ioctl;
139 ifp->if_start = edsc_start;
144 ifp->if_snd.ifq_maxlen = ifqmaxlen;
151 ether_ifattach(ifp, eaddr);
157 ifp->if_drv_flags |= IFF_DRV_RUNNING;
166 edsc_clone_destroy(struct ifnet *ifp)
168 struct edsc_softc *sc = ifp->if_softc;
173 ether_ifdetach(ifp);
178 if_free(ifp);
191 struct ifnet *ifp = sc->sc_ifp;
201 edsc_ioctl(struct ifnet *ifp, u_long cmd, caddr_t data)
213 ifp->if_capenable = ifr->ifr_reqcap;
219 mask = ifp->if_capenable ^ ifr->ifr_reqcap;
222 ifp->if_capenable ^= IFCAP_VLAN_HWTAGGING;
224 if (ifp->if_capenable & IFCAP_VLAN_HWTAGGING)
236 return (ether_ioctl(ifp, cmd, data));
246 edsc_start(struct ifnet *ifp)
252 * in ifp->if_drv_flags:
254 * ifp->if_drv_flags |= IFF_DRV_OACTIVE;
281 IFQ_DEQUEUE(&ifp->if_snd, m);
288 BPF_MTAP(ifp, m);
293 ifp->if_obytes += m->m_pkthdr.len;
294 ifp->if_opackets++;
304 * ifp->if_drv_flags &= ~IFF_DRV_OACTIVE;