HV:refine 'apic_page' & 'pir_desc' in 'struct acrn_vlapic'

- update 'apic_page' field in 'struct acrn_vlapic',
   from pointer type to 'struct lapic_regs' type.

 - delete 'pir' and update 'pir_desc' to 'vlapic_pir_desc'
   type.

 - fix potential memory leak in 'vlapic_create()'
   should free allocated memory in case of registering
   mmio handler failure.

Signed-off-by: Yonghua Huang <yonghua.huang@intel.com>
This commit is contained in:
Yonghua Huang
2018-08-20 18:25:48 +08:00
committed by lijinxia
parent 17ef5076a4
commit e0d40feaa8
4 changed files with 68 additions and 77 deletions

View File

@@ -167,7 +167,7 @@ struct lapic_regs {
/* reserved */ PAD4;
uint32_t dcr_timer; PAD3;
/* reserved */ PAD4;
};
} __aligned(CPU_PAGE_SIZE);
enum LAPIC_REGISTERS {
LAPIC_ID = 0x2,