From: Yao Lei <lei.a.yao@intel.com>
To: dts@dpdk.org
Cc: lei yao <lei.a.yao@intel.com>
Subject: [dts] [PATCH V1] framework qemu_kvm.py: Add "server" and "multi_queue" parameter for more qemu launch option and adjust some timeout setting to improve the test stability
Date: Fri, 16 Dec 2016 15:54:59 +0800 [thread overview]
Message-ID: <1481874899-4510-1-git-send-email-lei.a.yao@intel.com> (raw)
From: lei yao <lei.a.yao@intel.com>
Signed-off-by: lei yao <lei.a.yao@intel.com>
---
framework/qemu_kvm.py | 24 +++++++++++++++++-------
1 file changed, 17 insertions(+), 7 deletions(-)
diff --git a/framework/qemu_kvm.py b/framework/qemu_kvm.py
index 6ced54a..e9d29cc 100644
--- a/framework/qemu_kvm.py
+++ b/framework/qemu_kvm.py
@@ -606,21 +606,31 @@ class QEMUKvm(VirtBase):
if 'opt_path' in options.keys() and options['opt_path']:
dev_boot_line = '-chardev socket'
char_id = 'char%d' % self.char_idx
- dev_boot_line += separator + 'id=%s' % char_id + separator + 'path=%s' % options['opt_path']
- self.char_idx += 1
- self.__add_boot_line(dev_boot_line)
+ if 'opt_server' in options.keys() and options['opt_server']:
+ dev_boot_line += separator + 'id=%s' % char_id + separator + 'path=%s' %options['opt_path'] + separator + '%s' % options['opt_server']
+ self.char_idx += 1
+ self.__add_boot_line(dev_boot_line)
+ else:
+ dev_boot_line += separator + 'id=%s' % char_id + separator + 'path=%s' %options['opt_path']
+ self.char_idx += 1
+ self.__add_boot_line(dev_boot_line)
# netdev parameter
netdev_id = 'netdev%d' % self.netdev_idx
self.netdev_idx += 1
- dev_boot_line = '-netdev type=vhost-user,id=%s,chardev=%s,vhostforce' % (netdev_id, char_id)
+ if 'opt_queue' in options.keys() and options['opt_queue']:
+ queue_num=options['opt_queue']
+ dev_boot_line = '-netdev type=vhost-user,id=%s,chardev=%s,vhostforce,queues=%s' % (netdev_id, char_id,queue_num)
+ else:
+ dev_boot_line = '-netdev type=vhost-user,id=%s,chardev=%s,vhostforce' % (netdev_id, char_id)
self.__add_boot_line(dev_boot_line)
# device parameter
opts = {'opt_netdev': '%s' % netdev_id}
if 'opt_mac' in options.keys() and \
options['opt_mac']:
opts['opt_mac'] = options['opt_mac']
-
- self.__add_vm_virtio_net_pci(**opts)
+ if 'opt_settings' in options.keys() and options['opt_settings']:
+ opts['opt_settings'] = options['opt_settings']
+ self.__add_vm_virtio_net_pci(**opts)
def __add_vm_virtio_cuse_pci(self, **options):
"""
@@ -939,7 +949,7 @@ class QEMUKvm(VirtBase):
wait for 120 seconds for vm net ready
10.0.2.* is the default ip address allocated by qemu
"""
- count = 20
+ count = 40
while count:
out = self.__control_session('ifconfig')
if "10.0.2" in out:
--
2.7.4
next reply other threads:[~2016-12-16 7:53 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-12-16 7:54 Yao Lei [this message]
2016-12-19 2:59 ` Liu, Yong
2016-12-19 3:19 ` Yao, Lei A
2016-12-19 3:33 ` Liu, Yong
2016-12-19 4:46 ` Yao, Lei A
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=1481874899-4510-1-git-send-email-lei.a.yao@intel.com \
--to=lei.a.yao@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).