Makefile 2.8 KB
Newer Older
1 2 3 4
#
# Makefile for Kernel-based Virtual Machine module
#

5 6
subdir-ccflags-$(CONFIG_PPC_WERROR) := -Werror

7
ccflags-y := -Ivirt/kvm -Iarch/powerpc/kvm
8
KVM := ../../../virt/kvm
9

10 11
common-objs-y = $(KVM)/kvm_main.o $(KVM)/coalesced_mmio.o \
		$(KVM)/eventfd.o
12

13
CFLAGS_44x_tlb.o  := -I.
14 15
CFLAGS_e500_mmu.o := -I.
CFLAGS_e500_mmu_host.o := -I.
16 17
CFLAGS_emulate.o  := -I.

18
common-objs-y += powerpc.o emulate.o
19
obj-$(CONFIG_KVM_EXIT_TIMING) += timing.o
20
obj-$(CONFIG_KVM_BOOK3S_HANDLER) += book3s_exports.o
21 22 23

AFLAGS_booke_interrupts.o := -I$(obj)

24
kvm-440-objs := \
25
	$(common-objs-y) \
26
	booke.o \
27
	booke_emulate.o \
28 29 30 31
	booke_interrupts.o \
	44x.o \
	44x_tlb.o \
	44x_emulate.o
32
kvm-objs-$(CONFIG_KVM_440) := $(kvm-440-objs)
33 34

kvm-e500-objs := \
35
	$(common-objs-y) \
36 37 38 39
	booke.o \
	booke_emulate.o \
	booke_interrupts.o \
	e500.o \
40 41
	e500_mmu.o \
	e500_mmu_host.o \
42
	e500_emulate.o
43
kvm-objs-$(CONFIG_KVM_E500V2) := $(kvm-e500-objs)
44

S
Scott Wood 已提交
45 46 47 48 49 50
kvm-e500mc-objs := \
	$(common-objs-y) \
	booke.o \
	booke_emulate.o \
	bookehv_interrupts.o \
	e500mc.o \
51 52
	e500_mmu.o \
	e500_mmu_host.o \
S
Scott Wood 已提交
53 54 55
	e500_emulate.o
kvm-objs-$(CONFIG_KVM_E500MC) := $(kvm-e500mc-objs)

56 57 58
kvm-book3s_64-builtin-objs-$(CONFIG_KVM_BOOK3S_64_HANDLER) := \
	book3s_64_vio_hv.o

59
kvm-book3s_64-objs-$(CONFIG_KVM_BOOK3S_64_PR) := \
60
	$(KVM)/coalesced_mmio.o \
61
	fpu.o \
62
	book3s_paired_singles.o \
63
	book3s_pr.o \
64
	book3s_pr_papr.o \
65 66
	book3s_emulate.o \
	book3s_interrupts.o \
67
	book3s_mmu_hpte.o \
68 69 70
	book3s_64_mmu_host.o \
	book3s_64_mmu.o \
	book3s_32_mmu.o
71 72

kvm-book3s_64-builtin-objs-$(CONFIG_KVM_BOOK3S_64_PR) += \
73
	book3s_rmhandlers.o
74 75 76 77 78

kvm-book3s_64-objs-$(CONFIG_KVM_BOOK3S_64_HV) := \
	book3s_hv.o \
	book3s_hv_interrupts.o \
	book3s_64_mmu_hv.o
79

80 81
kvm-book3s_64-builtin-xics-objs-$(CONFIG_KVM_XICS) := \
	book3s_hv_rm_xics.o
82 83

kvm-book3s_64-builtin-objs-$(CONFIG_KVM_BOOK3S_64_HV) += \
84
	book3s_hv_rmhandlers.o \
85
	book3s_hv_rm_mmu.o \
86
	book3s_hv_ras.o \
87
	book3s_hv_builtin.o \
88
	book3s_hv_cma.o \
89
	$(kvm-book3s_64-builtin-xics-objs-y)
90

91 92 93
kvm-book3s_64-objs-$(CONFIG_KVM_XICS) += \
	book3s_xics.o

94
kvm-book3s_64-module-objs := \
95 96
	$(KVM)/kvm_main.o \
	$(KVM)/eventfd.o \
97 98 99
	powerpc.o \
	emulate.o \
	book3s.o \
100
	book3s_64_vio.o \
101
	book3s_rtas.o \
102
	$(kvm-book3s_64-objs-y)
103 104

kvm-objs-$(CONFIG_KVM_BOOK3S_64) := $(kvm-book3s_64-module-objs)
105

106 107 108 109 110
kvm-book3s_32-objs := \
	$(common-objs-y) \
	fpu.o \
	book3s_paired_singles.o \
	book3s.o \
111
	book3s_pr.o \
112 113
	book3s_emulate.o \
	book3s_interrupts.o \
114
	book3s_mmu_hpte.o \
115 116 117 118
	book3s_32_mmu_host.o \
	book3s_32_mmu.o
kvm-objs-$(CONFIG_KVM_BOOK3S_32) := $(kvm-book3s_32-objs)

119
kvm-objs-$(CONFIG_KVM_MPIC) += mpic.o
120
kvm-objs-$(CONFIG_HAVE_KVM_IRQ_ROUTING) += $(KVM)/irqchip.o
121

122 123 124
kvm-objs := $(kvm-objs-m) $(kvm-objs-y)

obj-$(CONFIG_KVM_440) += kvm.o
125
obj-$(CONFIG_KVM_E500V2) += kvm.o
S
Scott Wood 已提交
126
obj-$(CONFIG_KVM_E500MC) += kvm.o
127
obj-$(CONFIG_KVM_BOOK3S_64) += kvm.o
128
obj-$(CONFIG_KVM_BOOK3S_32) += kvm.o
129

130
obj-y += $(kvm-book3s_64-builtin-objs-y)