aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/srv6-ad
diff options
context:
space:
mode:
authorpcamaril <pcamaril@cisco.com>2020-02-04 08:36:51 +0100
committerNeale Ranns <nranns@cisco.com>2020-02-11 16:25:41 +0000
commit30e7671c85087b5781a34bde45ef3846f5de8c17 (patch)
tree532f76c9d61e8ed9a0967cd0bccaf552279f7dbe /src/plugins/srv6-ad
parent619179cfcdb087acb0864d273c4fbd3b7396974c (diff)
sr: update NH value for Ethernet payloads
Upon encapsulation of L2 frames, IETF has replaced the NextHeader value from 59 (IPv6 No Next Header) to 143 (Ethernet). https://www.iana.org/assignments/protocol-numbers/protocol-numbers.xhtml Type: fix Signed-off-by: pcamaril <pcamaril@cisco.com> Change-Id: I88aa5590c81d16700ff7a0bbe6337e113179496e Signed-off-by: pcamaril <pcamaril@cisco.com>
Diffstat (limited to 'src/plugins/srv6-ad')
-rw-r--r--src/plugins/srv6-ad/node.c4
-rw-r--r--src/plugins/srv6-ad/test/test_srv6_ad.py2
2 files changed, 3 insertions, 3 deletions
diff --git a/src/plugins/srv6-ad/node.c b/src/plugins/srv6-ad/node.c
index dbd68cf4c98..9d4ea44e19b 100644
--- a/src/plugins/srv6-ad/node.c
+++ b/src/plugins/srv6-ad/node.c
@@ -156,7 +156,7 @@ end_ad_processing (vlib_buffer_t * b0,
/* Make sure next header is valid */
if (PREDICT_FALSE (next_hdr != IP_PROTOCOL_IPV6 &&
next_hdr != IP_PROTOCOL_IP_IN_IP &&
- next_hdr != IP_PROTOCOL_IP6_NONXT))
+ next_hdr != IP_PROTOCOL_IP6_ETHERNET))
{
return;
}
@@ -175,7 +175,7 @@ end_ad_processing (vlib_buffer_t * b0,
/* Remove IP header and extensions */
vlib_buffer_advance (b0, total_size);
- if (next_hdr == IP_PROTOCOL_IP6_NONXT)
+ if (next_hdr == IP_PROTOCOL_IP6_ETHERNET)
{
/* Set output interface */
vnet_buffer (b0)->sw_if_index[VLIB_TX] = ls0_mem->sw_if_index_out;
diff --git a/src/plugins/srv6-ad/test/test_srv6_ad.py b/src/plugins/srv6-ad/test/test_srv6_ad.py
index 828cb74d0ea..2627df32aa9 100644
--- a/src/plugins/srv6-ad/test/test_srv6_ad.py
+++ b/src/plugins/srv6-ad/test/test_srv6_ad.py
@@ -718,7 +718,7 @@ class TestSRv6(VppTestCase):
p = IPv6(src=srcaddr, dst=sidlist[segleft]) / \
IPv6ExtHdrSegmentRouting(addresses=sidlist,
- segleft=segleft, nh=59) / \
+ segleft=segleft, nh=143) / \
eth
return p