Changeset View
Changeset View
Standalone View
Standalone View
sys/sys/mbuf.h
Show First 20 Lines • Show All 131 Lines • ▼ Show 20 Lines | |||||
/* | /* | ||||
* Record/packet header in first mbuf of chain; valid only if M_PKTHDR is set. | * Record/packet header in first mbuf of chain; valid only if M_PKTHDR is set. | ||||
* Size ILP32: 48 | * Size ILP32: 48 | ||||
* LP64: 56 | * LP64: 56 | ||||
* Compile-time assertions in uipc_mbuf.c test these values to ensure that | * Compile-time assertions in uipc_mbuf.c test these values to ensure that | ||||
* they are correct. | * they are correct. | ||||
*/ | */ | ||||
struct pkthdr { | struct pkthdr { | ||||
struct ifnet *rcvif; /* rcv interface */ | struct ifnet *rcvif; /* rcv interface */ | ||||
gallatin: I thought we were going to turn the rcvif into a union, and make it a pointer to the snd_tag on… | |||||
Done Inline ActionsYes, we can do that, though I'm a little worried that someone will complain about nameless unions. What do you think? hselasky: Yes, we can do that, though I'm a little worried that someone will complain about nameless… | |||||
SLIST_HEAD(packet_tags, m_tag) tags; /* list of packet tags */ | SLIST_HEAD(packet_tags, m_tag) tags; /* list of packet tags */ | ||||
int32_t len; /* total packet length */ | int32_t len; /* total packet length */ | ||||
/* Layer crossing persistent information. */ | /* Layer crossing persistent information. */ | ||||
uint32_t flowid; /* packet's 4-tuple system */ | uint32_t flowid; /* packet's 4-tuple system */ | ||||
uint64_t csum_flags; /* checksum and offload features */ | uint64_t csum_flags; /* checksum and offload features */ | ||||
uint16_t fibnum; /* this packet should use this fib */ | uint16_t fibnum; /* this packet should use this fib */ | ||||
uint8_t cosqos; /* class/quality of service */ | uint8_t cosqos; /* class/quality of service */ | ||||
▲ Show 20 Lines • Show All 191 Lines • ▼ Show 20 Lines | |||||
/* Non-standard RSS hash types */ | /* Non-standard RSS hash types */ | ||||
#define M_HASHTYPE_RSS_UDP_IPV4 M_HASHTYPE_HASH(7) /* IPv4 UDP 4-tuple*/ | #define M_HASHTYPE_RSS_UDP_IPV4 M_HASHTYPE_HASH(7) /* IPv4 UDP 4-tuple*/ | ||||
#define M_HASHTYPE_RSS_UDP_IPV4_EX M_HASHTYPE_HASH(8) /* IPv4 UDP 4-tuple + | #define M_HASHTYPE_RSS_UDP_IPV4_EX M_HASHTYPE_HASH(8) /* IPv4 UDP 4-tuple + | ||||
* ext hdrs */ | * ext hdrs */ | ||||
#define M_HASHTYPE_RSS_UDP_IPV6 M_HASHTYPE_HASH(9) /* IPv6 UDP 4-tuple*/ | #define M_HASHTYPE_RSS_UDP_IPV6 M_HASHTYPE_HASH(9) /* IPv6 UDP 4-tuple*/ | ||||
#define M_HASHTYPE_RSS_UDP_IPV6_EX M_HASHTYPE_HASH(10)/* IPv6 UDP 4-tuple + | #define M_HASHTYPE_RSS_UDP_IPV6_EX M_HASHTYPE_HASH(10)/* IPv6 UDP 4-tuple + | ||||
* ext hdrs */ | * ext hdrs */ | ||||
#define M_HASHTYPE_TXRTLMT 62 /* rate limited TX traffic */ | |||||
#define M_HASHTYPE_OPAQUE 63 /* ordering, not affinity */ | #define M_HASHTYPE_OPAQUE 63 /* ordering, not affinity */ | ||||
#define M_HASHTYPE_OPAQUE_HASH M_HASHTYPE_HASH(M_HASHTYPE_OPAQUE) | #define M_HASHTYPE_OPAQUE_HASH M_HASHTYPE_HASH(M_HASHTYPE_OPAQUE) | ||||
/* ordering+hash, not affinity*/ | /* ordering+hash, not affinity*/ | ||||
#define M_HASHTYPE_CLEAR(m) ((m)->m_pkthdr.rsstype = 0) | #define M_HASHTYPE_CLEAR(m) ((m)->m_pkthdr.rsstype = 0) | ||||
#define M_HASHTYPE_GET(m) ((m)->m_pkthdr.rsstype) | #define M_HASHTYPE_GET(m) ((m)->m_pkthdr.rsstype) | ||||
#define M_HASHTYPE_SET(m, v) ((m)->m_pkthdr.rsstype = (v)) | #define M_HASHTYPE_SET(m, v) ((m)->m_pkthdr.rsstype = (v)) | ||||
#define M_HASHTYPE_TEST(m, v) (M_HASHTYPE_GET(m) == (v)) | #define M_HASHTYPE_TEST(m, v) (M_HASHTYPE_GET(m) == (v)) | ||||
▲ Show 20 Lines • Show All 958 Lines • Show Last 20 Lines |
I thought we were going to turn the rcvif into a union, and make it a pointer to the snd_tag on xmit?