cpu: Remove CPU_COMMON
This macro is now always empty, so remove it. This leaves the entire contents of CPUArchState under the control of the guest architecture. Reviewed-by: Alistair Francis <alistair.francis@wdc.com> Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
This commit is contained in:
parent
269bd5d8f6
commit
e8b5fae516
@ -231,8 +231,6 @@ typedef struct CPUTLB { } CPUTLB;
|
|||||||
|
|
||||||
#endif /* !CONFIG_USER_ONLY && CONFIG_TCG */
|
#endif /* !CONFIG_USER_ONLY && CONFIG_TCG */
|
||||||
|
|
||||||
#define CPU_COMMON /* Nothing */
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* This structure must be placed in ArchCPU immedately
|
* This structure must be placed in ArchCPU immedately
|
||||||
* before CPUArchState, as a field named "neg".
|
* before CPUArchState, as a field named "neg".
|
||||||
|
@ -251,9 +251,6 @@ struct CPUAlphaState {
|
|||||||
/* This alarm doesn't exist in real hardware; we wish it did. */
|
/* This alarm doesn't exist in real hardware; we wish it did. */
|
||||||
uint64_t alarm_expire;
|
uint64_t alarm_expire;
|
||||||
|
|
||||||
/* Those resources are used only in QEMU core */
|
|
||||||
CPU_COMMON
|
|
||||||
|
|
||||||
int error_code;
|
int error_code;
|
||||||
|
|
||||||
uint32_t features;
|
uint32_t features;
|
||||||
|
@ -645,9 +645,7 @@ typedef struct CPUARMState {
|
|||||||
/* Fields up to this point are cleared by a CPU reset */
|
/* Fields up to this point are cleared by a CPU reset */
|
||||||
struct {} end_reset_fields;
|
struct {} end_reset_fields;
|
||||||
|
|
||||||
CPU_COMMON
|
/* Fields after this point are preserved across CPU reset. */
|
||||||
|
|
||||||
/* Fields after CPU_COMMON are preserved across CPU reset. */
|
|
||||||
|
|
||||||
/* Internal CPU feature flags. */
|
/* Internal CPU feature flags. */
|
||||||
uint64_t features;
|
uint64_t features;
|
||||||
|
@ -163,8 +163,6 @@ typedef struct CPUCRISState {
|
|||||||
/* Fields up to this point are cleared by a CPU reset */
|
/* Fields up to this point are cleared by a CPU reset */
|
||||||
struct {} end_reset_fields;
|
struct {} end_reset_fields;
|
||||||
|
|
||||||
CPU_COMMON
|
|
||||||
|
|
||||||
/* Members from load_info on are preserved across resets. */
|
/* Members from load_info on are preserved across resets. */
|
||||||
void *load_info;
|
void *load_info;
|
||||||
} CPUCRISState;
|
} CPUCRISState;
|
||||||
|
@ -197,9 +197,6 @@ struct CPUHPPAState {
|
|||||||
target_ureg cr_back[2]; /* back of cr17/cr18 */
|
target_ureg cr_back[2]; /* back of cr17/cr18 */
|
||||||
target_ureg shadow[7]; /* shadow registers */
|
target_ureg shadow[7]; /* shadow registers */
|
||||||
|
|
||||||
/* Those resources are used only in QEMU core */
|
|
||||||
CPU_COMMON
|
|
||||||
|
|
||||||
/* ??? The number of entries isn't specified by the architecture. */
|
/* ??? The number of entries isn't specified by the architecture. */
|
||||||
/* ??? Implement a unified itlb/dtlb for the moment. */
|
/* ??? Implement a unified itlb/dtlb for the moment. */
|
||||||
/* ??? We should use a more intelligent data structure. */
|
/* ??? We should use a more intelligent data structure. */
|
||||||
|
@ -1289,9 +1289,7 @@ typedef struct CPUX86State {
|
|||||||
/* Fields up to this point are cleared by a CPU reset */
|
/* Fields up to this point are cleared by a CPU reset */
|
||||||
struct {} end_reset_fields;
|
struct {} end_reset_fields;
|
||||||
|
|
||||||
CPU_COMMON
|
/* Fields after this point are preserved across CPU reset. */
|
||||||
|
|
||||||
/* Fields after CPU_COMMON are preserved across CPU reset. */
|
|
||||||
|
|
||||||
/* processor features (e.g. for CPUID insn) */
|
/* processor features (e.g. for CPUID insn) */
|
||||||
/* Minimum level/xlevel/xlevel2, based on CPU model + features */
|
/* Minimum level/xlevel/xlevel2, based on CPU model + features */
|
||||||
|
@ -159,8 +159,6 @@ struct CPULM32State {
|
|||||||
/* Fields up to this point are cleared by a CPU reset */
|
/* Fields up to this point are cleared by a CPU reset */
|
||||||
struct {} end_reset_fields;
|
struct {} end_reset_fields;
|
||||||
|
|
||||||
CPU_COMMON
|
|
||||||
|
|
||||||
/* Fields from here on are preserved across CPU reset. */
|
/* Fields from here on are preserved across CPU reset. */
|
||||||
uint32_t eba; /* exception base address */
|
uint32_t eba; /* exception base address */
|
||||||
uint32_t deba; /* debug exception base address */
|
uint32_t deba; /* debug exception base address */
|
||||||
|
@ -143,8 +143,6 @@ typedef struct CPUM68KState {
|
|||||||
/* Fields up to this point are cleared by a CPU reset */
|
/* Fields up to this point are cleared by a CPU reset */
|
||||||
struct {} end_reset_fields;
|
struct {} end_reset_fields;
|
||||||
|
|
||||||
CPU_COMMON
|
|
||||||
|
|
||||||
/* Fields from here on are preserved across CPU reset. */
|
/* Fields from here on are preserved across CPU reset. */
|
||||||
uint32_t features;
|
uint32_t features;
|
||||||
} CPUM68KState;
|
} CPUM68KState;
|
||||||
|
@ -266,8 +266,6 @@ struct CPUMBState {
|
|||||||
/* Fields up to this point are cleared by a CPU reset */
|
/* Fields up to this point are cleared by a CPU reset */
|
||||||
struct {} end_reset_fields;
|
struct {} end_reset_fields;
|
||||||
|
|
||||||
CPU_COMMON
|
|
||||||
|
|
||||||
/* These fields are preserved on reset. */
|
/* These fields are preserved on reset. */
|
||||||
|
|
||||||
struct {
|
struct {
|
||||||
|
@ -1041,8 +1041,6 @@ struct CPUMIPSState {
|
|||||||
/* Fields up to this point are cleared by a CPU reset */
|
/* Fields up to this point are cleared by a CPU reset */
|
||||||
struct {} end_reset_fields;
|
struct {} end_reset_fields;
|
||||||
|
|
||||||
CPU_COMMON
|
|
||||||
|
|
||||||
/* Fields from here on are preserved across CPU reset. */
|
/* Fields from here on are preserved across CPU reset. */
|
||||||
CPUMIPSMVPContext *mvp;
|
CPUMIPSMVPContext *mvp;
|
||||||
#if !defined(CONFIG_USER_ONLY)
|
#if !defined(CONFIG_USER_ONLY)
|
||||||
|
@ -45,9 +45,6 @@ typedef struct CPUMoxieState {
|
|||||||
|
|
||||||
/* Fields up to this point are cleared by a CPU reset */
|
/* Fields up to this point are cleared by a CPU reset */
|
||||||
struct {} end_reset_fields;
|
struct {} end_reset_fields;
|
||||||
|
|
||||||
CPU_COMMON
|
|
||||||
|
|
||||||
} CPUMoxieState;
|
} CPUMoxieState;
|
||||||
|
|
||||||
#include "qom/cpu.h"
|
#include "qom/cpu.h"
|
||||||
|
@ -167,8 +167,6 @@ struct CPUNios2State {
|
|||||||
|
|
||||||
uint32_t irq_pending;
|
uint32_t irq_pending;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
CPU_COMMON
|
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -286,8 +286,6 @@ typedef struct CPUOpenRISCState {
|
|||||||
/* Fields up to this point are cleared by a CPU reset */
|
/* Fields up to this point are cleared by a CPU reset */
|
||||||
struct {} end_reset_fields;
|
struct {} end_reset_fields;
|
||||||
|
|
||||||
CPU_COMMON
|
|
||||||
|
|
||||||
/* Fields from here on are preserved across CPU reset. */
|
/* Fields from here on are preserved across CPU reset. */
|
||||||
uint32_t cpucfgr; /* CPU configure register */
|
uint32_t cpucfgr; /* CPU configure register */
|
||||||
|
|
||||||
|
@ -999,8 +999,6 @@ struct CPUPPCState {
|
|||||||
/* when a memory exception occurs, the access type is stored here */
|
/* when a memory exception occurs, the access type is stored here */
|
||||||
int access_type;
|
int access_type;
|
||||||
|
|
||||||
CPU_COMMON
|
|
||||||
|
|
||||||
/* MMU context - only relevant for full system emulation */
|
/* MMU context - only relevant for full system emulation */
|
||||||
#if !defined(CONFIG_USER_ONLY)
|
#if !defined(CONFIG_USER_ONLY)
|
||||||
#if defined(TARGET_PPC64)
|
#if defined(TARGET_PPC64)
|
||||||
|
@ -171,9 +171,6 @@ struct CPURISCVState {
|
|||||||
|
|
||||||
float_status fp_status;
|
float_status fp_status;
|
||||||
|
|
||||||
/* QEMU */
|
|
||||||
CPU_COMMON
|
|
||||||
|
|
||||||
/* Fields from here on are preserved across CPU reset. */
|
/* Fields from here on are preserved across CPU reset. */
|
||||||
QEMUTimer *timer; /* Internal timer */
|
QEMUTimer *timer; /* Internal timer */
|
||||||
};
|
};
|
||||||
|
@ -114,8 +114,6 @@ struct CPUS390XState {
|
|||||||
/* Fields up to this point are cleared by a CPU reset */
|
/* Fields up to this point are cleared by a CPU reset */
|
||||||
struct {} end_reset_fields;
|
struct {} end_reset_fields;
|
||||||
|
|
||||||
CPU_COMMON
|
|
||||||
|
|
||||||
#if !defined(CONFIG_USER_ONLY)
|
#if !defined(CONFIG_USER_ONLY)
|
||||||
uint32_t core_id; /* PoP "CPU address", same as cpu_index */
|
uint32_t core_id; /* PoP "CPU address", same as cpu_index */
|
||||||
uint64_t cpuid;
|
uint64_t cpuid;
|
||||||
|
@ -179,8 +179,6 @@ typedef struct CPUSH4State {
|
|||||||
/* Fields up to this point are cleared by a CPU reset */
|
/* Fields up to this point are cleared by a CPU reset */
|
||||||
struct {} end_reset_fields;
|
struct {} end_reset_fields;
|
||||||
|
|
||||||
CPU_COMMON
|
|
||||||
|
|
||||||
/* Fields from here on are preserved over CPU reset. */
|
/* Fields from here on are preserved over CPU reset. */
|
||||||
int id; /* CPU model */
|
int id; /* CPU model */
|
||||||
|
|
||||||
|
@ -446,8 +446,6 @@ struct CPUSPARCState {
|
|||||||
/* Fields up to this point are cleared by a CPU reset */
|
/* Fields up to this point are cleared by a CPU reset */
|
||||||
struct {} end_reset_fields;
|
struct {} end_reset_fields;
|
||||||
|
|
||||||
CPU_COMMON
|
|
||||||
|
|
||||||
/* Fields from here on are preserved across CPU reset. */
|
/* Fields from here on are preserved across CPU reset. */
|
||||||
target_ulong version;
|
target_ulong version;
|
||||||
uint32_t nwindows;
|
uint32_t nwindows;
|
||||||
|
@ -93,8 +93,6 @@ typedef struct CPUTLGState {
|
|||||||
|
|
||||||
/* Fields up to this point are cleared by a CPU reset */
|
/* Fields up to this point are cleared by a CPU reset */
|
||||||
struct {} end_reset_fields;
|
struct {} end_reset_fields;
|
||||||
|
|
||||||
CPU_COMMON
|
|
||||||
} CPUTLGState;
|
} CPUTLGState;
|
||||||
|
|
||||||
#include "qom/cpu.h"
|
#include "qom/cpu.h"
|
||||||
|
@ -184,8 +184,6 @@ struct CPUTriCoreState {
|
|||||||
int error_code;
|
int error_code;
|
||||||
uint32_t hflags; /* CPU State */
|
uint32_t hflags; /* CPU State */
|
||||||
|
|
||||||
CPU_COMMON
|
|
||||||
|
|
||||||
/* Internal CPU feature flags. */
|
/* Internal CPU feature flags. */
|
||||||
uint64_t features;
|
uint64_t features;
|
||||||
|
|
||||||
|
@ -55,8 +55,6 @@ typedef struct CPUUniCore32State {
|
|||||||
float_status fp_status;
|
float_status fp_status;
|
||||||
} ucf64;
|
} ucf64;
|
||||||
|
|
||||||
CPU_COMMON
|
|
||||||
|
|
||||||
/* Internal CPU feature flags. */
|
/* Internal CPU feature flags. */
|
||||||
uint32_t features;
|
uint32_t features;
|
||||||
|
|
||||||
|
@ -541,8 +541,6 @@ typedef struct CPUXtensaState {
|
|||||||
|
|
||||||
/* Watchpoints for DBREAK registers */
|
/* Watchpoints for DBREAK registers */
|
||||||
struct CPUWatchpoint *cpu_watchpoint[MAX_NDBREAK];
|
struct CPUWatchpoint *cpu_watchpoint[MAX_NDBREAK];
|
||||||
|
|
||||||
CPU_COMMON
|
|
||||||
} CPUXtensaState;
|
} CPUXtensaState;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
Reference in New Issue
Block a user