From: Richard Henderson <richard.henderson@linaro.org>
To: qemu-devel@nongnu.org
Subject: [Qemu-devel] [PATCH v3 10/27] target/mips: Pass a valid error to raise_mmu_exception for user-only
Date: Thu, 9 May 2019 15:26:14 -0700 [thread overview]
Message-ID: <20190509222631.14271-11-richard.henderson@linaro.org> (raw)
In-Reply-To: <20190509222631.14271-1-richard.henderson@linaro.org>
At present we give ret = 0, or TLBRET_MATCH. This gets matched
by the default case, which falls through to TLBRET_BADADDR.
However, it makes more sense to use a proper value. All of the
tlb-related exceptions are handled identically in cpu_loop.c,
so TLBRET_BADADDR is as good as any other. Retain it.
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
---
target/mips/helper.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/target/mips/helper.c b/target/mips/helper.c
index c44cdca3b5..cc7be7703a 100644
--- a/target/mips/helper.c
+++ b/target/mips/helper.c
@@ -884,7 +884,7 @@ int mips_cpu_handle_mmu_fault(CPUState *cs, vaddr address, int size, int rw,
int prot;
int access_type;
#endif
- int ret = 0;
+ int ret = TLBRET_BADADDR;
#if 0
log_cpu_state(cs, 0);
--
2.17.1
next prev parent reply other threads:[~2019-05-09 22:29 UTC|newest]
Thread overview: 32+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-05-09 22:26 [Qemu-devel] [PATCH v3 00/27] tcg: Add CPUClass::tlb_fill Richard Henderson
2019-05-09 22:26 ` [Qemu-devel] [PATCH v3 01/27] " Richard Henderson
2019-05-09 22:26 ` [Qemu-devel] [PATCH v3 02/27] target/alpha: Convert to CPUClass::tlb_fill Richard Henderson
2019-05-09 22:26 ` [Qemu-devel] [PATCH v3 03/27] target/arm: " Richard Henderson
2019-05-09 22:26 ` [Qemu-devel] [PATCH v3 04/27] target/cris: " Richard Henderson
2019-05-09 22:26 ` [Qemu-devel] [PATCH v3 05/27] target/hppa: " Richard Henderson
2019-05-09 22:26 ` [Qemu-devel] [PATCH v3 06/27] target/i386: " Richard Henderson
2019-05-09 22:26 ` [Qemu-devel] [PATCH v3 07/27] target/lm32: " Richard Henderson
2019-05-09 22:26 ` [Qemu-devel] [PATCH v3 08/27] target/m68k: " Richard Henderson
2019-05-09 22:26 ` [Qemu-devel] [PATCH v3 09/27] target/microblaze: " Richard Henderson
2019-05-09 22:26 ` Richard Henderson [this message]
2019-05-09 22:26 ` [Qemu-devel] [PATCH v3 11/27] target/mips: Tidy control flow in mips_cpu_handle_mmu_fault Richard Henderson
2019-05-09 22:26 ` [Qemu-devel] [PATCH v3 12/27] target/mips: Convert to CPUClass::tlb_fill Richard Henderson
2019-05-09 22:26 ` [Qemu-devel] [PATCH v3 13/27] target/moxie: " Richard Henderson
2019-05-09 22:26 ` [Qemu-devel] [PATCH v3 14/27] target/nios2: " Richard Henderson
2019-05-10 8:58 ` Peter Maydell
2019-05-09 22:26 ` [Qemu-devel] [PATCH v3 15/27] target/openrisc: " Richard Henderson
2019-05-09 22:26 ` [Qemu-devel] [PATCH v3 16/27] target/ppc: " Richard Henderson
2019-05-10 1:39 ` David Gibson
2019-05-09 22:26 ` [Qemu-devel] [PATCH v3 17/27] target/riscv: " Richard Henderson
2019-05-09 22:26 ` [Qemu-devel] [PATCH v3 18/27] target/s390x: " Richard Henderson
2019-05-09 22:26 ` [Qemu-devel] [PATCH v3 19/27] target/sh4: " Richard Henderson
2019-05-09 22:26 ` [Qemu-devel] [PATCH v3 20/27] target/sparc: " Richard Henderson
2019-05-10 9:55 ` Peter Maydell
2019-05-10 9:57 ` Peter Maydell
2019-05-09 22:26 ` [Qemu-devel] [PATCH v3 21/27] target/tilegx: " Richard Henderson
2019-05-09 22:26 ` [Qemu-devel] [PATCH v3 22/27] target/tricore: " Richard Henderson
2019-05-09 22:26 ` [Qemu-devel] [PATCH v3 23/27] target/unicore32: " Richard Henderson
2019-05-09 22:26 ` [Qemu-devel] [PATCH v3 24/27] target/xtensa: " Richard Henderson
2019-05-09 22:26 ` [Qemu-devel] [PATCH v3 25/27] tcg: Use CPUClass::tlb_fill in cputlb.c Richard Henderson
2019-05-09 22:26 ` [Qemu-devel] [PATCH v3 26/27] tcg: Remove CPUClass::handle_mmu_fault Richard Henderson
2019-05-09 22:26 ` [Qemu-devel] [PATCH v3 27/27] tcg: Use tlb_fill probe from tlb_vaddr_to_host 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=20190509222631.14271-11-richard.henderson@linaro.org \
--to=richard.henderson@linaro.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).