qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [RFC PATCH] tests/avocado: probe for multi-process support before ru


From: Philippe Mathieu-Daudé
Subject: Re: [RFC PATCH] tests/avocado: probe for multi-process support before running test
Date: Wed, 22 Mar 2023 09:40:18 +0100
User-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:102.0) Gecko/20100101 Thunderbird/102.9.0

On 21/3/23 19:19, Alex Bennée wrote:
Philippe Mathieu-Daudé <philmd@linaro.org> writes:
On 21/3/23 12:17, Alex Bennée wrote:
A recent attempt to let avocado run more tests on the CentOS stream
build failed because there was no gating on the multiprocess feature.
Like missing accelerators avocado should gracefully skip when the
feature is not enabled.
In this case we use the existence of the proxy device as a proxy for
multi-process support.
Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
Cc: Elena Ufimtseva <elena.ufimtseva@oracle.com>
Cc: Jagannathan Raman <jag.raman@oracle.com>
Cc: John G Johnson <john.g.johnson@oracle.com>
---
   tests/avocado/avocado_qemu/__init__.py | 10 ++++++++++
   tests/avocado/multiprocess.py          |  1 +
   2 files changed, 11 insertions(+)

+        """
+        Test for the presence of the x-pci-proxy-dev which is required
+        to support multiprocess.
+        """
+        devhelp = run_cmd([self.qemu_bin,
+                           '-M', 'none', '-device', 'help'])[0];
+        if devhelp.find('x-pci-proxy-dev') < 0:
+            self.cancel('no support for multiprocess device emulation')

FYI a more generic alternative to this method:
https://lore.kernel.org/qemu-devel/20200129212345.20547-14-philmd@redhat.com/

But yours just works :)

For now I want to keep it simple. We should replace it with yours once
we get a chance. Are you happy for a r-b?

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>




reply via email to

[Prev in Thread] Current Thread [Next in Thread]