Skip to content

Commit a89c41d

Browse files
mgcaowenlingz
authored andcommitted
HV: cleanup header files under hypervisor/common
it removes hypervisor.h and just includes needed header files. Tracked-On: #1842 Signed-off-by: Minggui Cao <minggui.cao@intel.com> Acked-by: Eddie Dong <eddie.dong@intel.com>
1 parent 3cb5542 commit a89c41d

File tree

9 files changed

+47
-11
lines changed

9 files changed

+47
-11
lines changed

hypervisor/common/hv_main.c

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,15 @@
44
* SPDX-License-Identifier: BSD-3-Clause
55
*/
66

7-
#include <hypervisor.h>
7+
#include <vm.h>
8+
#include <vmcs.h>
9+
#include <vmexit.h>
10+
#include <irq.h>
811
#include <schedule.h>
912
#include <softirq.h>
13+
#include <profiling.h>
14+
#include <trace.h>
15+
#include <logmsg.h>
1016

1117
void vcpu_thread(struct sched_object *obj)
1218
{

hypervisor/common/hypercall.c

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,20 @@
44
* SPDX-License-Identifier: BSD-3-Clause
55
*/
66

7-
#include <hypervisor.h>
7+
#include <vm.h>
8+
#include <vmcs.h>
89
#include <schedule.h>
910
#include <hypercall.h>
1011
#include <version.h>
1112
#include <reloc.h>
1213
#include <vtd.h>
14+
#include <per_cpu.h>
15+
#include <lapic.h>
16+
#include <assign.h>
17+
#include <ept.h>
18+
#include <mmu.h>
19+
#include <errno.h>
20+
#include <logmsg.h>
1321

1422
#define ACRN_DBG_HYCALL 6U
1523

hypervisor/common/io_req.c

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,11 @@
33
* SPDX-License-Identifier: BSD-3-Clause
44
*/
55

6-
#include <hypervisor.h>
6+
#include <vm.h>
7+
#include <irq.h>
8+
#include <errno.h>
9+
#include <atomic.h>
10+
#include <logmsg.h>
711

812
#define ACRN_DBG_IOREQUEST 6U
913

hypervisor/common/ptdev.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,12 @@
44
* SPDX-License-Identifier: BSD-3-Clause
55
*/
66

7-
#include <hypervisor.h>
7+
#include <vm.h>
88
#include <softirq.h>
99
#include <ptdev.h>
10+
#include <irq.h>
11+
#include <atomic.h>
12+
#include <logmsg.h>
1013

1114
#define PTIRQ_BITMAP_ARRAY_SIZE INT_DIV_ROUNDUP(CONFIG_MAX_PT_IRQ_ENTRIES, 64U)
1215
struct ptirq_remapping_info ptirq_entries[CONFIG_MAX_PT_IRQ_ENTRIES];

hypervisor/common/schedule.c

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,14 @@
44
* SPDX-License-Identifier: BSD-3-Clause
55
*/
66

7-
#include <hypervisor.h>
7+
#include <rtl.h>
8+
#include <list.h>
9+
#include <bits.h>
10+
#include <cpu.h>
11+
#include <per_cpu.h>
12+
#include <lapic.h>
813
#include <schedule.h>
14+
#include <sprintf.h>
915

1016
static uint64_t pcpu_used_bitmap;
1117

hypervisor/common/softirq.c

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,12 @@
44
* SPDX-License-Identifier: BSD-3-Clause
55
*/
66

7-
#include <hypervisor.h>
7+
#include <types.h>
8+
#include <bits.h>
9+
#include <cpu.h>
10+
#include <per_cpu.h>
811
#include <softirq.h>
912

10-
1113
static softirq_handler softirq_handlers[NR_SOFTIRQS];
1214

1315
void init_softirq(void)

hypervisor/common/stack_protector.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
*
44
* SPDX-License-Identifier: BSD-3-Clause
55
*/
6-
7-
#include <hypervisor.h>
6+
#include <types.h>
7+
#include <logmsg.h>
88

99
void __stack_chk_fail(void)
1010
{

hypervisor/common/trusty_hypercall.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,10 @@
44
* SPDX-License-Identifier: BSD-3-Clause
55
*/
66

7-
#include <hypervisor.h>
7+
#include <vm.h>
8+
#include <errno.h>
89
#include <hypercall.h>
10+
#include <logmsg.h>
911

1012
#define ACRN_DBG_TRUSTY_HYCALL 6U
1113

hypervisor/common/vm_load.c

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,15 @@
44
* SPDX-License-Identifier: BSD-3-Clause
55
*/
66

7-
#include <hypervisor.h>
7+
#include <vm.h>
88
#include <e820.h>
99
#include <zeropage.h>
1010
#include <boot_context.h>
11+
#include <ept.h>
12+
#include <mmu.h>
13+
#include <errno.h>
14+
#include <sprintf.h>
15+
#include <logmsg.h>
1116

1217
static void prepare_bsp_gdt(struct acrn_vm *vm)
1318
{

0 commit comments

Comments
 (0)