From 8bf212f2d0afe84071d6539eff1d48f578fe67d6 Mon Sep 17 00:00:00 2001 From: Dan Zheng Date: Tue, 18 Jul 2023 14:10:05 +0800 Subject: [PATCH] virsh: align same usage for emulatorpin Usually the options value should be started with --. The old codes added '--' in this utility function which is not suitable. We expect the client provides like '--config' to invoke this function as other functions do. Signed-off-by: Dan Zheng --- virttest/virsh.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/virttest/virsh.py b/virttest/virsh.py index 822c798a22..234a3709f4 100644 --- a/virttest/virsh.py +++ b/virttest/virsh.py @@ -3461,7 +3461,7 @@ def numatune(name, mode=None, nodeset=None, options=None, **dargs): """ cmd = "numatune %s" % name if options: - cmd += " --%s" % options + cmd += " %s" % options if mode: cmd += " --mode %s" % mode if nodeset: @@ -3925,13 +3925,13 @@ def emulatorpin(name, cpulist=None, options=None, **dargs): Control or query domain emulator affinity :param name: name of domain :param cpulist: a list of physical CPU numbers - :param options: options may be live, config and current + :param options: options may be --live, --config and --current :param dargs: standardized virsh function API keywords :return: CmdResult instance """ cmd = "emulatorpin %s" % name if options: - cmd += " --%s" % options + cmd += " %s" % options if cpulist: cmd += " --cpulist %s" % cpulist