[V1] tests/vm2vm_virtio_user: sync CBDMA case code with test plan

Message ID 20201215163305.14675-1-weix.ling@intel.com (mailing list archive)
State Superseded
Delegated to: LIjuan Tu
Headers
Series [V1] tests/vm2vm_virtio_user: sync CBDMA case code with test plan |

Commit Message

Ling, WeiX Dec. 15, 2020, 4:33 p.m. UTC
  sync CBDMA case code with test plan

Signed-off-by: lingwei <weix.ling@intel.com>
---
 tests/TestSuite_vm2vm_virtio_user.py | 20 ++++++++++----------
 1 file changed, 10 insertions(+), 10 deletions(-)
  

Patch

diff --git a/tests/TestSuite_vm2vm_virtio_user.py b/tests/TestSuite_vm2vm_virtio_user.py
index 910552c0..15c1f347 100644
--- a/tests/TestSuite_vm2vm_virtio_user.py
+++ b/tests/TestSuite_vm2vm_virtio_user.py
@@ -132,8 +132,8 @@  class TestVM2VMVirtioUser(TestCase):
         launch the testpmd as virtio with vhost_net0
         and start to send 251 small packets with diff burst
         """
-        eal_params = ' --socket-mem {} --vdev=net_virtio_user0,mac=00:01:02:03:04:05,path=./vhost-net0,queues=1,' \
-                     '{},queue_size={} '.format(self.socket_mem, path_mode, ringsize)
+        eal_params = ' --socket-mem {} --vdev=net_virtio_user0,mac=00:01:02:03:04:05,path=./vhost-net0,queues={},' \
+                     '{},queue_size={} '.format(self.socket_mem, self.queue_num, path_mode, ringsize)
         if self.check_2M_env:
             eal_params += " --single-file-segments"
         if 'vectorized_path' in self.running_case:
@@ -152,8 +152,8 @@  class TestVM2VMVirtioUser(TestCase):
         launch the testpmd as virtio with vhost_net0
         and start to send 251 small packets with diff burst
         """
-        eal_params = ' --socket-mem {} --vdev=net_virtio_user0,mac=00:01:02:03:04:05,path=./vhost-net0,' \
-                     'queues={},{},queue_size={} '.format(self.socket_mem, self.queue_num, path_mode, ringsize)
+        eal_params = ' --socket-mem {} --vdev=net_virtio_user0,mac=00:01:02:03:04:05,path=./vhost-net0,queues={},' \
+                     '{},queue_size={} '.format(self.socket_mem, self.queue_num, path_mode, ringsize)
         if self.check_2M_env:
             eal_params += " --single-file-segments "
         params = "--nb-cores=1 --txd={} --rxd={} {}".format(ringsize, ringsize, extern_params)
@@ -676,14 +676,14 @@  class TestVM2VMVirtioUser(TestCase):
         large_2k_pkts_num = 10
         self.queue_num=2
         self.nopci=False
-        path_mode = 'packed_vq=0,mrg_rxbuf=1,in_order=1,server=0'
+        path_mode = 'server=1,packed_vq=0,mrg_rxbuf=1,in_order=1'
         ringsize = 4096
         extern_params = '--rxq=2 --txq=2'
         # get dump pcap file of virtio
         # the virtio0 will send 283 pkts, but the virtio only will received 252 pkts
         self.logger.info('check pcap file info about virtio')
-        vdevs = f"--vdev 'eth_vhost0,iface=vhost-net0,queues=2,client=0,dmas=[txq0@{self.cbdma_dev_infos[0]};txq1@{self.cbdma_dev_infos[1]}],dmathr=512' " \
-                f"--vdev 'eth_vhost1,iface=vhost-net1,queues=2,client=0,dmas=[txq0@{self.cbdma_dev_infos[2]};txq1@{self.cbdma_dev_infos[3]}],dmathr=512'"
+        vdevs = f"--vdev 'eth_vhost0,iface=vhost-net0,queues=2,client=1,dmas=[txq0@{self.cbdma_dev_infos[0]};txq1@{self.cbdma_dev_infos[1]}],dmathr=512' " \
+                f"--vdev 'eth_vhost1,iface=vhost-net1,queues=2,client=1,dmas=[txq0@{self.cbdma_dev_infos[2]};txq1@{self.cbdma_dev_infos[3]}],dmathr=512'"
 
         self.get_dump_file_of_virtio_user_cbdma(path_mode, extern_params, ringsize, vdevs)
         self.send_8k_pkt()
@@ -713,14 +713,14 @@  class TestVM2VMVirtioUser(TestCase):
         large_2k_pkts_num = 394
         self.queue_num=2
         self.nopci=False
-        path_mode = 'packed_vq=0,mrg_rxbuf=1,in_order=0,server=0'
+        path_mode = 'server=1,packed_vq=0,mrg_rxbuf=1,in_order=0'
         ringsize = 4096
         extern_params = '--rxq=2 --txq=2'
         # get dump pcap file of virtio
         # the virtio0 will send 283 pkts, but the virtio only will received 252 pkts
         self.logger.info('check pcap file info about virtio')
-        vdevs = f"--vdev 'eth_vhost0,iface=vhost-net0,queues=2,client=0,dmas=[txq0@{self.cbdma_dev_infos[0]};txq1@{self.cbdma_dev_infos[1]}],dmathr=512' " \
-                f"--vdev 'eth_vhost1,iface=vhost-net1,queues=2,client=0,dmas=[txq0@{self.cbdma_dev_infos[2]};txq1@{self.cbdma_dev_infos[3]}],dmathr=512'"
+        vdevs = f"--vdev 'eth_vhost0,iface=vhost-net0,queues=2,client=1,dmas=[txq0@{self.cbdma_dev_infos[0]};txq1@{self.cbdma_dev_infos[1]}],dmathr=512' " \
+                f"--vdev 'eth_vhost1,iface=vhost-net1,queues=2,client=1,dmas=[txq0@{self.cbdma_dev_infos[2]};txq1@{self.cbdma_dev_infos[3]}],dmathr=512'"
 
         self.get_dump_file_of_virtio_user_cbdma(path_mode, extern_params, ringsize, vdevs)
         self.send_multiple_pkt_with_8k54_2k394()