test suite reviews and discussions
 help / color / mirror / Atom feed
* [dts] [PATCH V1] tests/TestSuite_cbdma:Modify the start IOAT path
@ 2020-09-17  6:09 xizhan4x
  2020-09-17  6:14 ` Zhang, XiX
  2020-09-23  7:31 ` Tu, Lijuan
  0 siblings, 2 replies; 4+ messages in thread
From: xizhan4x @ 2020-09-17  6:09 UTC (permalink / raw)
  To: dts; +Cc: xizhan4x

Modify the start IOAT path supoort meson build

Signed-off-by: xizhan4x <xix.zhang@intel.com>
---
 tests/TestSuite_cbdma.py | 16 ++++++++++------
 1 file changed, 10 insertions(+), 6 deletions(-)

diff --git a/tests/TestSuite_cbdma.py b/tests/TestSuite_cbdma.py
index d7ca3ae..14611f0 100644
--- a/tests/TestSuite_cbdma.py
+++ b/tests/TestSuite_cbdma.py
@@ -54,7 +54,8 @@ class TestCBDMA(TestCase):
         self.verify(len(self.dut_ports) >= 2, "Insufficient ports for testing")
         self.ports_socket = self.dut.get_numa_id(self.dut_ports[0])
         self.get_cbdma_ports_info_and_bind_to_dpdk()
-        out = self.dut.build_dpdk_apps('./examples/ioat/')
+        out = self.dut.build_dpdk_apps('./examples/ioat')
+        self.app_path=self.dut.apps_name['ioat']
         self.verify('Error' not in out, 'compilation ioat error')
 
     def set_up(self):
@@ -139,14 +140,17 @@ class TestCBDMA(TestCase):
         num is 2
         '''
         # flush other output
-        self.dut.get_session_output(timeout=1)
-        cmd_command = './examples/ioat/build/ioatfwd ' + eal_params + \
+        self.send_session=self.dut.new_session("new_session")
+        target = self.app_path.split("/")
+        self.send_session.send_expect(f"cd  {'/'.join(target[0:-1])} ", '# ')
+        self.send_session.get_session_before(timeout=1)
+        cmd_command = "./"+target[-1] + eal_params + \
                       '-- -p %s -q %d %s -c %s' % (hex(port_info),
                       self.cbdma_ioat_dev_num/self.cbdma_nic_dev_num, mac_info,
                       self.cbdma_copy_mode)
-        self.dut.send_expect(cmd_command, 'ioatfwd,')
+        self.send_session.send_expect(cmd_command, f'{target[-1].strip()},')
         time.sleep(1)
-        out = self.dut.get_session_output(timeout=1)
+        out = self.send_session.get_session_before(timeout=1)
         thread_num = 2 if self.cbdma_cores_num > 2 else 1
         o_thread_info = 'Worker Threads = %d' % thread_num
         o_copy_info = 'Copy Mode = %s' % self.cbdma_copy_mode
@@ -210,7 +214,7 @@ class TestCBDMA(TestCase):
         """
         Check stats of ioat app, each ioat channel can enqueue packets
         """
-        out = self.dut.get_session_output(timeout=2)
+        out = self.send_session.get_session_before(timeout=2)
         index = out.rfind('Statistics for port 0')
         out = out[index:]
         data_info = re.findall('successful_enqueues:\s*(\d*)', out)
-- 
1.8.3.1


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

* Re: [dts] [PATCH V1] tests/TestSuite_cbdma:Modify the start IOAT path
  2020-09-17  6:09 [dts] [PATCH V1] tests/TestSuite_cbdma:Modify the start IOAT path xizhan4x
@ 2020-09-17  6:14 ` Zhang, XiX
  2020-09-22  5:41   ` Wang, Yinan
  2020-09-23  7:31 ` Tu, Lijuan
  1 sibling, 1 reply; 4+ messages in thread
From: Zhang, XiX @ 2020-09-17  6:14 UTC (permalink / raw)
  To: dts

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

Test-by: Zhang, XiX <xix.zhang@intel.com>

> -----Original Message-----
> From: Zhang, XiX
> Sent: Thursday, September 17, 2020 2:09 PM
> To: dts@dpdk.org
> Cc: Zhang, XiX <xix.zhang@intel.com>
> Subject: [dts][PATCH V1] tests/TestSuite_cbdma:Modify the start IOAT path
> 
> Modify the start IOAT path supoort meson build
> 
> Signed-off-by: xizhan4x <xix.zhang@intel.com>
> ---
>  tests/TestSuite_cbdma.py | 16 ++++++++++------
>  1 file changed, 10 insertions(+), 6 deletions(-)
> 
> diff --git a/tests/TestSuite_cbdma.py b/tests/TestSuite_cbdma.py index
> d7ca3ae..14611f0 100644
> --- a/tests/TestSuite_cbdma.py
> +++ b/tests/TestSuite_cbdma.py
> @@ -54,7 +54,8 @@ class TestCBDMA(TestCase):
>          self.verify(len(self.dut_ports) >= 2, "Insufficient ports for testing")
>          self.ports_socket = self.dut.get_numa_id(self.dut_ports[0])
>          self.get_cbdma_ports_info_and_bind_to_dpdk()
> -        out = self.dut.build_dpdk_apps('./examples/ioat/')
> +        out = self.dut.build_dpdk_apps('./examples/ioat')
> +        self.app_path=self.dut.apps_name['ioat']
>          self.verify('Error' not in out, 'compilation ioat error')
> 
>      def set_up(self):
> @@ -139,14 +140,17 @@ class TestCBDMA(TestCase):
>          num is 2
>          '''
>          # flush other output
> -        self.dut.get_session_output(timeout=1)
> -        cmd_command = './examples/ioat/build/ioatfwd ' + eal_params + \
> +        self.send_session=self.dut.new_session("new_session")
> +        target = self.app_path.split("/")
> +        self.send_session.send_expect(f"cd  {'/'.join(target[0:-1])} ", '# ')
> +        self.send_session.get_session_before(timeout=1)
> +        cmd_command = "./"+target[-1] + eal_params + \
>                        '-- -p %s -q %d %s -c %s' % (hex(port_info),
> 
> self.cbdma_ioat_dev_num/self.cbdma_nic_dev_num, mac_info,
>                        self.cbdma_copy_mode)
> -        self.dut.send_expect(cmd_command, 'ioatfwd,')
> +        self.send_session.send_expect(cmd_command,
> + f'{target[-1].strip()},')
>          time.sleep(1)
> -        out = self.dut.get_session_output(timeout=1)
> +        out = self.send_session.get_session_before(timeout=1)
>          thread_num = 2 if self.cbdma_cores_num > 2 else 1
>          o_thread_info = 'Worker Threads = %d' % thread_num
>          o_copy_info = 'Copy Mode = %s' % self.cbdma_copy_mode @@
> -210,7 +214,7 @@ class TestCBDMA(TestCase):
>          """
>          Check stats of ioat app, each ioat channel can enqueue packets
>          """
> -        out = self.dut.get_session_output(timeout=2)
> +        out = self.send_session.get_session_before(timeout=2)
>          index = out.rfind('Statistics for port 0')
>          out = out[index:]
>          data_info = re.findall('successful_enqueues:\s*(\d*)', out)
> --
> 1.8.3.1


[-- Attachment #2: TestCBDMA.LOG --]
[-- Type: application/octet-stream, Size: 816275 bytes --]

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

* Re: [dts] [PATCH V1] tests/TestSuite_cbdma:Modify the start IOAT path
  2020-09-17  6:14 ` Zhang, XiX
@ 2020-09-22  5:41   ` Wang, Yinan
  0 siblings, 0 replies; 4+ messages in thread
From: Wang, Yinan @ 2020-09-22  5:41 UTC (permalink / raw)
  To: Zhang, XiX, dts

Acked-by: Wang, Yinan <yinan.wang@intel.com>

> -----Original Message-----
> From: dts <dts-bounces@dpdk.org> On Behalf Of Zhang, XiX
> Sent: 2020年9月17日 14:14
> To: dts@dpdk.org
> Subject: Re: [dts] [PATCH V1] tests/TestSuite_cbdma:Modify the start IOAT
> path
> 
> Test-by: Zhang, XiX <xix.zhang@intel.com>
> 
> > -----Original Message-----
> > From: Zhang, XiX
> > Sent: Thursday, September 17, 2020 2:09 PM
> > To: dts@dpdk.org
> > Cc: Zhang, XiX <xix.zhang@intel.com>
> > Subject: [dts][PATCH V1] tests/TestSuite_cbdma:Modify the start IOAT
> path
> >
> > Modify the start IOAT path supoort meson build
> >
> > Signed-off-by: xizhan4x <xix.zhang@intel.com>
> > ---
> >  tests/TestSuite_cbdma.py | 16 ++++++++++------
> >  1 file changed, 10 insertions(+), 6 deletions(-)
> >
> > diff --git a/tests/TestSuite_cbdma.py b/tests/TestSuite_cbdma.py index
> > d7ca3ae..14611f0 100644
> > --- a/tests/TestSuite_cbdma.py
> > +++ b/tests/TestSuite_cbdma.py
> > @@ -54,7 +54,8 @@ class TestCBDMA(TestCase):
> >          self.verify(len(self.dut_ports) >= 2, "Insufficient ports for testing")
> >          self.ports_socket = self.dut.get_numa_id(self.dut_ports[0])
> >          self.get_cbdma_ports_info_and_bind_to_dpdk()
> > -        out = self.dut.build_dpdk_apps('./examples/ioat/')
> > +        out = self.dut.build_dpdk_apps('./examples/ioat')
> > +        self.app_path=self.dut.apps_name['ioat']
> >          self.verify('Error' not in out, 'compilation ioat error')
> >
> >      def set_up(self):
> > @@ -139,14 +140,17 @@ class TestCBDMA(TestCase):
> >          num is 2
> >          '''
> >          # flush other output
> > -        self.dut.get_session_output(timeout=1)
> > -        cmd_command = './examples/ioat/build/ioatfwd ' + eal_params + \
> > +        self.send_session=self.dut.new_session("new_session")
> > +        target = self.app_path.split("/")
> > +        self.send_session.send_expect(f"cd  {'/'.join(target[0:-1])} ", '# ')
> > +        self.send_session.get_session_before(timeout=1)
> > +        cmd_command = "./"+target[-1] + eal_params + \
> >                        '-- -p %s -q %d %s -c %s' % (hex(port_info),
> >
> > self.cbdma_ioat_dev_num/self.cbdma_nic_dev_num, mac_info,
> >                        self.cbdma_copy_mode)
> > -        self.dut.send_expect(cmd_command, 'ioatfwd,')
> > +        self.send_session.send_expect(cmd_command,
> > + f'{target[-1].strip()},')
> >          time.sleep(1)
> > -        out = self.dut.get_session_output(timeout=1)
> > +        out = self.send_session.get_session_before(timeout=1)
> >          thread_num = 2 if self.cbdma_cores_num > 2 else 1
> >          o_thread_info = 'Worker Threads = %d' % thread_num
> >          o_copy_info = 'Copy Mode = %s' % self.cbdma_copy_mode @@
> > -210,7 +214,7 @@ class TestCBDMA(TestCase):
> >          """
> >          Check stats of ioat app, each ioat channel can enqueue packets
> >          """
> > -        out = self.dut.get_session_output(timeout=2)
> > +        out = self.send_session.get_session_before(timeout=2)
> >          index = out.rfind('Statistics for port 0')
> >          out = out[index:]
> >          data_info = re.findall('successful_enqueues:\s*(\d*)', out)
> > --
> > 1.8.3.1


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

* Re: [dts] [PATCH V1] tests/TestSuite_cbdma:Modify the start IOAT path
  2020-09-17  6:09 [dts] [PATCH V1] tests/TestSuite_cbdma:Modify the start IOAT path xizhan4x
  2020-09-17  6:14 ` Zhang, XiX
@ 2020-09-23  7:31 ` Tu, Lijuan
  1 sibling, 0 replies; 4+ messages in thread
From: Tu, Lijuan @ 2020-09-23  7:31 UTC (permalink / raw)
  To: Zhang, XiX, dts; +Cc: Zhang, XiX

> Subject: [dts] [PATCH V1] tests/TestSuite_cbdma:Modify the start IOAT path
> 
> Modify the start IOAT path supoort meson build
> 
> Signed-off-by: xizhan4x <xix.zhang@intel.com>

Applied

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

end of thread, other threads:[~2020-09-23  7:32 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-17  6:09 [dts] [PATCH V1] tests/TestSuite_cbdma:Modify the start IOAT path xizhan4x
2020-09-17  6:14 ` Zhang, XiX
2020-09-22  5:41   ` Wang, Yinan
2020-09-23  7:31 ` Tu, Lijuan

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).