All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Philippe Mathieu-Daudé" <philmd@oss.qualcomm.com>
To: qemu-devel@nongnu.org
Cc: "Alex Bennée" <alex.bennee@linaro.org>,
	qemu-arm@nongnu.org, "Peter Maydell" <peter.maydell@linaro.org>,
	"Pierrick Bouvier" <pierrick.bouvier@oss.qualcomm.com>,
	qemu-ppc <qemu-ppc@nongnu.org>
Subject: Re: [PATCH] target/arm: Restrict arm_do_plugin_vcpu_discon_cb() to TCG
Date: Fri, 14 Aug 2026 10:13:18 +0200	[thread overview]
Message-ID: <13b0aca6-d1b9-4e76-88ce-530e0bc4db20@oss.qualcomm.com> (raw)
In-Reply-To: <20260814080507.23196-1-philmd@oss.qualcomm.com>

On 14/8/26 10:05, Philippe Mathieu-Daudé wrote:
> So far TCG plugins can only be used when TCG is available.
> Move the arm_do_plugin_vcpu_discon_cb() call within the
> 'if tcg_enabled' block and wrap the definition with #ifdef'ry.
> 
> Signed-off-by: Philippe Mathieu-Daudé <philmd@oss.qualcomm.com>
> ---

BTW luckily, except PPC, all other targets with HW accelerator
support already have this restricted to TCG (X86, LoongArch,
RISCV, S390x). Since I'm only testing hybrid acceleration on
ARM I don't have the need to do the equivalent cleanup on PPC.

>   target/arm/helper.c | 6 ++++--
>   1 file changed, 4 insertions(+), 2 deletions(-)
> 
> diff --git a/target/arm/helper.c b/target/arm/helper.c
> index af45234ad2a..adae2b2b8e5 100644
> --- a/target/arm/helper.c
> +++ b/target/arm/helper.c
> @@ -8915,6 +8915,7 @@ static void take_aarch32_exception(CPUARMState *env, int new_mode,
>       }
>   }
>   
> +#ifdef CONFIG_TCG
>   void arm_do_plugin_vcpu_discon_cb(CPUState *cs, uint64_t from)
>   {
>       switch (cs->exception_index) {
> @@ -8932,6 +8933,7 @@ void arm_do_plugin_vcpu_discon_cb(CPUState *cs, uint64_t from)
>           qemu_plugin_vcpu_exception_cb(cs, from);
>       }
>   }
> +#endif
>   
>   static void arm_cpu_do_interrupt_aarch32_hyp(CPUState *cs)
>   {
> @@ -9677,9 +9679,9 @@ void arm_cpu_do_interrupt(CPUState *cs)
>   
>       if (tcg_enabled()) {
>           cpu_set_interrupt(cs, CPU_INTERRUPT_EXITTB);
> -    }
>   
> -    arm_do_plugin_vcpu_discon_cb(cs, last_pc);
> +        arm_do_plugin_vcpu_discon_cb(cs, last_pc);
> +    }
>   }
>   #endif /* !CONFIG_USER_ONLY */
>   



  reply	other threads:[~2026-08-14  8:13 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-08-14  8:05 [PATCH] target/arm: Restrict arm_do_plugin_vcpu_discon_cb() to TCG Philippe Mathieu-Daudé
2026-08-14  8:13 ` Philippe Mathieu-Daudé [this message]
2026-08-14 15:35 ` Pierrick Bouvier
2026-08-14 15:35   ` Pierrick Bouvier
2026-08-15 15:08 ` Peter Maydell
2026-08-15 15:37   ` Philippe Mathieu-Daudé

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=13b0aca6-d1b9-4e76-88ce-530e0bc4db20@oss.qualcomm.com \
    --to=philmd@oss.qualcomm.com \
    --cc=alex.bennee@linaro.org \
    --cc=peter.maydell@linaro.org \
    --cc=pierrick.bouvier@oss.qualcomm.com \
    --cc=qemu-arm@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    --cc=qemu-ppc@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.