FreeBSD/sys/netpfil/ipfw/ip_dn_io.c
/*
 * Return the mbuf tag holding the dummynet state (it should
 * be the first one on the list).
 */
Return the mbuf tag holding the dummynet state (it should
be the first one on the list).
Return the mbuf tag holding the dummynet state ( it should be the first one on the list ) .
static struct dn_pkt_tag *
dn_tag_get(struct mbuf *m)
{
	struct m_tag *mtag = m_tag_first(m);
#ifdef NEW_AQM
	if (mtag != NULL && mtag->m_tag_id == DN_AQM_MTAG_TS) {
		m_tag_delete(m,mtag); 
		mtag = m_tag_first(m);
		D("skip TS tag");
	}
#endif
	KASSERT(mtag != NULL &&
	    mtag->m_tag_cookie == MTAG_ABI_COMPAT &&
	    mtag->m_tag_id == PACKET_TAG_DUMMYNET,
	    ("packet on dummynet queue w/o dummynet tag!"));
	return (struct dn_pkt_tag *)(mtag+1);
}
static struct dn_pkt_tag * dn_tag_get ( struct mbuf * m ) { struct m_tag * mtag = m_tag_first ( m ) ; #ifdef NEW_AQM if ( mtag != NULL && mtag -> m_tag_id == DN_AQM_MTAG_TS ) { m_tag_delete ( m , mtag ) ; mtag = m_tag_first ( m ) ; D ( " " ) ; } #endif KASSERT ( mtag != NULL && mtag -> m_tag_cookie == MTAG_ABI_COMPAT && mtag -> m_tag_id == PACKET_TAG_DUMMYNET , ( " " ) ) ; return ( struct dn_pkt_tag * ) ( mtag + 1 ) ; }
Return the mbuf tag holding the dummynet state (it should
 be the first one on the list).
Return the mbuf tag holding the dummynet state ( it should be the first one on the list ) .
/* XXX: to skip ts m_tag. For Debugging only*/