Skip to content

Commit

Permalink
Temporarily patch pna code.
Browse files Browse the repository at this point in the history
  • Loading branch information
fruffy committed Jul 12, 2023
1 parent be3c011 commit 93eb400
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions testdata/p4_16_samples/dash/dash-pipeline-pna.p4
Original file line number Diff line number Diff line change
Expand Up @@ -370,9 +370,10 @@ action nvgre_encap(inout headers_t hdr, in EthernetAddress underlay_dmac, in Eth
hdr.ipv4.ihl = 5;
hdr.ipv4.diffserv = 0;
bit<16> inner_ip_len = 0;
if (hdr.inner_ipv4.isValid()) {
inner_ip_len = inner_ip_len + hdr.inner_ipv4.total_len;
}
// This code is non-functional.
// if (hdr.inner_ipv4.isValid()) {
// inner_ip_len = inner_ip_len + hdr.inner_ipv4.total_len;
// }
if (hdr.inner_ipv6.isValid()) {
inner_ip_len = inner_ip_len + IPV6_HDR_SIZE + hdr.inner_ipv6.payload_length;
}
Expand Down

0 comments on commit 93eb400

Please sign in to comment.