test suite reviews and discussions
 help / color / mirror / Atom feed
From: michael.luo@intel.com
To: dts@dpdk.org
Subject: [dts] [PATCH] tests/pmdrss_hash: set the rss type of ipv6-sctp as sctp
Date: Thu,  8 Feb 2018 07:22:08 +0800	[thread overview]
Message-ID: <1518045728-48385-1-git-send-email-michael.luo@intel.com> (raw)

From: Luo Gaoliang <michael.luo@intel.com>

The rss type of the flow type ipv6-sctp should be set as sctp instead of ip.
And it need to explicitly set the next header nh=132 for scapy to send ipv6
sctp packets. Otherwise, the scapy below the version 2.3.2 will send ipv6
sctp packets with unknown next header(nh=59).

Signed-off-by: Luo Gaoliang <michael.luo@intel.com>
---
 tests/TestSuite_pmdrss_hash.py | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/tests/TestSuite_pmdrss_hash.py b/tests/TestSuite_pmdrss_hash.py
index 78e4075..728c427 100644
--- a/tests/TestSuite_pmdrss_hash.py
+++ b/tests/TestSuite_pmdrss_hash.py
@@ -133,7 +133,7 @@ class TestPmdrssHash(TestCase):
                 time.sleep(.5)
         elif tran_type == "ipv6-sctp":
             for i in range(10):
-                packet = r'sendp([Ether(dst="%s", src=get_if_hwaddr("%s"))/IPv6(src="3ffe:2501:200:1fff::%d", dst="3ffe:2501:200:3::%d")/SCTP(sport=1024,dport=1024,tag=1)], iface="%s")' % (
+                packet = r'sendp([Ether(dst="%s", src=get_if_hwaddr("%s"))/IPv6(src="3ffe:2501:200:1fff::%d", dst="3ffe:2501:200:3::%d", nh=132)/SCTP(sport=1024,dport=1024,tag=1)], iface="%s")' % (
                     mac, itf, i + 1, i + 2, itf)
                 self.tester.scapy_append(packet)
                 self.tester.scapy_execute()
@@ -326,12 +326,12 @@ class TestPmdrssHash(TestCase):
                 time.sleep(.5)
         elif tran_type == "ipv6-sctp":
             for i in range(4):
-                packet = r'sendp([Ether(dst="%s")/IPv6(src="3ffe:2501:200:1fff::%d", dst="3ffe:2501:200:3::%d")/SCTP(sport=1024,dport=1025,tag=1)], iface="%s")' % (
+                packet = r'sendp([Ether(dst="%s")/IPv6(src="3ffe:2501:200:1fff::%d", dst="3ffe:2501:200:3::%d", nh=132)/SCTP(sport=1024,dport=1025,tag=1)], iface="%s")' % (
                     mac, i + 1, i + 2, itf)
                 self.tester.scapy_append(packet)
                 self.tester.scapy_execute()
                 time.sleep(.5)
-                packet = r'sendp([Ether(dst="%s")/IPv6(src="3ffe:2501:200:1fff::%d", dst="3ffe:2501:200:3::%d")/SCTP(sport=1025,dport=1024,tag=1)], iface="%s")' % (
+                packet = r'sendp([Ether(dst="%s")/IPv6(src="3ffe:2501:200:1fff::%d", dst="3ffe:2501:200:3::%d", nh=132)/SCTP(sport=1025,dport=1024,tag=1)], iface="%s")' % (
                     mac, i + 2, i + 1, itf)
                 self.tester.scapy_append(packet)
                 self.tester.scapy_execute()
@@ -451,7 +451,7 @@ class TestPmdrssHash(TestCase):
                    # this hash not support in dpdk2.0
                    # 'l2_payload':'ether',
                    'ipv6-other': 'ip',
-                   'ipv6-sctp': 'ip',
+                   'ipv6-sctp': 'sctp',
                    'ipv6-udp': 'udp',
                    'ipv6-tcp': 'tcp',
                    'ipv6-frag': 'ip'
@@ -502,7 +502,7 @@ class TestPmdrssHash(TestCase):
                    # this hash not support in dpdk2.0
                    # 'l2_payload':'ether',
                    'ipv6-other': 'ip',
-                   'ipv6-sctp': 'ip',
+                   'ipv6-sctp': 'sctp',
                    'ipv6-udp': 'udp',
                    'ipv6-tcp': 'tcp',
                    'ipv6-frag': 'ip'
@@ -555,7 +555,7 @@ class TestPmdrssHash(TestCase):
                    # this hass not support in dpdk 2.0
                    # 'l2_payload':'ether',
                    'ipv6-other': 'ip',
-                   'ipv6-sctp': 'ip',
+                   'ipv6-sctp': 'sctp',
                    'ipv6-udp': 'udp',
                    'ipv6-tcp': 'tcp',
                    'ipv6-frag': 'ip'
@@ -612,7 +612,7 @@ class TestPmdrssHash(TestCase):
                    # this hash not support in dpdk2.0
                    # 'l2_payload':'ether',
                    'ipv6-other': 'ip',
-                   'ipv6-sctp': 'ip',
+                   'ipv6-sctp': 'sctp',
                    'ipv6-udp': 'udp',
                    'ipv6-tcp': 'tcp',
                    'ipv6-frag': 'ip'
-- 
2.7.4

             reply	other threads:[~2018-02-07 15:28 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-02-07 23:22 michael.luo [this message]
2018-02-08 13:26 ` Liu, Yong

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1518045728-48385-1-git-send-email-michael.luo@intel.com \
    --to=michael.luo@intel.com \
    --cc=dts@dpdk.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).