aboutsummaryrefslogtreecommitdiff
path: root/include/exec
diff options
context:
space:
mode:
authorRichard Henderson <richard.henderson@linaro.org>2022-08-19 15:49:41 -0700
committerRichard Henderson <richard.henderson@linaro.org>2022-10-03 20:53:30 -0700
commitaf803a4fcb1c707a6a885b5736335baf794f7676 (patch)
tree3663346c9fc832baaffe1743d7f0302b1aa6773c /include/exec
parentc3c8bf579b431b6b305dce12d67ff6fe86bc79e8 (diff)
downloadqemu-af803a4fcb1c707a6a885b5736335baf794f7676.zip
qemu-af803a4fcb1c707a6a885b5736335baf794f7676.tar.gz
qemu-af803a4fcb1c707a6a885b5736335baf794f7676.tar.bz2
accel/tcg: Introduce probe_access_full
Add an interface to return the CPUTLBEntryFull struct that goes with the lookup. The result is not intended to be valid across multiple lookups, so the user must use the results immediately. Reviewed-by: Alex Bennée <alex.bennee@linaro.org> Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Diffstat (limited to 'include/exec')
-rw-r--r--include/exec/exec-all.h15
1 files changed, 15 insertions, 0 deletions
diff --git a/include/exec/exec-all.h b/include/exec/exec-all.h
index bcad607..d255d69 100644
--- a/include/exec/exec-all.h
+++ b/include/exec/exec-all.h
@@ -434,6 +434,21 @@ int probe_access_flags(CPUArchState *env, target_ulong addr,
MMUAccessType access_type, int mmu_idx,
bool nonfault, void **phost, uintptr_t retaddr);
+#ifndef CONFIG_USER_ONLY
+/**
+ * probe_access_full:
+ * Like probe_access_flags, except also return into @pfull.
+ *
+ * The CPUTLBEntryFull structure returned via @pfull is transient
+ * and must be consumed or copied immediately, before any further
+ * access or changes to TLB @mmu_idx.
+ */
+int probe_access_full(CPUArchState *env, target_ulong addr,
+ MMUAccessType access_type, int mmu_idx,
+ bool nonfault, void **phost,
+ CPUTLBEntryFull **pfull, uintptr_t retaddr);
+#endif
+
#define CODE_GEN_ALIGN 16 /* must be >= of the size of a icache line */
/* Estimated block size for TB allocation. */