summaryrefslogtreecommitdiff
path: root/lib/librte_net/rte_icmp.h
diff options
context:
space:
mode:
Diffstat (limited to 'lib/librte_net/rte_icmp.h')
-rw-r--r--lib/librte_net/rte_icmp.h12
1 files changed, 7 insertions, 5 deletions
diff --git a/lib/librte_net/rte_icmp.h b/lib/librte_net/rte_icmp.h
index 3f8100a..e0aeed4 100644
--- a/lib/librte_net/rte_icmp.h
+++ b/lib/librte_net/rte_icmp.h
@@ -16,6 +16,8 @@
#include <stdint.h>
+#include <rte_byteorder.h>
+
#ifdef __cplusplus
extern "C" {
#endif
@@ -24,11 +26,11 @@ extern "C" {
* ICMP Header
*/
struct rte_icmp_hdr {
- uint8_t icmp_type; /* ICMP packet type. */
- uint8_t icmp_code; /* ICMP packet code. */
- uint16_t icmp_cksum; /* ICMP packet checksum. */
- uint16_t icmp_ident; /* ICMP packet identifier. */
- uint16_t icmp_seq_nb; /* ICMP packet sequence number. */
+ uint8_t icmp_type; /* ICMP packet type. */
+ uint8_t icmp_code; /* ICMP packet code. */
+ rte_be16_t icmp_cksum; /* ICMP packet checksum. */
+ rte_be16_t icmp_ident; /* ICMP packet identifier. */
+ rte_be16_t icmp_seq_nb; /* ICMP packet sequence number. */
} __attribute__((__packed__));
/* ICMP packet types */