mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-09 02:24:58 -06:00
target/arm: move kvm stubs and remove CONFIG_KVM from kvm_arm.h
Add a forward decl for struct kvm_vcpu_init to avoid pulling all kvm headers. Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Signed-off-by: Pierrick Bouvier <pierrick.bouvier@linaro.org> Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org> Message-id: 20250512180502.2395029-5-pierrick.bouvier@linaro.org Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
This commit is contained in:
parent
b2bb3f3576
commit
9a27ee9ca4
2 changed files with 78 additions and 82 deletions
|
@ -22,3 +22,80 @@ bool write_list_to_kvmstate(ARMCPU *cpu, int level)
|
||||||
{
|
{
|
||||||
g_assert_not_reached();
|
g_assert_not_reached();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* It's safe to call these functions without KVM support.
|
||||||
|
* They should either do nothing or return "not supported".
|
||||||
|
*/
|
||||||
|
bool kvm_arm_aarch32_supported(void)
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
bool kvm_arm_pmu_supported(void)
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
bool kvm_arm_sve_supported(void)
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
bool kvm_arm_mte_supported(void)
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* These functions should never actually be called without KVM support.
|
||||||
|
*/
|
||||||
|
void kvm_arm_set_cpu_features_from_host(ARMCPU *cpu)
|
||||||
|
{
|
||||||
|
g_assert_not_reached();
|
||||||
|
}
|
||||||
|
|
||||||
|
void kvm_arm_add_vcpu_properties(ARMCPU *cpu)
|
||||||
|
{
|
||||||
|
g_assert_not_reached();
|
||||||
|
}
|
||||||
|
|
||||||
|
int kvm_arm_get_max_vm_ipa_size(MachineState *ms, bool *fixed_ipa)
|
||||||
|
{
|
||||||
|
g_assert_not_reached();
|
||||||
|
}
|
||||||
|
|
||||||
|
int kvm_arm_vgic_probe(void)
|
||||||
|
{
|
||||||
|
g_assert_not_reached();
|
||||||
|
}
|
||||||
|
|
||||||
|
void kvm_arm_pmu_set_irq(ARMCPU *cpu, int irq)
|
||||||
|
{
|
||||||
|
g_assert_not_reached();
|
||||||
|
}
|
||||||
|
|
||||||
|
void kvm_arm_pmu_init(ARMCPU *cpu)
|
||||||
|
{
|
||||||
|
g_assert_not_reached();
|
||||||
|
}
|
||||||
|
|
||||||
|
void kvm_arm_pvtime_init(ARMCPU *cpu, uint64_t ipa)
|
||||||
|
{
|
||||||
|
g_assert_not_reached();
|
||||||
|
}
|
||||||
|
|
||||||
|
void kvm_arm_steal_time_finalize(ARMCPU *cpu, Error **errp)
|
||||||
|
{
|
||||||
|
g_assert_not_reached();
|
||||||
|
}
|
||||||
|
|
||||||
|
uint32_t kvm_arm_sve_get_vls(ARMCPU *cpu)
|
||||||
|
{
|
||||||
|
g_assert_not_reached();
|
||||||
|
}
|
||||||
|
|
||||||
|
void kvm_arm_enable_mte(Object *cpuobj, Error **errp)
|
||||||
|
{
|
||||||
|
g_assert_not_reached();
|
||||||
|
}
|
||||||
|
|
|
@ -94,7 +94,7 @@ void kvm_arm_cpu_post_load(ARMCPU *cpu);
|
||||||
*/
|
*/
|
||||||
void kvm_arm_reset_vcpu(ARMCPU *cpu);
|
void kvm_arm_reset_vcpu(ARMCPU *cpu);
|
||||||
|
|
||||||
#ifdef CONFIG_KVM
|
struct kvm_vcpu_init;
|
||||||
/**
|
/**
|
||||||
* kvm_arm_create_scratch_host_vcpu:
|
* kvm_arm_create_scratch_host_vcpu:
|
||||||
* @fdarray: filled in with kvmfd, vmfd, cpufd file descriptors in that order
|
* @fdarray: filled in with kvmfd, vmfd, cpufd file descriptors in that order
|
||||||
|
@ -216,85 +216,4 @@ int kvm_arm_set_irq(int cpu, int irqtype, int irq, int level);
|
||||||
|
|
||||||
void kvm_arm_enable_mte(Object *cpuobj, Error **errp);
|
void kvm_arm_enable_mte(Object *cpuobj, Error **errp);
|
||||||
|
|
||||||
#else
|
|
||||||
|
|
||||||
/*
|
|
||||||
* It's safe to call these functions without KVM support.
|
|
||||||
* They should either do nothing or return "not supported".
|
|
||||||
*/
|
|
||||||
static inline bool kvm_arm_aarch32_supported(void)
|
|
||||||
{
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
static inline bool kvm_arm_pmu_supported(void)
|
|
||||||
{
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
static inline bool kvm_arm_sve_supported(void)
|
|
||||||
{
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
static inline bool kvm_arm_mte_supported(void)
|
|
||||||
{
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
* These functions should never actually be called without KVM support.
|
|
||||||
*/
|
|
||||||
static inline void kvm_arm_set_cpu_features_from_host(ARMCPU *cpu)
|
|
||||||
{
|
|
||||||
g_assert_not_reached();
|
|
||||||
}
|
|
||||||
|
|
||||||
static inline void kvm_arm_add_vcpu_properties(ARMCPU *cpu)
|
|
||||||
{
|
|
||||||
g_assert_not_reached();
|
|
||||||
}
|
|
||||||
|
|
||||||
static inline int kvm_arm_get_max_vm_ipa_size(MachineState *ms, bool *fixed_ipa)
|
|
||||||
{
|
|
||||||
g_assert_not_reached();
|
|
||||||
}
|
|
||||||
|
|
||||||
static inline int kvm_arm_vgic_probe(void)
|
|
||||||
{
|
|
||||||
g_assert_not_reached();
|
|
||||||
}
|
|
||||||
|
|
||||||
static inline void kvm_arm_pmu_set_irq(ARMCPU *cpu, int irq)
|
|
||||||
{
|
|
||||||
g_assert_not_reached();
|
|
||||||
}
|
|
||||||
|
|
||||||
static inline void kvm_arm_pmu_init(ARMCPU *cpu)
|
|
||||||
{
|
|
||||||
g_assert_not_reached();
|
|
||||||
}
|
|
||||||
|
|
||||||
static inline void kvm_arm_pvtime_init(ARMCPU *cpu, uint64_t ipa)
|
|
||||||
{
|
|
||||||
g_assert_not_reached();
|
|
||||||
}
|
|
||||||
|
|
||||||
static inline void kvm_arm_steal_time_finalize(ARMCPU *cpu, Error **errp)
|
|
||||||
{
|
|
||||||
g_assert_not_reached();
|
|
||||||
}
|
|
||||||
|
|
||||||
static inline uint32_t kvm_arm_sve_get_vls(ARMCPU *cpu)
|
|
||||||
{
|
|
||||||
g_assert_not_reached();
|
|
||||||
}
|
|
||||||
|
|
||||||
static inline void kvm_arm_enable_mte(Object *cpuobj, Error **errp)
|
|
||||||
{
|
|
||||||
g_assert_not_reached();
|
|
||||||
}
|
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue