[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 08/13] target: Include missing 'cpu.h'
From: |
Philippe Mathieu-Daudé |
Subject: |
[PATCH 08/13] target: Include missing 'cpu.h' |
Date: |
Tue, 8 Feb 2022 16:22:38 +0100 |
These target-specific files use the target-specific CPU state
but lack to include "cpu.h"; i.e.:
../target/riscv/pmp.h:61:23: error: unknown type name 'CPURISCVState'
void pmpcfg_csr_write(CPURISCVState *env, uint32_t reg_index,
^
../target/nios2/mmu.h:43:18: error: unknown type name 'CPUNios2State'
void mmu_flip_um(CPUNios2State *env, unsigned int um);
^
../target/microblaze/mmu.h:88:19: error: unknown type name 'CPUMBState';
did you mean 'CPUState'?
uint32_t mmu_read(CPUMBState *env, bool ea, uint32_t rn);
^~~~~~~~~~
CPUState
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
---
target/microblaze/mmu.h | 2 ++
target/mips/internal.h | 1 +
target/nios2/mmu.h | 2 ++
target/riscv/pmp.h | 2 ++
4 files changed, 7 insertions(+)
diff --git a/target/microblaze/mmu.h b/target/microblaze/mmu.h
index b6b4b9ad60..1068bd2d52 100644
--- a/target/microblaze/mmu.h
+++ b/target/microblaze/mmu.h
@@ -20,6 +20,8 @@
#ifndef TARGET_MICROBLAZE_MMU_H
#define TARGET_MICROBLAZE_MMU_H
+#include "cpu.h"
+
#define MMU_R_PID 0
#define MMU_R_ZPR 1
#define MMU_R_TLBX 2
diff --git a/target/mips/internal.h b/target/mips/internal.h
index daddb05fd4..f705d6bfa6 100644
--- a/target/mips/internal.h
+++ b/target/mips/internal.h
@@ -12,6 +12,7 @@
#ifdef CONFIG_TCG
#include "tcg/tcg-internal.h"
#endif
+#include "cpu.h"
/*
* MMU types, the first four entries have the same layout as the
diff --git a/target/nios2/mmu.h b/target/nios2/mmu.h
index 4f46fbb82e..d36b8cc86a 100644
--- a/target/nios2/mmu.h
+++ b/target/nios2/mmu.h
@@ -21,6 +21,8 @@
#ifndef NIOS2_MMU_H
#define NIOS2_MMU_H
+#include "cpu.h"
+
typedef struct Nios2TLBEntry {
target_ulong tag;
target_ulong data;
diff --git a/target/riscv/pmp.h b/target/riscv/pmp.h
index a9a0b363a7..fcb6b7c467 100644
--- a/target/riscv/pmp.h
+++ b/target/riscv/pmp.h
@@ -22,6 +22,8 @@
#ifndef RISCV_PMP_H
#define RISCV_PMP_H
+#include "cpu.h"
+
typedef enum {
PMP_READ = 1 << 0,
PMP_WRITE = 1 << 1,
--
2.34.1
- [PATCH 03/13] accel: Elide kvm_update_guest_debug by checking kvm_supports_guest_debug, (continued)
- [PATCH 03/13] accel: Elide kvm_update_guest_debug by checking kvm_supports_guest_debug, Philippe Mathieu-Daudé, 2022/02/08
- [PATCH 04/13] target/i386/cpu: Ensure accelerators set CPU addressble physical bits, Philippe Mathieu-Daudé, 2022/02/08
- [PATCH 06/13] cpu: Add missing 'exec/exec-all.h' and ''exec/exec-all.h'' headers, Philippe Mathieu-Daudé, 2022/02/08
- [PATCH 05/13] target/i386/tcg/sysemu: Include missing 'exec/exec-all.h' header, Philippe Mathieu-Daudé, 2022/02/08
- [PATCH 07/13] cpu: Move common code to cpu-common, Philippe Mathieu-Daudé, 2022/02/08
- [PATCH 08/13] target: Include missing 'cpu.h',
Philippe Mathieu-Daudé <=
- [PATCH 09/13] target: Use forward declared type instead of structure type, Philippe Mathieu-Daudé, 2022/02/08
- [PATCH 10/13] target: Use CPUArchState as interface to target-specific CPU state, Philippe Mathieu-Daudé, 2022/02/08
- [PATCH 11/13] exec/cpu_ldst: Restrict TCG-specific code, Philippe Mathieu-Daudé, 2022/02/08
- [PATCH 12/13] exec/cpu-all: Restrict cpu_copy() to user emulation, Philippe Mathieu-Daudé, 2022/02/08