From: Richard Henderson <richard.henderson@linaro.org>
To: Sven Schnelle <svens@stackframe.org>
Cc: qemu-devel@nongnu.org, Helge Deller <deller@gmx.de>
Subject: Re: [PATCH 3/3] target/hppa: fix building gva for wide mode
Date: Sun, 24 Mar 2024 07:20:39 -1000 [thread overview]
Message-ID: <6be58de3-978b-4248-9023-e89c33612b93@linaro.org> (raw)
In-Reply-To: <20240324080945.991100-4-svens@stackframe.org>
On 3/23/24 22:09, Sven Schnelle wrote:
> 64 Bit hppa no longer has a fixed 32/32 bit split between space and
> offset. Instead it uses 42 bits for the offset. The lower 10 bits of
> the space are always zero, leaving 22 bits actually used. Simply or
> the values together to build the gva.
>
> Signed-off-by: Sven Schnelle <svens@stackframe.org>
> ---
> target/hppa/mem_helper.c | 13 +++++++------
> 1 file changed, 7 insertions(+), 6 deletions(-)
>
> diff --git a/target/hppa/mem_helper.c b/target/hppa/mem_helper.c
> index 84785b5a5c..6f895fced7 100644
> --- a/target/hppa/mem_helper.c
> +++ b/target/hppa/mem_helper.c
> @@ -523,13 +523,16 @@ void HELPER(itlbp_pa11)(CPUHPPAState *env, target_ulong addr, target_ulong reg)
> }
>
> static void itlbt_pa20(CPUHPPAState *env, target_ulong r1,
> - target_ulong r2, vaddr va_b)
> + target_ulong r2, uint64_t spc, uint64_t off)
> {
> HPPATLBEntry *ent;
> - vaddr va_e;
> + vaddr va_b, va_e;
> uint64_t va_size;
> int mask_shift;
>
> + va_b = off & gva_offset_mask(env->psw);
> + va_b |= spc << 32;
Indeed, this ought to be using
va_b = hppa_form_gva_psw(env->psw, off, spc << 32);
With that,
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
r~
next prev parent reply other threads:[~2024-03-24 17:21 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-03-24 8:09 [PATCH 0/3] few hppa fixes for 64bit mode Sven Schnelle
2024-03-24 8:09 ` [PATCH 1/3] target/hppa: use gva_offset_mask() everywhere Sven Schnelle
2024-03-24 16:13 ` Helge Deller
2024-03-24 17:20 ` Richard Henderson
2024-03-24 8:09 ` [PATCH 2/3] target/hppa: mask offset bits in gva Sven Schnelle
2024-03-24 16:24 ` Helge Deller
2024-03-24 18:13 ` Richard Henderson
2024-03-24 18:41 ` Sven Schnelle
2024-03-24 23:14 ` Richard Henderson
2024-03-25 6:27 ` Sven Schnelle
2024-03-28 21:03 ` Sven Schnelle
2024-04-02 6:01 ` Sven Schnelle
2024-04-02 6:08 ` Richard Henderson
2024-04-02 6:29 ` Sven Schnelle
2024-04-02 22:18 ` Helge Deller
2024-03-24 8:09 ` [PATCH 3/3] target/hppa: fix building gva for wide mode Sven Schnelle
2024-03-24 16:28 ` Helge Deller
2024-03-24 17:20 ` Richard Henderson [this message]
2024-03-24 21:39 ` Richard Henderson
2024-03-24 23:38 ` 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=6be58de3-978b-4248-9023-e89c33612b93@linaro.org \
--to=richard.henderson@linaro.org \
--cc=deller@gmx.de \
--cc=qemu-devel@nongnu.org \
--cc=svens@stackframe.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).