* This routine is called to deliver a packet out the interface. * We simply queue the netgraph version to be called when netgraph locking * allows it to happen. * Until we know what the rest of the networking code is doing for * locking, we don't know how we will interact with it. * Take comfort from the fact that the ifnet struct is part of our * private info and can't go away while we are
| 287 | * somehow, but we can't and if we did would we solve anything? |
| 288 | */ |
| 289 | static void |
| 290 | ng_eiface_start(struct ifnet *ifp) |
| 291 | { |
| 292 | const priv_p priv = (priv_p)ifp->if_softc; |
| 293 | |
| 294 | /* Don't do anything if output is active */ |
| 295 | if (ifp->if_drv_flags & IFF_DRV_OACTIVE) |
| 296 | return; |
| 297 | |
| 298 | ifp->if_drv_flags |= IFF_DRV_OACTIVE; |
| 299 | |
| 300 | if (ng_send_fn(priv->node, NULL, &ng_eiface_start2, ifp, 0) != 0) |
| 301 | ifp->if_drv_flags &= ~IFF_DRV_OACTIVE; |
| 302 | } |
| 303 | |
| 304 | #ifdef DEBUG |
| 305 | /* |
nothing calls this directly
no test coverage detected