qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Philippe Mathieu-Daudé" <philmd@linaro.org>
To: qemu-devel@nongnu.org
Cc: "Anton Johansson" <anjo@rev.ng>,
	"Pierrick Bouvier" <pierrick.bouvier@linaro.org>,
	"Yoshinori Sato" <yoshinori.sato@nifty.com>,
	"Philippe Mathieu-Daudé" <philmd@linaro.org>
Subject: [PATCH 1/6] target/sh4: Convert CPUSH4State::sr register to uint32_t type
Date: Wed,  8 Oct 2025 08:48:08 +0200	[thread overview]
Message-ID: <20251008064814.90520-2-philmd@linaro.org> (raw)
In-Reply-To: <20251008064814.90520-1-philmd@linaro.org>

Since its introduction in commit fdf9b3e831e the %SR register
is a uint32_t type.

Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
---
 target/sh4/cpu.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/target/sh4/cpu.h b/target/sh4/cpu.h
index c41ab70dd7c..db27a693f12 100644
--- a/target/sh4/cpu.h
+++ b/target/sh4/cpu.h
@@ -365,14 +365,14 @@ static inline int cpu_ptel_pr (uint32_t ptel)
 #define PTEA_TC        (1 << 3)
 #define cpu_ptea_tc(ptea) (((ptea) & PTEA_TC) >> 3)
 
-static inline target_ulong cpu_read_sr(CPUSH4State *env)
+static inline uint32_t cpu_read_sr(CPUSH4State *env)
 {
     return env->sr | (env->sr_m << SR_M) |
                      (env->sr_q << SR_Q) |
                      (env->sr_t << SR_T);
 }
 
-static inline void cpu_write_sr(CPUSH4State *env, target_ulong sr)
+static inline void cpu_write_sr(CPUSH4State *env, uint32_t sr)
 {
     env->sr_m = (sr >> SR_M) & 1;
     env->sr_q = (sr >> SR_Q) & 1;
-- 
2.51.0



  reply	other threads:[~2025-10-08  6:49 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-10-08  6:48 [PATCH 0/6] target/sh4: Remove all uses of target_ulong type Philippe Mathieu-Daudé
2025-10-08  6:48 ` Philippe Mathieu-Daudé [this message]
2025-10-08 10:46   ` [PATCH 1/6] target/sh4: Convert CPUSH4State::sr register to uint32_t type Anton Johansson via
2025-10-08  6:48 ` [PATCH 2/6] target/sh4: Remove target_ulong use in cpu_sh4_is_cached() Philippe Mathieu-Daudé
2025-10-08 10:48   ` Anton Johansson via
2025-10-08  6:48 ` [PATCH 3/6] target/sh4: Use hwaddr type for hardware addresses Philippe Mathieu-Daudé
2025-10-08 10:52   ` Anton Johansson via
2025-10-08  6:48 ` [PATCH 4/6] target/sh4: Remove target_ulong uses in superh_cpu_get_phys_page_debug Philippe Mathieu-Daudé
2025-10-08 10:57   ` Anton Johansson via
2025-10-08  6:48 ` [PATCH 5/6] target/sh4: Use vaddr type for TLB virtual addresses Philippe Mathieu-Daudé
2025-10-08 11:00   ` Anton Johansson via
2025-10-08  6:48 ` [PATCH 6/6] target/sh4: Remove target_ulong use in gen_goto_tb() Philippe Mathieu-Daudé
2025-10-08 11:03   ` Anton Johansson via
2025-10-15 17:15 ` [PATCH 0/6] target/sh4: Remove all uses of target_ulong type 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=20251008064814.90520-2-philmd@linaro.org \
    --to=philmd@linaro.org \
    --cc=anjo@rev.ng \
    --cc=pierrick.bouvier@linaro.org \
    --cc=qemu-devel@nongnu.org \
    --cc=yoshinori.sato@nifty.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).