From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 646D8A0566; Wed, 11 Mar 2020 05:41:31 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 52F1E1BF94; Wed, 11 Mar 2020 05:41:31 +0100 (CET) Received: from mga04.intel.com (mga04.intel.com [192.55.52.120]) by dpdk.org (Postfix) with ESMTP id EF7741BF7F for ; Wed, 11 Mar 2020 05:41:29 +0100 (CET) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga003.jf.intel.com ([10.7.209.27]) by fmsmga104.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 10 Mar 2020 21:41:28 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.70,539,1574150400"; d="scan'208";a="242559808" Received: from fmsmsx106.amr.corp.intel.com ([10.18.124.204]) by orsmga003.jf.intel.com with ESMTP; 10 Mar 2020 21:41:28 -0700 Received: from fmsmsx158.amr.corp.intel.com (10.18.116.75) by FMSMSX106.amr.corp.intel.com (10.18.124.204) with Microsoft SMTP Server (TLS) id 14.3.439.0; Tue, 10 Mar 2020 21:41:27 -0700 Received: from shsmsx103.ccr.corp.intel.com (10.239.4.69) by fmsmsx158.amr.corp.intel.com (10.18.116.75) with Microsoft SMTP Server (TLS) id 14.3.439.0; Tue, 10 Mar 2020 21:41:27 -0700 Received: from shsmsx101.ccr.corp.intel.com ([169.254.1.43]) by SHSMSX103.ccr.corp.intel.com ([169.254.4.137]) with mapi id 14.03.0439.000; Wed, 11 Mar 2020 12:41:24 +0800 From: "Tu, Lijuan" To: Thinh Tran , "dts@dpdk.org" CC: "drc@linux.vnet.ibm.com" Thread-Topic: [dts] [PATCH] change execution path of DPDK examples Thread-Index: AQHV8Xb8uGZEa4yjfUq6gH5ADsVRkahC267w Date: Wed, 11 Mar 2020 04:41:23 +0000 Message-ID: <8CE3E05A3F976642AAB0F4675D0AD20E0BBEBA4E@SHSMSX101.ccr.corp.intel.com> References: <20200303161459.118730-1-thinhtr@linux.vnet.ibm.com> In-Reply-To: <20200303161459.118730-1-thinhtr@linux.vnet.ibm.com> Accept-Language: zh-CN, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-product: dlpe-windows dlp-version: 11.2.0.6 dlp-reaction: no-action x-originating-ip: [10.239.127.40] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [dts] [PATCH] change execution path of DPDK examples X-BeenThere: dts@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: test suite reviews and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dts-bounces@dpdk.org Sender: "dts" Applied, thanks > -----Original Message----- > From: dts [mailto:dts-bounces@dpdk.org] On Behalf Of Thinh Tran > Sent: Wednesday, March 4, 2020 12:15 AM > To: dts@dpdk.org > Cc: drc@linux.vnet.ibm.com; Thinh Tran > Subject: [dts] [PATCH] change execution path of DPDK examples >=20 > - There is a different way the DPDK examples getting built. > In their Makefile, if the libdpdk package is installed > ... > # Build using pkg-config variables if possible > ifeq ($(shell pkg-config --exists libdpdk && echo 0),0) > ... > their binaries will be created under ./examples//build/ > if not, they will be under both ./examples//build/ and > ./examples//build/app/ > - DTS test scripts should pick the common path of these binaries >=20 >=20 > Signed-off-by: Thinh Tran > --- > tests/TestSuite_cbdma.py | 2 +- > tests/TestSuite_cmdline.py | 2 +- > tests/TestSuite_eventdev_pipeline.py | 2 +- > tests/TestSuite_hello_world.py | 4 ++-- > tests/TestSuite_kni.py | 2 +- > tests/TestSuite_l2fwd.py | 6 +++--- > tests/TestSuite_pvp_vhost_user_built_in_net_driver.py | 2 +- > tests/TestSuite_short_live.py | 4 ++-- > tests/TestSuite_timer.py | 2 +- > tests/TestSuite_vhost_enqueue_interrupt.py | 2 +- > tests/TestSuite_vhost_event_idx_interrupt.py | 2 +- > tests/TestSuite_vhost_virtio_pmd_interrupt.py | 2 +- > 12 files changed, 16 insertions(+), 16 deletions(-) >=20 > diff --git a/tests/TestSuite_cbdma.py b/tests/TestSuite_cbdma.py index > fd9aec9..d7ca3ae 100644 > --- a/tests/TestSuite_cbdma.py > +++ b/tests/TestSuite_cbdma.py > @@ -140,7 +140,7 @@ class TestCBDMA(TestCase): > ''' > # flush other output > self.dut.get_session_output(timeout=3D1) > - cmd_command =3D './examples/ioat/build/app/ioatfwd ' + eal_param= s + > \ > + cmd_command =3D './examples/ioat/build/ioatfwd ' + eal_params + = \ > '-- -p %s -q %d %s -c %s' % (hex(port_info), > self.cbdma_ioat_dev_num/self.cbdma_nic_dev_num, ma= c_info, > self.cbdma_copy_mode) diff --git a/tests/TestSuite= _cmdline.py > b/tests/TestSuite_cmdline.py index 9bf6850..ab30d8e 100644 > --- a/tests/TestSuite_cmdline.py > +++ b/tests/TestSuite_cmdline.py > @@ -57,7 +57,7 @@ class TestCmdline(TestCase): > # Run cmdline app > cores =3D self.dut.get_core_list('1S/1C/1T') > coreMask =3D utils.create_mask(cores) > - self.dut.send_expect("./examples/cmdline/build/app/cmdline -n 1 = -c " > + coreMask, "> ", 10) > + self.dut.send_expect("./examples/cmdline/build/cmdline -n 1 -c > + " + coreMask, "> ", 10) >=20 > def set_up(self): > """ > diff --git a/tests/TestSuite_eventdev_pipeline.py > b/tests/TestSuite_eventdev_pipeline.py > index 4818fc4..b0b3b8b 100644 > --- a/tests/TestSuite_eventdev_pipeline.py > +++ b/tests/TestSuite_eventdev_pipeline.py > @@ -98,7 +98,7 @@ class TestEventdevPipeline(TestCase): > eal_params =3D self.dut.create_eal_parameters(cores=3Dself.core_= list, > ports=3D[self.dut.ports_info[0]['pci']]) > command_line =3D "taskset -c %s " + self.app_command + \ > - "/build/app/eventdev_pipeline %s " + \ > + "/build/eventdev_pipeline %s " + \ > "--vdev event_sw0 -- -r%s -t%s -e%s -w %s -s1 -n0= -c32 - > W1000 %s -D" > command_line =3D command_line % ( > self.taskset_core_list, eal_params, self.core_mask_r= x, diff --git > a/tests/TestSuite_hello_world.py b/tests/TestSuite_hello_world.py index > 3f29e60..3d58e2a 100644 > --- a/tests/TestSuite_hello_world.py > +++ b/tests/TestSuite_hello_world.py > @@ -66,7 +66,7 @@ class TestHelloWorld(TestCase): > # get the mask for the first core > cores =3D self.dut.get_core_list('1S/1C/1T') > coreMask =3D utils.create_mask(cores) > - cmdline =3D "./examples/helloworld/build/app/helloworld -n 1 -c = " + > coreMask > + cmdline =3D "./examples/helloworld/build/helloworld -n 1 -c " + > + coreMask > out =3D self.dut.send_expect(cmdline, "# ", 30) > self.verify("hello from core %s" % cores[0] in out, "EAL not sta= rted on > core%s" % cores[0]) >=20 > @@ -87,7 +87,7 @@ class TestHelloWorld(TestCase): >=20 > coreMask =3D utils.create_mask(cores[:available_max_lcore - 1]) >=20 > - cmdline =3D "./examples/helloworld/build/app/helloworld -n 1 -c = " + > coreMask > + cmdline =3D "./examples/helloworld/build/helloworld -n 1 -c " + > + coreMask > out =3D self.dut.send_expect(cmdline, "# ", 50) > for i in range(available_max_lcore - 1): > self.verify("hello from core %s" % cores[i] in out, "EAL not= started on > core%s" % cores[i]) diff --git a/tests/TestSuite_kni.py b/tests/TestSuite= _kni.py > index f611383..3cbd457 100644 > --- a/tests/TestSuite_kni.py > +++ b/tests/TestSuite_kni.py > @@ -341,7 +341,7 @@ class TestKni(TestCase): > config_param =3D self.build_config_param() >=20 > out_kni =3D self.dut.send_expect( > - './examples/kni/build/app/kni -c %s -n %d -- -P -p %s %s -m = &' % > + './examples/kni/build/kni -c %s -n %d -- -P -p %s %s -m &' > + % > (core_mask, self.dut.get_memory_channels(), port_mask, > config_param), > "Link Up", 20) >=20 > diff --git a/tests/TestSuite_l2fwd.py b/tests/TestSuite_l2fwd.py index > 382ec60..4a47c02 100644 > --- a/tests/TestSuite_l2fwd.py > +++ b/tests/TestSuite_l2fwd.py > @@ -108,7 +108,7 @@ class TestL2fwd(TestCase): > port_mask =3D utils.create_mask([self.dut_ports[0], self.dut_por= ts[1]]) > eal_params =3D self.dut.create_eal_parameters() >=20 > - self.dut.send_expect("./examples/l2fwd/build/app/l2fwd %s -- -q = 8 - > p %s &" % (eal_params, port_mask), > + self.dut.send_expect("./examples/l2fwd/build/l2fwd %s -- -q 8 > + -p %s &" % (eal_params, port_mask), > "L2FWD: entering main loop", 60) >=20 > for i in [0, 1]: > @@ -144,7 +144,7 @@ class TestL2fwd(TestCase): > eal_params =3D self.dut.create_eal_parameters(cores=3Dcores) > for queues in self.test_queues: >=20 > - command_line =3D "./examples/l2fwd/build/app/l2fwd %s -- -q= %s - > p %s &" % \ > + command_line =3D "./examples/l2fwd/build/l2fwd %s -- -q %s > + -p %s &" % \ > (eal_params, str(queues['queues']), port_mask= ) >=20 > self.dut.send_expect(command_line, "L2FWD: entering main loo= p", > 60) @@ -193,7 +193,7 @@ class TestL2fwd(TestCase): >=20 > for queues in self.test_queues: >=20 > - command_line =3D "./examples/l2fwd/build/app/l2fwd %s --= -q %s - > p %s &" % \ > + command_line =3D "./examples/l2fwd/build/l2fwd %s -- -q > + %s -p %s &" % \ > (eal_params, str(queues['queues']), port_mask) >=20 > # self.dut.send_expect(command_line, "memory mapped", 60) > diff --git a/tests/TestSuite_pvp_vhost_user_built_in_net_driver.py > b/tests/TestSuite_pvp_vhost_user_built_in_net_driver.py > index 528f0d7..cfdd704 100644 > --- a/tests/TestSuite_pvp_vhost_user_built_in_net_driver.py > +++ b/tests/TestSuite_pvp_vhost_user_built_in_net_driver.py > @@ -172,7 +172,7 @@ class TestPVPVhostUserBuiltInNetDriver(TestCase): > """ > self.dut.send_expect("rm -rf ./vhost.out", "#") > eal_param =3D self.dut.create_eal_parameters(socket=3Dself.ports= _socket, > cores=3Dself.core_list_vhost_user, prefix=3D'vhost') > - command_line_client =3D "./examples/vhost/build/app/vhost-switch= " + > eal_param + ' -- -p 0x1 --mergeable 0 --vm2vm 1 --builtin-net-driver --so= cket- > file ./vhost-net> ./vhost.out &' > + command_line_client =3D "./examples/vhost/build/vhost-switch " + > eal_param + ' -- -p 0x1 --mergeable 0 --vm2vm 1 --builtin-net-driver --so= cket- > file ./vhost-net> ./vhost.out &' > self.vhost_switch.send_expect(command_line_client, "# ", 120) > time.sleep(15) > try: > diff --git a/tests/TestSuite_short_live.py b/tests/TestSuite_short_live.p= y > index 31adf0d..a4358ff 100644 > --- a/tests/TestSuite_short_live.py > +++ b/tests/TestSuite_short_live.py > @@ -193,7 +193,7 @@ class TestShortLiveApp(TestCase): > for i in range(repeat_time): > #dpdk start > print("clean_up_with_signal_l2fwd round %d" % (i + 1)) > - self.dut.send_expect("./examples/l2fwd/build/app/l2fwd -n 4 = -c 0xf - > - -p 0x3 &", "L2FWD: entering main loop", 60) > + self.dut.send_expect("./examples/l2fwd/build/l2fwd -n 4 -c > + 0xf -- -p 0x3 &", "L2FWD: entering main loop", 60) > self.check_forwarding([0, 1], self.nic) >=20 > # kill with different Signal @@ -209,7 +209,7 @@ class > TestShortLiveApp(TestCase): > for i in range(repeat_time): > #dpdk start > print("clean_up_with_signal_l3fwd round %d" % (i + 1)) > - self.dut.send_expect("./examples/l3fwd/build/app/l3fwd -n 4 = -c 0xf - > - -p 0x3 --config=3D'(0,0,1),(1,0,2)' &", "L3FWD: entering main loop", 12= 0) > + self.dut.send_expect("./examples/l3fwd/build/l3fwd -n 4 -c > + 0xf -- -p 0x3 --config=3D'(0,0,1),(1,0,2)' &", "L3FWD: entering main > + loop", 120) > self.check_forwarding([0, 0], self.nic) >=20 > # kill with different Signal diff --git a/tests/TestSuite_ti= mer.py > b/tests/TestSuite_timer.py index f73bb77..4d0434e 100644 > --- a/tests/TestSuite_timer.py > +++ b/tests/TestSuite_timer.py > @@ -72,7 +72,7 @@ class TestTimer(TestCase): > coreMask =3D utils.create_mask(cores) >=20 > # run timer on the background > - cmdline =3D "./examples/timer/build/app/timer -n 1 -c " + coreMa= sk + " > &" > + cmdline =3D "./examples/timer/build/timer -n 1 -c " + coreMask += " &" >=20 > self.dut.send_expect(cmdline, "# ", 1) > time.sleep(15) > diff --git a/tests/TestSuite_vhost_enqueue_interrupt.py > b/tests/TestSuite_vhost_enqueue_interrupt.py > index da325d3..509c7f3 100644 > --- a/tests/TestSuite_vhost_enqueue_interrupt.py > +++ b/tests/TestSuite_vhost_enqueue_interrupt.py > @@ -108,7 +108,7 @@ class TestVhostEnqueueInterrupt(TestCase): > info =3D {'core': self.core_list_l3fwd[i], 'port': 0, 'queue= ': i} > self.verify_info.append(info) >=20 > - example_cmd =3D "./examples/l3fwd-power/build/app/l3fwd-power " > + example_cmd =3D "./examples/l3fwd-power/build/l3fwd-power " > vdev =3D [r"'net_vhost0,iface=3Dvhost-net,queues=3D%d,client=3D1= '" % > self.queues] > para =3D " -- -p 0x1 --parse-ptype 1 --config '%s' " % config_in= fo > eal_params =3D self.dut.create_eal_parameters(cores=3Dself.core_= list_l3fwd, > no_pci=3DTrue, ports=3D[self.pci_info], vdevs=3Dvdev) diff --git > a/tests/TestSuite_vhost_event_idx_interrupt.py > b/tests/TestSuite_vhost_event_idx_interrupt.py > index 38cdc77..fb7da60 100644 > --- a/tests/TestSuite_vhost_event_idx_interrupt.py > +++ b/tests/TestSuite_vhost_event_idx_interrupt.py > @@ -106,7 +106,7 @@ class TestVhostEventIdxInterrupt(TestCase): >=20 > port_info =3D "0x1" if self.vm_num =3D=3D 1 else "0x3" >=20 > - example_para =3D "./examples/l3fwd-power/build/app/l3fwd-power " > + example_para =3D "./examples/l3fwd-power/build/l3fwd-power " > para =3D " --log-level=3D9 %s -- -p %s --parse-ptype 1 --config = '%s'" % > (vdev_info, port_info, config_info) > eal_params =3D self.dut.create_eal_parameters(cores=3Dself.core_= list_l3fwd, > no_pci=3DTrue) > command_line_client =3D example_para + eal_params + para diff --= git > a/tests/TestSuite_vhost_virtio_pmd_interrupt.py > b/tests/TestSuite_vhost_virtio_pmd_interrupt.py > index bf97a91..5e6437e 100644 > --- a/tests/TestSuite_vhost_virtio_pmd_interrupt.py > +++ b/tests/TestSuite_vhost_virtio_pmd_interrupt.py > @@ -144,7 +144,7 @@ class TestVhostVirtioPmdInterrupt(TestCase): > info =3D {'core': core_list_l3fwd[queue], 'port': 0, 'queue'= : queue} > self.verify_info.append(info) >=20 > - command_client =3D "./examples/l3fwd-power/build/app/l3fwd-power= " > + \ > + command_client =3D "./examples/l3fwd-power/build/l3fwd-power " + > + \ > "-c %s -n 4 --log-level=3D'user1,7' -- -p 1 -P = " + \ > "--config '%s' --no-numa --parse-ptype " > command_line_client =3D command_client % (core_mask_l3fwd, > config_info) > -- > 2.17.0