git.droids-corp.org
/
dpdk.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
net/ice: support PPPoE RSS
[dpdk.git]
/
lib
/
librte_gro
/
gro_vxlan_tcp4.c
diff --git
a/lib/librte_gro/gro_vxlan_tcp4.c
b/lib/librte_gro/gro_vxlan_tcp4.c
index
8e2a1dd
..
f3b6e60
100644
(file)
--- a/
lib/librte_gro/gro_vxlan_tcp4.c
+++ b/
lib/librte_gro/gro_vxlan_tcp4.c
@@
-208,7
+208,7
@@
is_same_vxlan_tcp4_flow(struct vxlan_tcp4_flow_key k1,
static inline int
check_vxlan_seq_option(struct gro_vxlan_tcp4_item *item,
static inline int
check_vxlan_seq_option(struct gro_vxlan_tcp4_item *item,
- struct tcp_hdr *tcp_hdr,
+ struct
rte_
tcp_hdr *tcp_hdr,
uint32_t sent_seq,
uint16_t outer_ip_id,
uint16_t ip_id,
uint32_t sent_seq,
uint16_t outer_ip_id,
uint16_t ip_id,
@@
-264,7
+264,7
@@
static inline void
update_vxlan_header(struct gro_vxlan_tcp4_item *item)
{
struct rte_ipv4_hdr *ipv4_hdr;
update_vxlan_header(struct gro_vxlan_tcp4_item *item)
{
struct rte_ipv4_hdr *ipv4_hdr;
- struct udp_hdr *udp_hdr;
+ struct
rte_
udp_hdr *udp_hdr;
struct rte_mbuf *pkt = item->inner_item.firstseg;
uint16_t len;
struct rte_mbuf *pkt = item->inner_item.firstseg;
uint16_t len;
@@
-276,7
+276,7
@@
update_vxlan_header(struct gro_vxlan_tcp4_item *item)
/* Update the outer UDP header. */
len -= pkt->outer_l3_len;
/* Update the outer UDP header. */
len -= pkt->outer_l3_len;
- udp_hdr = (struct udp_hdr *)((char *)ipv4_hdr + pkt->outer_l3_len);
+ udp_hdr = (struct
rte_
udp_hdr *)((char *)ipv4_hdr + pkt->outer_l3_len);
udp_hdr->dgram_len = rte_cpu_to_be_16(len);
/* Update the inner IPv4 header. */
udp_hdr->dgram_len = rte_cpu_to_be_16(len);
/* Update the inner IPv4 header. */
@@
-292,8
+292,8
@@
gro_vxlan_tcp4_reassemble(struct rte_mbuf *pkt,
{
struct rte_ether_hdr *outer_eth_hdr, *eth_hdr;
struct rte_ipv4_hdr *outer_ipv4_hdr, *ipv4_hdr;
{
struct rte_ether_hdr *outer_eth_hdr, *eth_hdr;
struct rte_ipv4_hdr *outer_ipv4_hdr, *ipv4_hdr;
- struct tcp_hdr *tcp_hdr;
- struct udp_hdr *udp_hdr;
+ struct
rte_
tcp_hdr *tcp_hdr;
+ struct
rte_
udp_hdr *udp_hdr;
struct rte_vxlan_hdr *vxlan_hdr;
uint32_t sent_seq;
int32_t tcp_dl;
struct rte_vxlan_hdr *vxlan_hdr;
uint32_t sent_seq;
int32_t tcp_dl;
@@
-317,20
+317,20
@@
gro_vxlan_tcp4_reassemble(struct rte_mbuf *pkt,
outer_eth_hdr = rte_pktmbuf_mtod(pkt, struct rte_ether_hdr *);
outer_ipv4_hdr = (struct rte_ipv4_hdr *)((char *)outer_eth_hdr +
pkt->outer_l2_len);
outer_eth_hdr = rte_pktmbuf_mtod(pkt, struct rte_ether_hdr *);
outer_ipv4_hdr = (struct rte_ipv4_hdr *)((char *)outer_eth_hdr +
pkt->outer_l2_len);
- udp_hdr = (struct udp_hdr *)((char *)outer_ipv4_hdr +
+ udp_hdr = (struct
rte_
udp_hdr *)((char *)outer_ipv4_hdr +
pkt->outer_l3_len);
vxlan_hdr = (struct rte_vxlan_hdr *)((char *)udp_hdr +
pkt->outer_l3_len);
vxlan_hdr = (struct rte_vxlan_hdr *)((char *)udp_hdr +
- sizeof(struct udp_hdr));
+ sizeof(struct
rte_
udp_hdr));
eth_hdr = (struct rte_ether_hdr *)((char *)vxlan_hdr +
sizeof(struct rte_vxlan_hdr));
ipv4_hdr = (struct rte_ipv4_hdr *)((char *)udp_hdr + pkt->l2_len);
eth_hdr = (struct rte_ether_hdr *)((char *)vxlan_hdr +
sizeof(struct rte_vxlan_hdr));
ipv4_hdr = (struct rte_ipv4_hdr *)((char *)udp_hdr + pkt->l2_len);
- tcp_hdr = (struct tcp_hdr *)((char *)ipv4_hdr + pkt->l3_len);
+ tcp_hdr = (struct
rte_
tcp_hdr *)((char *)ipv4_hdr + pkt->l3_len);
/*
* Don't process the packet which has FIN, SYN, RST, PSH, URG,
* ECE or CWR set.
*/
/*
* Don't process the packet which has FIN, SYN, RST, PSH, URG,
* ECE or CWR set.
*/
- if (tcp_hdr->tcp_flags != TCP_ACK_FLAG)
+ if (tcp_hdr->tcp_flags !=
RTE_
TCP_ACK_FLAG)
return -1;
hdr_len = pkt->outer_l2_len + pkt->outer_l3_len + pkt->l2_len +
return -1;
hdr_len = pkt->outer_l2_len + pkt->outer_l3_len + pkt->l2_len +
@@
-348,11
+348,12
@@
gro_vxlan_tcp4_reassemble(struct rte_mbuf *pkt,
* whose DF bit is 1, IPv4 ID is ignored.
*/
frag_off = rte_be_to_cpu_16(outer_ipv4_hdr->fragment_offset);
* whose DF bit is 1, IPv4 ID is ignored.
*/
frag_off = rte_be_to_cpu_16(outer_ipv4_hdr->fragment_offset);
- outer_is_atomic = (frag_off & IPV4_HDR_DF_FLAG) == IPV4_HDR_DF_FLAG;
+ outer_is_atomic =
+ (frag_off & RTE_IPV4_HDR_DF_FLAG) == RTE_IPV4_HDR_DF_FLAG;
outer_ip_id = outer_is_atomic ? 0 :
rte_be_to_cpu_16(outer_ipv4_hdr->packet_id);
frag_off = rte_be_to_cpu_16(ipv4_hdr->fragment_offset);
outer_ip_id = outer_is_atomic ? 0 :
rte_be_to_cpu_16(outer_ipv4_hdr->packet_id);
frag_off = rte_be_to_cpu_16(ipv4_hdr->fragment_offset);
- is_atomic = (frag_off &
IPV4_HDR_DF_FLAG) ==
IPV4_HDR_DF_FLAG;
+ is_atomic = (frag_off &
RTE_IPV4_HDR_DF_FLAG) == RTE_
IPV4_HDR_DF_FLAG;
ip_id = is_atomic ? 0 : rte_be_to_cpu_16(ipv4_hdr->packet_id);
sent_seq = rte_be_to_cpu_32(tcp_hdr->sent_seq);
ip_id = is_atomic ? 0 : rte_be_to_cpu_16(ipv4_hdr->packet_id);
sent_seq = rte_be_to_cpu_32(tcp_hdr->sent_seq);