From: "Philippe Mathieu-Daudé" <philmd@linaro.org>
To: Peter Maydell <peter.maydell@linaro.org>,
qemu-arm@nongnu.org, qemu-devel@nongnu.org
Subject: Re: [PATCH 2/3] linux-user: Report AArch64 hwcap2 fields above bit 31
Date: Thu, 2 Nov 2023 08:28:36 +0100 [thread overview]
Message-ID: <d897c14b-d193-f148-1afe-aa64e348da52@linaro.org> (raw)
In-Reply-To: <20231030174000.3792225-3-peter.maydell@linaro.org>
On 30/10/23 18:39, Peter Maydell wrote:
> The AArch64 ELF hwcap2 field is 64 bits, but our get_elf_hwcap2()
> works with uint32_t, so it accidentally fails to report any hwcaps
> over bit 31. Use uint64_t here.
>
> The Arm hwcap2 is only 32 bits (because the ELF format makes these
> fields be the size of "long" in the ABI), but since it shares the
> prototype declaration for get_elf_hwcap2() it is easier to also
> expand it to 64 bits.
>
> The only hwcap fields we implement already that are affected by this
> are the HBC and MOPS ones, neither of which were implemented in a
> previous release, so this doesn't need backporting to older stable
> branches.
>
> Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
> ---
> linux-user/loader.h | 2 +-
> linux-user/elfload.c | 8 ++++----
> 2 files changed, 5 insertions(+), 5 deletions(-)
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
next prev parent reply other threads:[~2023-11-02 7:30 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-10-30 17:39 [PATCH 0/3] target/arm: Fix various FEAT_MOPS bugs Peter Maydell
2023-10-30 17:39 ` [PATCH 1/3] target/arm: Enable FEAT_MOPS insns in user-mode emulation Peter Maydell
2023-10-30 17:39 ` [PATCH 2/3] linux-user: Report AArch64 hwcap2 fields above bit 31 Peter Maydell
2023-11-02 7:28 ` Philippe Mathieu-Daudé [this message]
2023-10-30 17:40 ` [PATCH 3/3] target/arm: Make FEAT_MOPS SET* insns handle Xs == XZR correctly Peter Maydell
2023-10-30 18:24 ` [PATCH 0/3] target/arm: Fix various FEAT_MOPS bugs Richard Henderson
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=d897c14b-d193-f148-1afe-aa64e348da52@linaro.org \
--to=philmd@linaro.org \
--cc=peter.maydell@linaro.org \
--cc=qemu-arm@nongnu.org \
--cc=qemu-devel@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).