[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 2/2] target/s390x: Align __excp_addr in s390_probe_access
From: |
Richard Henderson |
Subject: |
[PATCH 2/2] target/s390x: Align __excp_addr in s390_probe_access |
Date: |
Tue, 23 Aug 2022 14:38:05 -0700 |
Per the comment in s390_cpu_record_sigsegv, the saved address
is always page aligned.
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
---
target/s390x/tcg/mem_helper.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/target/s390x/tcg/mem_helper.c b/target/s390x/tcg/mem_helper.c
index 4c0f8baa39..19ea7d2f8d 100644
--- a/target/s390x/tcg/mem_helper.c
+++ b/target/s390x/tcg/mem_helper.c
@@ -147,7 +147,7 @@ static int s390_probe_access(CPUArchState *env,
target_ulong addr, int size,
#if defined(CONFIG_USER_ONLY)
flags = page_get_flags(addr);
if (!(flags & (access_type == MMU_DATA_LOAD ? PAGE_READ :
PAGE_WRITE_ORG))) {
- env->__excp_addr = addr;
+ env->__excp_addr = addr & TARGET_PAGE_MASK;
flags = (flags & PAGE_VALID) ? PGM_PROTECTION : PGM_ADDRESSING;
if (nonfault) {
return flags;
--
2.34.1