aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorRichard Henderson <richard.henderson@linaro.org>2023-07-07 21:40:37 +0100
committerRichard Henderson <richard.henderson@linaro.org>2023-07-15 08:02:32 +0100
commitc2281ddcf38cb851857718acc388f1b9b7564f39 (patch)
treed3ca780adcb192c1d3ecac44b8f8ab9dc9743f09 /include
parent4b840f96096d11a69122de4b045a327a6e9a7dfa (diff)
downloadqemu-c2281ddcf38cb851857718acc388f1b9b7564f39.zip
qemu-c2281ddcf38cb851857718acc388f1b9b7564f39.tar.gz
qemu-c2281ddcf38cb851857718acc388f1b9b7564f39.tar.bz2
accel/tcg: Introduce page_check_range_empty
Examine the interval tree to validate that a region has no existing mappings. Reviewed-by: Alex Bennée <alex.bennee@linaro.org> Signed-off-by: Richard Henderson <richard.henderson@linaro.org> Message-Id: <20230707204054.8792-10-richard.henderson@linaro.org>
Diffstat (limited to 'include')
-rw-r--r--include/exec/cpu-all.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/include/exec/cpu-all.h b/include/exec/cpu-all.h
index 472fe9a..94f828b 100644
--- a/include/exec/cpu-all.h
+++ b/include/exec/cpu-all.h
@@ -225,6 +225,18 @@ void page_reset_target_data(target_ulong start, target_ulong last);
int page_check_range(target_ulong start, target_ulong len, int flags);
/**
+ * page_check_range_empty:
+ * @start: first byte of range
+ * @last: last byte of range
+ * Context: holding mmap lock
+ *
+ * Return true if the entire range [@start, @last] is unmapped.
+ * The memory lock must be held so that the caller will can ensure
+ * the result stays true until a new mapping can be installed.
+ */
+bool page_check_range_empty(target_ulong start, target_ulong last);
+
+/**
* page_get_target_data(address)
* @address: guest virtual address
*