qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: deller@kernel.org
To: Richard Henderson <richard.henderson@linaro.org>,
	Stefan Hajnoczi <stefanha@redhat.com>,
	qemu-devel@nongnu.org, Peter Maydell <peter.maydell@linaro.org>
Cc: deller@gmx.de
Subject: [PULL v2 7/9] target/hppa: 64-bit CPUs start with space register hashing enabled
Date: Fri, 31 Jan 2025 10:22:27 +0100	[thread overview]
Message-ID: <20250131092229.38232-8-deller@kernel.org> (raw)
In-Reply-To: <20250131092229.38232-1-deller@kernel.org>

From: Helge Deller <deller@gmx.de>

Turn on space register hashing for 64-bit CPUs when reset.

Signed-off-by: Helge Deller <deller@gmx.de>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
---
 target/hppa/cpu.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/target/hppa/cpu.c b/target/hppa/cpu.c
index b0bc9d35e4..c86f9190d2 100644
--- a/target/hppa/cpu.c
+++ b/target/hppa/cpu.c
@@ -28,6 +28,7 @@
 #include "exec/translation-block.h"
 #include "fpu/softfloat.h"
 #include "tcg/tcg.h"
+#include "hw/hppa/hppa_hardware.h"
 
 static void hppa_cpu_set_pc(CPUState *cs, vaddr value)
 {
@@ -217,6 +218,10 @@ static void hppa_cpu_reset_hold(Object *obj, ResetType type)
     memset(env, 0, offsetof(CPUHPPAState, end_reset_fields));
 
     cpu_hppa_loaded_fr0(env);
+
+    /* 64-bit machines start with space-register hashing enabled in %dr2 */
+    env->dr[2] = hppa_is_pa20(env) ? HPPA64_DIAG_SPHASH_ENABLE : 0;
+
     cpu_hppa_put_psw(env, PSW_M);
 }
 
-- 
2.47.0



  parent reply	other threads:[~2025-01-31  9:23 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-01-31  9:22 [PULL v2 0/9] Hppa system mfdiag for v10 patches deller
2025-01-31  9:22 ` [PULL v2 1/9] MAINTAINERS: Add myself as HPPA maintainer deller
2025-01-31  9:22 ` [PULL v2 2/9] hppa: Sync contents of hppa_hardware.h header file with SeaBIOS-hppa deller
2025-01-31  9:22 ` [PULL v2 3/9] disas/hppa: implement mfdiag/mtdiag disassembly deller
2025-01-31  9:22 ` [PULL v2 4/9] target/hppa: Add CPU diagnose registers deller
2025-01-31  9:22 ` [PULL v2 5/9] target/hppa: Drop diag_getshadowregs_pa2 and diag_putshadowregs_pa2 deller
2025-01-31  9:22 ` [PULL v2 6/9] target/hppa: Add instruction decoding for mfdiag and mtdiag deller
2025-01-31  9:22 ` deller [this message]
2025-01-31  9:22 ` [PULL v2 8/9] target/hppa: Implement space register hashing for 64-bit HP-UX deller
2025-01-31  9:22 ` [PULL v2 9/9] target/hppa: Update SeaBIOS-hppa to version 18 deller
2025-02-02 17:49 ` [PULL v2 0/9] Hppa system mfdiag for v10 patches Stefan Hajnoczi

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=20250131092229.38232-8-deller@kernel.org \
    --to=deller@kernel.org \
    --cc=deller@gmx.de \
    --cc=peter.maydell@linaro.org \
    --cc=qemu-devel@nongnu.org \
    --cc=richard.henderson@linaro.org \
    --cc=stefanha@redhat.com \
    /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).