@@ -642,8 +642,8 @@ struct rte_flow_item_higig2_hdr {
static const struct rte_flow_item_higig2_hdr rte_flow_item_higig2_hdr_mask = {
.hdr = {
.ppt1 = {
- .classification = 0xffff,
- .vid = 0xfff,
+ .classification = RTE_BE16(UINT16_MAX),
+ .vid = RTE_BE16(0xfff),
},
},
};
@@ -23,28 +23,28 @@ extern "C" {
*/
struct rte_arp_ipv4 {
struct rte_ether_addr arp_sha; /**< sender hardware address */
- uint32_t arp_sip; /**< sender IP address */
+ rte_be32_t arp_sip; /**< sender IP address */
struct rte_ether_addr arp_tha; /**< target hardware address */
- uint32_t arp_tip; /**< target IP address */
+ rte_be32_t arp_tip; /**< target IP address */
} __rte_packed __rte_aligned(2);
/**
* ARP header.
*/
struct rte_arp_hdr {
- uint16_t arp_hardware; /* format of hardware address */
-#define RTE_ARP_HRD_ETHER 1 /* ARP Ethernet address format */
+ rte_be16_t arp_hardware; /**< format of hardware address */
+#define RTE_ARP_HRD_ETHER 1 /**< ARP Ethernet address format */
- uint16_t arp_protocol; /* format of protocol address */
- uint8_t arp_hlen; /* length of hardware address */
- uint8_t arp_plen; /* length of protocol address */
- uint16_t arp_opcode; /* ARP opcode (command) */
-#define RTE_ARP_OP_REQUEST 1 /* request to resolve address */
-#define RTE_ARP_OP_REPLY 2 /* response to previous request */
-#define RTE_ARP_OP_REVREQUEST 3 /* request proto addr given hardware */
-#define RTE_ARP_OP_REVREPLY 4 /* response giving protocol address */
-#define RTE_ARP_OP_INVREQUEST 8 /* request to identify peer */
-#define RTE_ARP_OP_INVREPLY 9 /* response identifying peer */
+ rte_be16_t arp_protocol; /**< format of protocol address */
+ uint8_t arp_hlen; /**< length of hardware address */
+ uint8_t arp_plen; /**< length of protocol address */
+ rte_be16_t arp_opcode; /**< ARP opcode (command) */
+#define RTE_ARP_OP_REQUEST 1 /**< request to resolve address */
+#define RTE_ARP_OP_REPLY 2 /**< response to previous request */
+#define RTE_ARP_OP_REVREQUEST 3 /**< request proto addr given hardware */
+#define RTE_ARP_OP_REVREPLY 4 /**< response giving protocol address */
+#define RTE_ARP_OP_INVREQUEST 8 /**< request to identify peer */
+#define RTE_ARP_OP_INVREPLY 9 /**< response identifying peer */
struct rte_arp_ipv4 arp_data;
} __rte_packed __rte_aligned(2);
@@ -45,7 +45,7 @@ struct rte_gre_hdr {
uint16_t res3:5; /**< Reserved */
uint16_t ver:3; /**< Version Number */
#endif
- uint16_t proto; /**< Protocol Type */
+ rte_be16_t proto; /**< Protocol Type */
} __rte_packed;
/**
@@ -112,9 +112,9 @@ struct rte_higig2_ppt_type0 {
*/
__extension__
struct rte_higig2_ppt_type1 {
- uint16_t classification;
- uint16_t resv;
- uint16_t vid;
+ rte_be16_t classification;
+ rte_be16_t resv;
+ rte_be16_t vid;
#if RTE_BYTE_ORDER == RTE_LITTLE_ENDIAN
uint16_t opcode:3;
uint16_t resv1:2;
@@ -23,7 +23,7 @@ extern "C" {
*/
__extension__
struct rte_mpls_hdr {
- uint16_t tag_msb; /**< Label(msb). */
+ rte_be16_t tag_msb; /**< Label(msb). */
#if RTE_BYTE_ORDER == RTE_BIG_ENDIAN
uint8_t tag_lsb:4; /**< Label(lsb). */
uint8_t tc:3; /**< Traffic class. */