]> xenbits.xensource.com Git - qemu-xen.git/commitdiff
include/exec: Set default `NB_MMU_MODES` to 16
authorAnton Johansson <anjo@rev.ng>
Mon, 6 Mar 2023 17:52:08 +0000 (18:52 +0100)
committerRichard Henderson <richard.henderson@linaro.org>
Mon, 13 Mar 2023 13:44:35 +0000 (06:44 -0700)
Signed-off-by: Anton Johansson <anjo@rev.ng>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Alex Bennée <alex.bennee@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Message-Id: <20230306175230.7110-2-anjo@rev.ng>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
include/exec/cpu-defs.h

index cd8aa177cc20e5a93d309a6117af963c3157f886..5f6b8eed95bf7b4b1c237025704c00c35ec878f5 100644 (file)
@@ -36,9 +36,6 @@
 #ifndef TARGET_LONG_BITS
 # error TARGET_LONG_BITS must be defined in cpu-param.h
 #endif
-#ifndef NB_MMU_MODES
-# error NB_MMU_MODES must be defined in cpu-param.h
-#endif
 #ifndef TARGET_PHYS_ADDR_SPACE_BITS
 # error TARGET_PHYS_ADDR_SPACE_BITS must be defined in cpu-param.h
 #endif
 
 #include "exec/target_long.h"
 
+/*
+ * Fix the number of mmu modes to 16, which is also the maximum
+ * supported by the softmmu tlb api.
+ */
+#ifndef NB_MMU_MODES
+#define NB_MMU_MODES 16
+#endif
+
 #if !defined(CONFIG_USER_ONLY) && defined(CONFIG_TCG)
 
 /* use a fully associative victim tlb of 8 entries */