hv: rename VM exit handlers in vlapic

to keep aligned with the vmexit reasons' name defined in
SPEC.

Signed-off-by: Yonghua Huang <yonghua.huang@intel.com>
This commit is contained in:
Yonghua Huang 2018-03-22 17:42:44 +08:00 committed by Jack Ren
parent 23c12b7a74
commit d6904b412c
3 changed files with 13 additions and 13 deletions

View File

@ -2337,7 +2337,7 @@ apicv_inject_pir(struct vlapic *vlapic)
} }
} }
int apic_access_exit_handler(struct vcpu *vcpu) int apic_access_vmexit_handler(struct vcpu *vcpu)
{ {
bool ret; bool ret;
int access_type, offset; int access_type, offset;
@ -2366,7 +2366,7 @@ int apic_access_exit_handler(struct vcpu *vcpu)
return 0; return 0;
} }
int apicv_virtualized_eoi_exit_handler(struct vcpu *vcpu) int veoi_vmexit_handler(struct vcpu *vcpu)
{ {
struct vlapic *vlapic = NULL; struct vlapic *vlapic = NULL;
@ -2395,7 +2395,7 @@ int apicv_virtualized_eoi_exit_handler(struct vcpu *vcpu)
return 0; return 0;
} }
int apicv_write_exit_handler(struct vcpu *vcpu) int apic_write_vmexit_handler(struct vcpu *vcpu)
{ {
bool retu; bool retu;
uint64_t qual; uint64_t qual;
@ -2455,8 +2455,8 @@ int apicv_write_exit_handler(struct vcpu *vcpu)
return handled; return handled;
} }
int apic_tpr_below_threshold_exit_handler(__unused struct vcpu *vcpu) int tpr_below_threshold_vmexit_handler(__unused struct vcpu *vcpu)
{ {
pr_err("Unhandled %s,", __func__); pr_err("Unhandled %s.", __func__);
return 0; return 0;
} }

View File

@ -123,12 +123,12 @@ static const struct vm_exit_dispatch dispatch_table[] = {
[VMX_EXIT_REASON_ENTRY_FAILURE_MACHINE_CHECK] = { [VMX_EXIT_REASON_ENTRY_FAILURE_MACHINE_CHECK] = {
.handler = unhandled_vmexit_handler}, .handler = unhandled_vmexit_handler},
[VMX_EXIT_REASON_TPR_BELOW_THRESHOLD] = { [VMX_EXIT_REASON_TPR_BELOW_THRESHOLD] = {
.handler = apic_tpr_below_threshold_exit_handler}, .handler = tpr_below_threshold_vmexit_handler},
[VMX_EXIT_REASON_APIC_ACCESS] = { [VMX_EXIT_REASON_APIC_ACCESS] = {
.handler = apic_access_exit_handler, .handler = apic_access_vmexit_handler,
.need_exit_qualification = 1}, .need_exit_qualification = 1},
[VMX_EXIT_REASON_VIRTUALIZED_EOI] = { [VMX_EXIT_REASON_VIRTUALIZED_EOI] = {
.handler = apicv_virtualized_eoi_exit_handler, .handler = veoi_vmexit_handler,
.need_exit_qualification = 1}, .need_exit_qualification = 1},
[VMX_EXIT_REASON_GDTR_IDTR_ACCESS] = { [VMX_EXIT_REASON_GDTR_IDTR_ACCESS] = {
.handler = unhandled_vmexit_handler}, .handler = unhandled_vmexit_handler},
@ -153,7 +153,7 @@ static const struct vm_exit_dispatch dispatch_table[] = {
[VMX_EXIT_REASON_XSETBV] = { [VMX_EXIT_REASON_XSETBV] = {
.handler = unhandled_vmexit_handler}, .handler = unhandled_vmexit_handler},
[VMX_EXIT_REASON_APIC_WRITE] = { [VMX_EXIT_REASON_APIC_WRITE] = {
.handler = apicv_write_exit_handler, .handler = apic_write_vmexit_handler,
.need_exit_qualification = 1} .need_exit_qualification = 1}
}; };

View File

@ -125,10 +125,10 @@ uint64_t apicv_get_apic_access_addr(struct vm *vm);
uint64_t apicv_get_apic_page_addr(struct vlapic *vlapic); uint64_t apicv_get_apic_page_addr(struct vlapic *vlapic);
bool vlapic_apicv_enabled(struct vcpu *vcpu); bool vlapic_apicv_enabled(struct vcpu *vcpu);
void apicv_inject_pir(struct vlapic *vlapic); void apicv_inject_pir(struct vlapic *vlapic);
int apic_access_exit_handler(struct vcpu *vcpu); int apic_access_vmexit_handler(struct vcpu *vcpu);
int apicv_write_exit_handler(struct vcpu *vcpu); int apic_write_vmexit_handler(struct vcpu *vcpu);
int apicv_virtualized_eoi_exit_handler(struct vcpu *vcpu); int veoi_vmexit_handler(struct vcpu *vcpu);
int apic_tpr_below_threshold_exit_handler(struct vcpu *vcpu); int tpr_below_threshold_vmexit_handler(struct vcpu *vcpu);
void calcvdest(struct vm *vm, uint64_t *dmask, uint32_t dest, bool phys); void calcvdest(struct vm *vm, uint64_t *dmask, uint32_t dest, bool phys);
#endif /* _VLAPIC_H_ */ #endif /* _VLAPIC_H_ */