From: Paolo Bonzini <pbonzini@redhat.com>
To: Greg Kurz <groug@kaod.org>,
Richard Henderson <richard.henderson@linaro.org>
Cc: qemu-stable@nongnu.org, Eduardo Habkost <ehabkost@redhat.com>,
qemu-devel@nongnu.org
Subject: Re: [PATCH v3 2/2] accel/tcg: Register a force_rcu notifier
Date: Tue, 9 Nov 2021 19:03:56 +0100 [thread overview]
Message-ID: <86f1fea3-9fc4-b61b-ff0e-4cf5e7374675@redhat.com> (raw)
In-Reply-To: <20211109182407.75f623f8@bahia>
On 11/9/21 18:24, Greg Kurz wrote:> Anyway, it seems more explicit to use rr_current_cpu.
>
>> Alternately, no async_run_on_cpu at all, just rr_kick_next_cpu().
>>
>
> Heh, this looks even better ! I'll try this right away.
Once you've tested it I can queue the series with just a
--- a/accel/tcg/tcg-accel-ops-rr.c
+++ b/accel/tcg/tcg-accel-ops-rr.c
@@ -141,10 +141,10 @@ static void do_nothing(CPUState *cpu, run_on_cpu_data d)
static void rr_force_rcu(Notifier *notify, void *data)
{
/*
- * Called with rcu_registry_lock held, using async_run_on_cpu() ensures
- * that there are no deadlocks.
+ * Called with rcu_registry_lock held. rr_kick_next_cpu() is
+ * asynchronous, so there cannot be deadlocks.
*/
- async_run_on_cpu(first_cpu, do_nothing, RUN_ON_CPU_NULL);
+ rr_kick_next_cpu();
}
/*
squashed in.
Paolo
next prev parent reply other threads:[~2021-11-09 18:07 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-11-08 11:33 [PATCH v3 0/2] accel/tcg: Fix monitor deadlock Greg Kurz
2021-11-08 11:33 ` [PATCH v3 1/2] rcu: Introduce force_rcu notifier Greg Kurz
2021-11-08 11:33 ` [PATCH v3 2/2] accel/tcg: Register a " Greg Kurz
2021-11-09 7:54 ` Richard Henderson
2021-11-09 8:21 ` Richard Henderson
2021-11-09 17:24 ` Greg Kurz
2021-11-09 18:03 ` Paolo Bonzini [this message]
2021-11-09 18:29 ` Greg Kurz
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=86f1fea3-9fc4-b61b-ff0e-4cf5e7374675@redhat.com \
--to=pbonzini@redhat.com \
--cc=ehabkost@redhat.com \
--cc=groug@kaod.org \
--cc=qemu-devel@nongnu.org \
--cc=qemu-stable@nongnu.org \
--cc=richard.henderson@linaro.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).