From: Thomas Huth <thuth@redhat.com>
To: "Alex Bennée" <alex.bennee@linaro.org>, qemu-devel@nongnu.org
Cc: qemu-s390x@nongnu.org, qemu-arm@nongnu.org,
Peter Maydell <peter.maydell@linaro.org>,
Fabiano Rosas <farosas@suse.de>,
Laurent Vivier <lvivier@redhat.com>,
Paolo Bonzini <pbonzini@redhat.com>
Subject: Re: [PATCH 2/7] tests/qtest: don't attempt to clock_step while waiting for virtio ISR
Date: Tue, 21 Jan 2025 06:13:07 +0100 [thread overview]
Message-ID: <e7769309-6339-435b-ad30-e56c18679892@redhat.com> (raw)
In-Reply-To: <20250120210212.3890255-3-alex.bennee@linaro.org>
On 20/01/2025 22.02, Alex Bennée wrote:
> This replicates the changes from 92cb8f8bf6 (tests/qtest: remove
> clock_steps from virtio tests) as there are no timers in the virtio
> code. We still busy wait and timeout though.
>
> Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
> ---
> tests/qtest/libqos/virtio-pci-modern.c | 6 ++----
> tests/qtest/libqos/virtio-pci.c | 6 ++----
> 2 files changed, 4 insertions(+), 8 deletions(-)
>
> diff --git a/tests/qtest/libqos/virtio-pci-modern.c b/tests/qtest/libqos/virtio-pci-modern.c
> index 18d118866f..f6e3e32891 100644
> --- a/tests/qtest/libqos/virtio-pci-modern.c
> +++ b/tests/qtest/libqos/virtio-pci-modern.c
> @@ -173,13 +173,11 @@ static bool get_config_isr_status(QVirtioDevice *d)
>
> static void wait_config_isr_status(QVirtioDevice *d, gint64 timeout_us)
> {
> - QVirtioPCIDevice *dev = container_of(d, QVirtioPCIDevice, vdev);
> gint64 start_time = g_get_monotonic_time();
>
> - do {
> + while (!get_config_isr_status(d)) {
> g_assert(g_get_monotonic_time() - start_time <= timeout_us);
> - qtest_clock_step(dev->pdev->bus->qts, 100);
> - } while (!get_config_isr_status(d));
> + }
Trailing white space in above line?
Apart from that nit:
Reviewed-by: Thomas Huth <thuth@redhat.com>
next prev parent reply other threads:[~2025-01-21 5:14 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-01-20 21:02 [PATCH 0/7] testing/next (qtest timer stuff) Alex Bennée
2025-01-20 21:02 ` [PATCH 1/7] tests/docker: replicate the check-rust-tools-nightly CI job Alex Bennée
2025-01-20 21:02 ` [PATCH 2/7] tests/qtest: don't attempt to clock_step while waiting for virtio ISR Alex Bennée
2025-01-21 5:13 ` Thomas Huth [this message]
2025-01-20 21:02 ` [PATCH 3/7] tests/qtest: don't step clock at start of npcm7xx periodic IRQ test Alex Bennée
2025-01-21 12:52 ` Thomas Huth
2025-01-20 21:02 ` [PATCH 4/7] tests/qtest: simplify qtest_process_inbuf Alex Bennée
2025-01-20 21:02 ` [PATCH 5/7] tests/qtest: rename qtest_send_prefix and roll-up into qtest_send Alex Bennée
2025-01-20 22:05 ` Daniel Henrique Barboza
2025-01-20 21:02 ` [PATCH 6/7] tests/qtest: tighten up the checks on clock_step Alex Bennée
2025-01-21 13:04 ` Peter Maydell
2025-01-20 21:02 ` [PATCH 7/7] Revert "util/timer: avoid deadlock when shutting down" Alex Bennée
2025-01-21 12:51 ` [PATCH 0/7] testing/next (qtest timer stuff) Thomas Huth
2025-01-21 13:50 ` Fabiano Rosas
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=e7769309-6339-435b-ad30-e56c18679892@redhat.com \
--to=thuth@redhat.com \
--cc=alex.bennee@linaro.org \
--cc=farosas@suse.de \
--cc=lvivier@redhat.com \
--cc=pbonzini@redhat.com \
--cc=peter.maydell@linaro.org \
--cc=qemu-arm@nongnu.org \
--cc=qemu-devel@nongnu.org \
--cc=qemu-s390x@nongnu.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).