aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSaul Wold <Saul.Wold@windriver.com>2021-06-29 07:57:01 -0700
committerAlexandre Belloni <alexandre.belloni@bootlin.com>2021-07-01 15:56:30 +0200
commit61d434882e3cdcc7be029e1d44a917a408e4a9a1 (patch)
tree658af52d2ba4922d9419a31e35b79ae96734993e
parent41f6f67cb9fe149a70a99ec41484c6561b93ab38 (diff)
downloadopenembedded-core-contrib-61d434882e3cdcc7be029e1d44a917a408e4a9a1.tar.gz
openembedded-core-contrib-61d434882e3cdcc7be029e1d44a917a408e4a9a1.tar.bz2
openembedded-core-contrib-61d434882e3cdcc7be029e1d44a917a408e4a9a1.zip
oeqa/qemurunner: add support qmp cmd args
This will enable passing arguments to qmp commands for those that require additional information Signed-off-by: Saul Wold <saul.wold@windriver.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
-rw-r--r--meta/lib/oeqa/utils/qemurunner.py8
1 files changed, 6 insertions, 2 deletions
diff --git a/meta/lib/oeqa/utils/qemurunner.py b/meta/lib/oeqa/utils/qemurunner.py
index c7f78603179..10c54d6afab 100644
--- a/meta/lib/oeqa/utils/qemurunner.py
+++ b/meta/lib/oeqa/utils/qemurunner.py
@@ -602,8 +602,12 @@ class QemuRunner:
return True
return False
- def run_monitor(self, command, timeout=60):
- return self.qmp.cmd(command)
+ def run_monitor(self, command, args=None, timeout=60):
+ if hasattr(self, 'qmp') and self.qmp:
+ if args is not None:
+ return self.qmp.cmd(command, args)
+ else:
+ return self.qmp.cmd(command)
def run_serial(self, command, raw=False, timeout=60):
# We assume target system have echo to get command status