2017-12-22 15:59:02 +00:00
|
|
|
/* SPDX-License-Identifier: BSD-3-Clause
|
|
|
|
* Copyright(c) 1982, 1986, 1990, 1993
|
|
|
|
* The Regents of the University of California.
|
|
|
|
* Copyright(c) 2010-2014 Intel Corporation.
|
|
|
|
* All rights reserved.
|
2012-09-04 12:54:00 +00:00
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef _RTE_UDP_H_
|
|
|
|
#define _RTE_UDP_H_
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @file
|
|
|
|
*
|
|
|
|
* UDP-related defines
|
|
|
|
*/
|
|
|
|
|
|
|
|
#include <stdint.h>
|
|
|
|
|
2019-09-27 11:58:02 +00:00
|
|
|
#include <rte_byteorder.h>
|
|
|
|
|
2012-09-04 12:54:00 +00:00
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
|
|
|
#endif
|
|
|
|
|
|
|
|
/**
|
|
|
|
* UDP Header
|
|
|
|
*/
|
2019-05-21 16:13:14 +00:00
|
|
|
struct rte_udp_hdr {
|
2019-09-27 11:58:02 +00:00
|
|
|
rte_be16_t src_port; /**< UDP source port. */
|
|
|
|
rte_be16_t dst_port; /**< UDP destination port. */
|
|
|
|
rte_be16_t dgram_len; /**< UDP datagram length */
|
|
|
|
rte_be16_t dgram_cksum; /**< UDP datagram checksum */
|
2020-02-09 17:29:23 +00:00
|
|
|
} __rte_packed;
|
2012-09-04 12:54:00 +00:00
|
|
|
|
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#endif /* RTE_UDP_H_ */
|