FreeBSD/sys/dev/usb/wlan/if_uath.c
/*
 * Setup xmit of a fragmented frame.  Allocate a buffer for each frag and bump
 * the node reference count to reflect the held reference to be setup by
 * uath_tx_start.
 */
Setup xmit of a fragmented frame.  Allocate a buffer for each frag and bump
the node reference count to reflect the held reference to be setup by
uath_tx_start.
Setup xmit of a fragmented frame . Allocate a buffer for each frag and bump the node reference count to reflect the held reference to be setup by uath_tx_start .
static int
uath_txfrag_setup(struct uath_softc *sc, uath_datahead *frags,
    struct mbuf *m0, struct ieee80211_node *ni)
{
	struct mbuf *m;
	struct uath_data *bf;
	UATH_ASSERT_LOCKED(sc);
	for (m = m0->m_nextpkt; m != NULL; m = m->m_nextpkt) {
		bf = uath_getbuf(sc);
		if (bf == NULL) {       
			uath_txfrag_cleanup(sc, frags, ni);
			break;
		}
		ieee80211_node_incref(ni);
		STAILQ_INSERT_TAIL(frags, bf, next);
	}
	return !STAILQ_EMPTY(frags);
}
static int uath_txfrag_setup ( struct uath_softc * sc , uath_datahead * frags , struct mbuf * m0 , struct ieee80211_node * ni ) { struct mbuf * m ; struct uath_data * bf ; UATH_ASSERT_LOCKED ( sc ) ; for ( m = m0 -> m_nextpkt ; m != NULL ; m = m -> m_nextpkt ) { bf = uath_getbuf ( sc ) ; if ( bf == NULL ) { uath_txfrag_cleanup ( sc , frags , ni ) ; break ; } ieee80211_node_incref ( ni ) ; STAILQ_INSERT_TAIL ( frags , bf , next ) ; } return ! STAILQ_EMPTY ( frags ) ; }
Setup xmit of a fragmented frame.
Setup xmit of a fragmented frame .
/* out of buffers, cleanup */