test suite reviews and discussions
 help / color / mirror / Atom feed
* [dts] [PATCH] tests/Test_mtu_update:fix only config ports in one side of the machine. Start testpmd with different parameter in mlx4/mlx5
@ 2020-12-22 20:05 David Liu
  2020-12-22 20:18 ` David Liu
  0 siblings, 1 reply; 2+ messages in thread
From: David Liu @ 2020-12-22 20:05 UTC (permalink / raw)
  To: dts; +Cc: lijuan.tu, lylavoie, dliu

---
 tests/TestSuite_mtu_update.py | 12 +++++++++---
 1 file changed, 9 insertions(+), 3 deletions(-)

diff --git a/tests/TestSuite_mtu_update.py b/tests/TestSuite_mtu_update.py
index 6e425dcb..4fe697b4 100644
--- a/tests/TestSuite_mtu_update.py
+++ b/tests/TestSuite_mtu_update.py
@@ -51,8 +51,8 @@ import time
 from test_case import TestCase
 from pktgen import TRANSMIT_CONT
 
-from framework.packet import Packet
-from framework.settings import HEADER_SIZE
+from packet import Packet
+from settings import HEADER_SIZE
 
 ETHER_HEADER_LEN = 18
 IP_HEADER_LEN = 20
@@ -208,6 +208,7 @@ class TestMtuUpdate(TestCase):
         @return: None
         """
         self.admin_tester_port(self.tester.get_local_port(self.tx_port), f"mtu {mtu:d}")
+        self.admin_tester_port(self.tester.get_local_port(self.rx_port), f"mtu {mtu:d}")
     #
     #
     #
@@ -220,7 +221,12 @@ class TestMtuUpdate(TestCase):
         """
         self.set_mtu(packet_size + 1)
 
-        self.pmdout.start_testpmd("Default")
+        if self.kdriver == "mlx5_core" or self.kdriver == "mlx4_core":
+        # Mellanox will need extra options to start testpmd
+            self.pmdout.start_testpmd("Default", "--max-pkt-len=9500 --tx-offloads=0x8000 --enable-scatter -a")
+        else:
+            self.pmdout.start_testpmd("Default")
+        
         self.exec("port stop all")
         self.exec(f"port config mtu 0 {packet_size:d}")
         self.exec(f"port config mtu 1 {packet_size:d}")
-- 
2.17.1


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [dts] [PATCH] tests/Test_mtu_update:fix only config ports in one side of the machine. Start testpmd with different parameter in mlx4/mlx5
  2020-12-22 20:05 [dts] [PATCH] tests/Test_mtu_update:fix only config ports in one side of the machine. Start testpmd with different parameter in mlx4/mlx5 David Liu
@ 2020-12-22 20:18 ` David Liu
  0 siblings, 0 replies; 2+ messages in thread
From: David Liu @ 2020-12-22 20:18 UTC (permalink / raw)
  To: dts; +Cc: Tu, Lijuan, Lincoln Lavoie

[-- Attachment #1: Type: text/plain, Size: 1705 bytes --]

Sorry, forget to signed-off the patch. I will submit another one.

On Tue, Dec 22, 2020 at 3:05 PM David Liu <dliu@iol.unh.edu> wrote:

> ---
>  tests/TestSuite_mtu_update.py | 12 +++++++++---
>  1 file changed, 9 insertions(+), 3 deletions(-)
>
> diff --git a/tests/TestSuite_mtu_update.py b/tests/TestSuite_mtu_update.py
> index 6e425dcb..4fe697b4 100644
> --- a/tests/TestSuite_mtu_update.py
> +++ b/tests/TestSuite_mtu_update.py
> @@ -51,8 +51,8 @@ import time
>  from test_case import TestCase
>  from pktgen import TRANSMIT_CONT
>
> -from framework.packet import Packet
> -from framework.settings import HEADER_SIZE
> +from packet import Packet
> +from settings import HEADER_SIZE
>
>  ETHER_HEADER_LEN = 18
>  IP_HEADER_LEN = 20
> @@ -208,6 +208,7 @@ class TestMtuUpdate(TestCase):
>          @return: None
>          """
>          self.admin_tester_port(self.tester.get_local_port(self.tx_port),
> f"mtu {mtu:d}")
> +        self.admin_tester_port(self.tester.get_local_port(self.rx_port),
> f"mtu {mtu:d}")
>      #
>      #
>      #
> @@ -220,7 +221,12 @@ class TestMtuUpdate(TestCase):
>          """
>          self.set_mtu(packet_size + 1)
>
> -        self.pmdout.start_testpmd("Default")
> +        if self.kdriver == "mlx5_core" or self.kdriver == "mlx4_core":
> +        # Mellanox will need extra options to start testpmd
> +            self.pmdout.start_testpmd("Default", "--max-pkt-len=9500
> --tx-offloads=0x8000 --enable-scatter -a")
> +        else:
> +            self.pmdout.start_testpmd("Default")
> +
>          self.exec("port stop all")
>          self.exec(f"port config mtu 0 {packet_size:d}")
>          self.exec(f"port config mtu 1 {packet_size:d}")
> --
> 2.17.1
>
>

[-- Attachment #2: Type: text/html, Size: 2351 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-12-22 20:19 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-12-22 20:05 [dts] [PATCH] tests/Test_mtu_update:fix only config ports in one side of the machine. Start testpmd with different parameter in mlx4/mlx5 David Liu
2020-12-22 20:18 ` David Liu

test suite reviews and discussions

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://inbox.dpdk.org/dts/0 dts/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 dts dts/ http://inbox.dpdk.org/dts \
		dts@dpdk.org
	public-inbox-index dts

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://inbox.dpdk.org/inbox.dpdk.dts


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git