]> git.ipfire.org Git - thirdparty/qemu.git/commitdiff
hw/core/cpu: Move CacheType to general cpu.h
authorZhao Liu <zhao1.liu@intel.com>
Thu, 5 Jun 2025 13:27:22 +0000 (21:27 +0800)
committerPhilippe Mathieu-Daudé <philmd@linaro.org>
Tue, 10 Jun 2025 10:59:09 +0000 (12:59 +0200)
I386 has already defined cache types in target/i386/cpu.h.

Move CacheType to hw/core/cpu.h, so that ARM and other architectures
could use it.

Cc: Alireza Sanaee <alireza.sanaee@huawei.com>
Signed-off-by: Zhao Liu <zhao1.liu@intel.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-ID: <20250605132722.3597593-1-zhao1.liu@intel.com>
Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
include/hw/core/cpu.h
target/i386/cpu.h

index 1e87f7d393ec044e3a0861aad7bd24826643a860..33296a1c080eb8ce9f73e98b8dc3c49c2519ecfa 100644 (file)
@@ -1126,4 +1126,10 @@ extern const VMStateDescription vmstate_cpu_common;
 #define UNASSIGNED_CPU_INDEX -1
 #define UNASSIGNED_CLUSTER_INDEX -1
 
+enum CacheType {
+    DATA_CACHE,
+    INSTRUCTION_CACHE,
+    UNIFIED_CACHE
+};
+
 #endif
index 545851cbde1e76fbedcfd4ff2db6942d4aad5c0f..5910dcf74d42f96f882d14d2cc4d34d5a3c99d64 100644 (file)
@@ -1773,12 +1773,6 @@ typedef enum TPRAccess {
 
 /* Cache information data structures: */
 
-enum CacheType {
-    DATA_CACHE,
-    INSTRUCTION_CACHE,
-    UNIFIED_CACHE
-};
-
 typedef struct CPUCacheInfo {
     enum CacheType type;
     uint8_t level;