hv: vlapic: remove vcpu/vm structure pointer from vlapic

We could use container_of to get vcpu/vm structure pointer from vlapic. So vcpu/vm
structure pointer is no need in vlapic structure.

Tracked-On: #4550
Signed-off-by: Li Fei1 <fei1.li@intel.com>
This commit is contained in:
Li Fei1
2020-03-30 11:45:31 +08:00
committed by wenlingz
parent 7f342bf62f
commit a7768fdb6a
2 changed files with 61 additions and 60 deletions

View File

@@ -61,9 +61,6 @@ struct acrn_vlapic {
*/
struct lapic_regs apic_page;
struct acrn_vm *vm;
struct acrn_vcpu *vcpu;
uint32_t esr_pending;
int32_t esr_firing;
@@ -88,6 +85,8 @@ struct acrn_vlapic {
uint32_t lvt_last[VLAPIC_MAXLVT_INDEX + 1];
} __aligned(PAGE_SIZE);
struct acrn_vcpu;
struct acrn_apicv_ops {
void (*accept_intr)(struct acrn_vlapic *vlapic, uint32_t vector, bool level);
bool (*inject_intr)(struct acrn_vlapic *vlapic, bool guest_irq_enabled, bool injected);