qemu-devel
[Top][All Lists]
Advanced

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

Re: [PATCH v2 11/17] python/machine: remove has_quit argument


From: Hanna Reitz
Subject: Re: [PATCH v2 11/17] python/machine: remove has_quit argument
Date: Tue, 12 Oct 2021 17:30:03 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.1.0

On 23.09.21 02:49, John Snow wrote:
If we spy on the QMP commands instead, we don't need callers to remember
to pass it. Seems like a fair trade-off.

The one slightly weird bit is overloading this instance variable for
wait(), where we use it to mean "don't issue the qmp 'quit'
command". This means that wait() will "fail" if the QEMU process does
not terminate of its own accord.

In most cases, we probably did already actually issue quit -- some
iotests do this -- but in some others, we may be waiting for QEMU to
terminate for some other reason, such as a test wherein we tell the
guest (directly) to shut down.

Signed-off-by: John Snow <jsnow@redhat.com>
---
  python/qemu/machine/machine.py | 34 +++++++++++++++++++---------------
  tests/qemu-iotests/040         |  7 +------
  tests/qemu-iotests/218         |  2 +-
  tests/qemu-iotests/255         |  2 +-
  4 files changed, 22 insertions(+), 23 deletions(-)

Reviewed-by: Hanna Reitz <hreitz@redhat.com>




reply via email to

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