* [dts] [PATCH] /tests/TestSuite_nvgre : add ipv6 detect and ipv6checksum for CVL25gand100g nic Add ipv6 detect case and ipv6 checksum offload case for the CVL 25g and 100g nic test Add CVL25G and 100g nic support default none vector
@ 2019-08-20 2:05 zhiwei.he
2019-08-20 3:07 ` Lin, Xueqin
0 siblings, 1 reply; 2+ messages in thread
From: zhiwei.he @ 2019-08-20 2:05 UTC (permalink / raw)
To: dts; +Cc: zhiwei.he
From: "zhiwei.he" <zhiwei.he@intel.com>
Signed-off-by: zhiwei.he <zhiwei.he@intel.com>
---
tests/TestSuite_nvgre.py | 57 +++++++++++++++++++++++++++++++++++++++++++-----
1 file changed, 52 insertions(+), 5 deletions(-)
diff --git a/tests/TestSuite_nvgre.py b/tests/TestSuite_nvgre.py
index 62aac3a..2fd304a 100644
--- a/tests/TestSuite_nvgre.py
+++ b/tests/TestSuite_nvgre.py
@@ -93,8 +93,8 @@ class NvgreTestConfig(object):
self.outer_ip_dst = '192.168.1.2'
self.outer_ip_invalid = 0
- self.outer_ip6_src = 'N/A'
- self.outer_ip6_dst = 'N/A'
+ self.outer_ip6_src = 'FE80:0:0:0:0:0:0:0'
+ self.outer_ip6_dst = 'FE80:0:0:0:0:0:0:1'
self.outer_ip6_invalid = 0
"""
gre info
@@ -150,8 +150,8 @@ class NvgreTestConfig(object):
self.inner_ip_dst = '192.168.2.2'
self.inner_ip_invalid = 0
- self.inner_ip6_src = 'N/A'
- self.inner_ip6_dst = 'N/A'
+ self.inner_ip6_src = 'FE80:0:0:0:0:0:0:0'
+ self.inner_ip6_dst = 'FE80:0:0:0:0:0:0:1'
self.inner_ip6_invalid = 0
self.inner_l4_type = 'UDP'
@@ -361,10 +361,12 @@ class TestNvgre(TestCase):
nvgre Prerequisites
"""
# this feature only enable in FVL now
- if self.nic in ["fortville_eagle", "fortville_spirit", "fortville_spirit_single", "fortville_25g", "fortpark_TLV", "cavium_a063", "cavium_a064"]:
+ if self.nic in [ "fortville_eagle", "fortville_spirit", "fortville_spirit_single", "fortville_25g", "fortpark_TLV", "cavium_a063", "cavium_a064"]:
self.compile_switch = 'CONFIG_RTE_LIBRTE_I40E_INC_VECTOR'
elif self.nic in ["sageville", "sagepond"]:
self.compile_switch = 'CONFIG_RTE_IXGBE_INC_VECTOR'
+ elif self.nic in ["columbiaville_25g","columbiaville_100g"]:
+ print "CVL support default none VECTOR"
else:
self.verify(False, "%s not support NVGRE case" % self.nic)
# Based on h/w type, choose how many ports to use
@@ -616,7 +618,52 @@ class TestNvgre(TestCase):
# verify saved pcap checksum same to expected checksum
for key in chksums_default:
self.verify(chksums[key] == chksums_default[key], "%s not matched to %s" % (key, chksums_default[key]))
+ def test_nvgre_ipv6(self):
+ """
+ verify nvgre packet with ipv6
+ """
+ outer_l3_type = "IPv6"
+ inner_l3_type = "IPv6"
+ outer_ip6_src = 'FE80:0:0:0:0:0:0:0'
+ outer_ip6_dst = 'FE80:0:0:0:0:0:0:1'
+ inner_ip6_src = 'FE80:0:0:0:0:0:0:0'
+ inner_ip6_dst = 'FE80:0:0:0:0:0:0:1'
+ # check no nvgre packet
+ self.nvgre_detect(outer_l3_type = "IPv6", inner_l3_type="IPv6", outer_ip_proto=0xFF)
+ # check nvgre + IP inner packet
+ self.nvgre_detect(outer_l3_type = "IPv6", inner_l3_type="IPv6", inner_l4_type='None')
+ # check nvgre + udp inner packet
+ self.nvgre_detect(outer_l3_type = "IPv6", inner_l3_type="IPv6", inner_l4_type='TCP')
+ # check nvgre + SCTP inner packet
+ self.nvgre_detect(outer_l3_type = "IPv6", inner_l3_type="IPv6", inner_l4_type='SCTP')
+ # check nvgre + UDP inner packet
+ self.nvgre_detect(outer_l3_type = "IPv6", inner_l3_type="IPv6", inner_l4_type='UDP')
+ # check nvgre + vlan inner packet
+ self.nvgre_detect(outer_l3_type = "IPv6", inner_l3_type="IPv6", outer_vlan=1)
+ # check vlan nvgre + vlan inner packet
+ self.nvgre_detect(outer_l3_type = "IPv6", inner_l3_type="IPv6", outer_vlan=1, inner_vlan=1)
+
+ def test_nvgre_ipv6_checksum_offload(self):
+ outer_l3_type = "IPv6"
+ inner_l3_type = "IPv6"
+ outer_ip6_src = 'FE80:0:0:0:0:0:0:0'
+ outer_ip6_dst = 'FE80:0:0:0:0:0:0:1'
+ inner_ip6_src = 'FE80:0:0:0:0:0:0:0'
+ inner_ip6_dst = 'FE80:0:0:0:0:0:0:1'
+ # check nvgre packet + inner ip checksum invalid
+ self.nvgre_checksum(outer_l3_type = "IPv6", inner_l3_type="IPv6", inner_l4_invalid=1)
+ # check nvgre packet + inner tcp checksum invalid
+ self.nvgre_checksum(outer_l3_type = "IPv6", inner_l3_type="IPv6", inner_l4_invalid=1, inner_l4_type='TCP')
+ #check nvgre packet + inner sctp checksum invalid
+ self.nvgre_checksum(outer_l3_type = "IPv6", inner_l3_type="IPv6", inner_l4_invalid=1, inner_l4_type='SCTP')
+ # check vlan nvgre packet + inner vlan + inner udp checksum invalid
+ self.nvgre_checksum(outer_l3_type = "IPv6", inner_l3_type="IPv6", outer_vlan=1, inner_l4_invalid=1, inner_l4_type='UDP')
+ # check vlan nvgre packet + inner vlan + inner tcp checksum invalid
+ self.nvgre_checksum(outer_l3_type = "IPv6", inner_l3_type="IPv6", outer_vlan=1, inner_l4_invalid=1, inner_l4_type='TCP')
+ # check vlan nvgre packet + inner vlan + inner sctp checksum invalid
+ self.nvgre_checksum(outer_l3_type = "IPv6", inner_l3_type="IPv6", outer_vlan=1, inner_l4_invalid=1, inner_l4_type='SCTP')
+
def test_nvgre_ipv4(self):
"""
verify nvgre packet with ipv4
--
1.8.3.1
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [dts] [PATCH] /tests/TestSuite_nvgre : add ipv6 detect and ipv6checksum for CVL25gand100g nic Add ipv6 detect case and ipv6 checksum offload case for the CVL 25g and 100g nic test Add CVL25G and 100g nic support default none vector
2019-08-20 2:05 [dts] [PATCH] /tests/TestSuite_nvgre : add ipv6 detect and ipv6checksum for CVL25gand100g nic Add ipv6 detect case and ipv6 checksum offload case for the CVL 25g and 100g nic test Add CVL25G and 100g nic support default none vector zhiwei.he
@ 2019-08-20 3:07 ` Lin, Xueqin
0 siblings, 0 replies; 2+ messages in thread
From: Lin, Xueqin @ 2019-08-20 3:07 UTC (permalink / raw)
To: He, Zhiwei, dts; +Cc: He, Zhiwei
Patch title is too long, you could put some explanation in the comment.
Some comment as below.
Best regards,
Xueqin
> -----Original Message-----
> From: dts [mailto:dts-bounces@dpdk.org] On Behalf Of zhiwei.he
> Sent: Tuesday, August 20, 2019 10:06 AM
> To: dts@dpdk.org
> Cc: He, Zhiwei <zhiwei.he@intel.com>
> Subject: [dts] [PATCH] /tests/TestSuite_nvgre : add ipv6 detect and
> ipv6checksum for CVL25gand100g nic Add ipv6 detect case and ipv6
> checksum offload case for the CVL 25g and 100g nic test Add CVL25G and
> 100g nic support default none vector
>
> From: "zhiwei.he" <zhiwei.he@intel.com>
>
> Signed-off-by: zhiwei.he <zhiwei.he@intel.com>
> ---
> tests/TestSuite_nvgre.py | 57
> +++++++++++++++++++++++++++++++++++++++++++-----
> 1 file changed, 52 insertions(+), 5 deletions(-)
>
> diff --git a/tests/TestSuite_nvgre.py b/tests/TestSuite_nvgre.py index
> 62aac3a..2fd304a 100644
> --- a/tests/TestSuite_nvgre.py
> +++ b/tests/TestSuite_nvgre.py
> @@ -93,8 +93,8 @@ class NvgreTestConfig(object):
> self.outer_ip_dst = '192.168.1.2'
> self.outer_ip_invalid = 0
>
> - self.outer_ip6_src = 'N/A'
> - self.outer_ip6_dst = 'N/A'
> + self.outer_ip6_src = 'FE80:0:0:0:0:0:0:0'
> + self.outer_ip6_dst = 'FE80:0:0:0:0:0:0:1'
> self.outer_ip6_invalid = 0
> """
> gre info
> @@ -150,8 +150,8 @@ class NvgreTestConfig(object):
> self.inner_ip_dst = '192.168.2.2'
> self.inner_ip_invalid = 0
>
> - self.inner_ip6_src = 'N/A'
> - self.inner_ip6_dst = 'N/A'
> + self.inner_ip6_src = 'FE80:0:0:0:0:0:0:0'
> + self.inner_ip6_dst = 'FE80:0:0:0:0:0:0:1'
> self.inner_ip6_invalid = 0
>
> self.inner_l4_type = 'UDP'
> @@ -361,10 +361,12 @@ class TestNvgre(TestCase):
> nvgre Prerequisites
> """
> # this feature only enable in FVL now
> - if self.nic in ["fortville_eagle", "fortville_spirit", "fortville_spirit_single",
> "fortville_25g", "fortpark_TLV", "cavium_a063", "cavium_a064"]:
> + if self.nic in [ "fortville_eagle", "fortville_spirit", "fortville_spirit_single",
> "fortville_25g", "fortpark_TLV", "cavium_a063", "cavium_a064"]:
> self.compile_switch = 'CONFIG_RTE_LIBRTE_I40E_INC_VECTOR'
> elif self.nic in ["sageville", "sagepond"]:
> self.compile_switch = 'CONFIG_RTE_IXGBE_INC_VECTOR'
> + elif self.nic in ["columbiaville_25g","columbiaville_100g"]:
> + print "CVL support default none VECTOR"
> else:
> self.verify(False, "%s not support NVGRE case" % self.nic)
> # Based on h/w type, choose how many ports to use @@ -616,7 +618,52
> @@ class TestNvgre(TestCase):
> # verify saved pcap checksum same to expected checksum
> for key in chksums_default:
> self.verify(chksums[key] == chksums_default[key], "%s not matched
> to %s" % (key, chksums_default[key]))
> + def test_nvgre_ipv6(self):
> + """
> + verify nvgre packet with ipv6
> + """
> + outer_l3_type = "IPv6"
> + inner_l3_type = "IPv6"
> + outer_ip6_src = 'FE80:0:0:0:0:0:0:0'
> + outer_ip6_dst = 'FE80:0:0:0:0:0:0:1'
> + inner_ip6_src = 'FE80:0:0:0:0:0:0:0'
> + inner_ip6_dst = 'FE80:0:0:0:0:0:0:1'
>
[xueqin] have defined self.inner_ip6_src, self.inner_ipv6_dst, self.outer_ipv6_src, self.outer_ipv6_dst above, why repeat to add ipv6 src, dst... similar code here?
Are you sure code could be called? Pls check create_pcap() code.
> + # check no nvgre packet
> + self.nvgre_detect(outer_l3_type = "IPv6", inner_l3_type="IPv6",
> outer_ip_proto=0xFF)
[xueqin] if run no nvgre packet, should only set outer_ip_proto=0xFF.
outer_l3_type = "IPv6", inner_l3_type="IPv6 are for nvgre packet.
> + # check nvgre + IP inner packet
[xueqin] below is ipv6 inner packet.
> + self.nvgre_detect(outer_l3_type = "IPv6", inner_l3_type="IPv6",
> inner_l4_type='None')
> + # check nvgre + udp inner packet
[xueqin] below is tcp inner packet
> + self.nvgre_detect(outer_l3_type = "IPv6", inner_l3_type="IPv6",
> inner_l4_type='TCP')
> + # check nvgre + SCTP inner packet
> + self.nvgre_detect(outer_l3_type = "IPv6", inner_l3_type="IPv6",
> inner_l4_type='SCTP')
> + # check nvgre + UDP inner packet
> + self.nvgre_detect(outer_l3_type = "IPv6", inner_l3_type="IPv6",
> inner_l4_type='UDP')
> + # check nvgre + vlan inner packet
> + self.nvgre_detect(outer_l3_type = "IPv6", inner_l3_type="IPv6",
> outer_vlan=1)
> + # check vlan nvgre + vlan inner packet
> + self.nvgre_detect(outer_l3_type = "IPv6", inner_l3_type="IPv6",
> + outer_vlan=1, inner_vlan=1)
> +
> + def test_nvgre_ipv6_checksum_offload(self):
> + outer_l3_type = "IPv6"
> + inner_l3_type = "IPv6"
> + outer_ip6_src = 'FE80:0:0:0:0:0:0:0'
> + outer_ip6_dst = 'FE80:0:0:0:0:0:0:1'
> + inner_ip6_src = 'FE80:0:0:0:0:0:0:0'
> + inner_ip6_dst = 'FE80:0:0:0:0:0:0:1'
[xueqin] same as above.
> + # check nvgre packet + inner ip checksum invalid
[xueqin] inner ipv6.
> + self.nvgre_checksum(outer_l3_type = "IPv6", inner_l3_type="IPv6",
> inner_l4_invalid=1)
> + # check nvgre packet + inner tcp checksum invalid
> + self.nvgre_checksum(outer_l3_type = "IPv6", inner_l3_type="IPv6",
> inner_l4_invalid=1, inner_l4_type='TCP')
> + #check nvgre packet + inner sctp checksum invalid
> + self.nvgre_checksum(outer_l3_type = "IPv6", inner_l3_type="IPv6",
> inner_l4_invalid=1, inner_l4_type='SCTP')
> + # check vlan nvgre packet + inner vlan + inner udp checksum invalid
> + self.nvgre_checksum(outer_l3_type = "IPv6", inner_l3_type="IPv6",
> outer_vlan=1, inner_l4_invalid=1, inner_l4_type='UDP')
> + # check vlan nvgre packet + inner vlan + inner tcp checksum invalid
> + self.nvgre_checksum(outer_l3_type = "IPv6", inner_l3_type="IPv6",
> outer_vlan=1, inner_l4_invalid=1, inner_l4_type='TCP')
> + # check vlan nvgre packet + inner vlan + inner sctp checksum invalid
> + self.nvgre_checksum(outer_l3_type = "IPv6",
> + inner_l3_type="IPv6", outer_vlan=1, inner_l4_invalid=1,
> + inner_l4_type='SCTP')
> +
> def test_nvgre_ipv4(self):
> """
> verify nvgre packet with ipv4
> --
> 1.8.3.1
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2019-08-20 3:07 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-08-20 2:05 [dts] [PATCH] /tests/TestSuite_nvgre : add ipv6 detect and ipv6checksum for CVL25gand100g nic Add ipv6 detect case and ipv6 checksum offload case for the CVL 25g and 100g nic test Add CVL25G and 100g nic support default none vector zhiwei.he
2019-08-20 3:07 ` Lin, Xueqin
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).