Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
sysemu/kvm: Restrict kvm_get_apic_state() to x86 targets
kvm_get_apic_state() is only defined for x86 targets (in
hw/i386/kvm/apic.c). Its declaration is pointless on all
other targets.

Since we include "linux-headers/asm-x86/kvm.h", no need
to forward-declare 'struct kvm_lapic_state'.

Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-ID: <20230904124325.79040-12-philmd@linaro.org>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
  • Loading branch information
philmd authored and bonzini committed Sep 7, 2023
1 parent f3f99d2 commit 1f49d47
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 3 deletions.
3 changes: 0 additions & 3 deletions include/sysemu/kvm.h
Expand Up @@ -188,7 +188,6 @@ extern bool kvm_msi_use_devid;
#endif /* CONFIG_KVM_IS_POSSIBLE */

struct kvm_run;
struct kvm_lapic_state;
struct kvm_irq_routing_entry;

typedef struct KVMCapabilityInfo {
Expand Down Expand Up @@ -407,8 +406,6 @@ void kvm_irqchip_add_change_notifier(Notifier *n);
void kvm_irqchip_remove_change_notifier(Notifier *n);
void kvm_irqchip_change_notify(void);

void kvm_get_apic_state(DeviceState *d, struct kvm_lapic_state *kapic);

struct kvm_guest_debug;
struct kvm_debug_exit_arch;

Expand Down
1 change: 1 addition & 0 deletions target/i386/kvm/kvm_i386.h
Expand Up @@ -54,6 +54,7 @@ bool kvm_has_adjust_clock_stable(void);
bool kvm_has_exception_payload(void);
void kvm_synchronize_all_tsc(void);

void kvm_get_apic_state(DeviceState *d, struct kvm_lapic_state *kapic);
void kvm_put_apicbase(X86CPU *cpu, uint64_t value);

bool kvm_has_x2apic_api(void);
Expand Down

0 comments on commit 1f49d47

Please sign in to comment.