From: Daniel Henrique Barboza <danielhb413@gmail.com>
To: "Philippe Mathieu-Daudé" <philmd@linaro.org>, qemu-devel@nongnu.org
Cc: "Nicholas Piggin" <npiggin@gmail.com>,
"Daniel Henrique Barboza" <dbarboza@ventanamicro.com>,
qemu-ppc@nongnu.org,
"Richard Henderson" <richard.henderson@linaro.org>,
kvm@vger.kernel.org, "Paolo Bonzini" <pbonzini@redhat.com>,
"Kevin Wolf" <kwolf@redhat.com>,
"David Gibson" <david@gibson.dropbear.id.au>,
"Cédric Le Goater" <clg@kaod.org>,
"Michael Tokarev" <mjt@tls.msk.ru>, "Greg Kurz" <groug@kaod.org>
Subject: Re: [PATCH 4/4] target/ppc: Prohibit target specific KVM prototypes on user emulation
Date: Wed, 13 Sep 2023 06:14:48 -0300 [thread overview]
Message-ID: <014ba528-db84-3a81-f2c1-0306965d40b9@gmail.com> (raw)
In-Reply-To: <20230912113027.63941-5-philmd@linaro.org>
On 9/12/23 08:30, Philippe Mathieu-Daudé wrote:
> None of these target-specific prototypes should be used
> by user emulation. Remove their declaration there, so we
> get a compile failure if ever used (instead of having to
> deal with linker and its possible optimizations, such
> dead code removal).
>
> Suggested-by: Kevin Wolf <kwolf@redhat.com>
> Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
> ---
Reviewed-by: Daniel Henrique Barboza <danielhb413@gmail.com>
> target/ppc/kvm_ppc.h | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/target/ppc/kvm_ppc.h b/target/ppc/kvm_ppc.h
> index 440e93f923..ffda8054b2 100644
> --- a/target/ppc/kvm_ppc.h
> +++ b/target/ppc/kvm_ppc.h
> @@ -13,6 +13,10 @@
> #include "exec/hwaddr.h"
> #include "cpu.h"
>
> +#ifdef CONFIG_USER_ONLY
> +#error Cannot include kvm_ppc.h from user emulation
> +#endif
> +
> #ifdef CONFIG_KVM
>
> uint32_t kvmppc_get_tbfreq(void);
prev parent reply other threads:[~2023-09-13 9:15 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-09-12 11:30 [PATCH 0/4] target/ppc: Prohibit target specific KVM prototypes on user emulation Philippe Mathieu-Daudé
2023-09-12 11:30 ` [PATCH 1/4] sysemu/kvm: Restrict kvmppc_get_radix_page_info() to ppc targets Philippe Mathieu-Daudé
2023-09-12 12:32 ` Michael Tokarev
2023-09-12 12:44 ` Philippe Mathieu-Daudé
2023-09-12 11:30 ` [PATCH 2/4] target/ppc: Restrict KVM objects to system emulation Philippe Mathieu-Daudé
2023-09-12 13:03 ` Michael Tokarev
2023-09-12 11:30 ` [PATCH 3/4] hw/ppc/e500: Restrict ppce500_init_mpic_kvm() to KVM Philippe Mathieu-Daudé
2023-09-12 12:43 ` Michael Tokarev
2023-09-12 11:30 ` [PATCH 4/4] target/ppc: Prohibit target specific KVM prototypes on user emulation Philippe Mathieu-Daudé
2023-09-13 9:14 ` Daniel Henrique Barboza [this message]
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=014ba528-db84-3a81-f2c1-0306965d40b9@gmail.com \
--to=danielhb413@gmail.com \
--cc=clg@kaod.org \
--cc=david@gibson.dropbear.id.au \
--cc=dbarboza@ventanamicro.com \
--cc=groug@kaod.org \
--cc=kvm@vger.kernel.org \
--cc=kwolf@redhat.com \
--cc=mjt@tls.msk.ru \
--cc=npiggin@gmail.com \
--cc=pbonzini@redhat.com \
--cc=philmd@linaro.org \
--cc=qemu-devel@nongnu.org \
--cc=qemu-ppc@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).