1 # SPDX-License-Identifier: GPL-2.0
3 # Makefile for Kernel-based Virtual Machine module
6 ccflags-y
:= -Ivirt
/kvm
-Iarch
/powerpc
/kvm
7 KVM
:= ..
/..
/..
/virt
/kvm
9 common-objs-y
= $(KVM
)/kvm_main.o
$(KVM
)/eventfd.o
10 common-objs-
$(CONFIG_KVM_VFIO
) += $(KVM
)/vfio.o
11 common-objs-
$(CONFIG_KVM_MMIO
) += $(KVM
)/coalesced_mmio.o
13 common-objs-y
+= powerpc.o emulate_loadstore.o
14 obj-
$(CONFIG_KVM_EXIT_TIMING
) += timing.o
15 obj-
$(CONFIG_KVM_BOOK3S_HANDLER
) += book3s_exports.o
17 AFLAGS_booke_interrupts.o
:= -I
$(objtree
)/$(obj
)
29 kvm-objs-
$(CONFIG_KVM_E500V2
) := $(kvm-e500-objs
)
36 bookehv_interrupts.o \
41 kvm-objs-
$(CONFIG_KVM_E500MC
) := $(kvm-e500mc-objs
)
43 kvm-book3s_64-builtin-objs-
$(CONFIG_SPAPR_TCE_IOMMU
) := \
49 book3s_paired_singles.o \
55 book3s_64_mmu_host.o \
59 kvm-book3s_64-builtin-objs-
$(CONFIG_KVM_BOOK3S_64_HANDLER
) += \
62 ifdef CONFIG_KVM_BOOK3S_PR_POSSIBLE
63 kvm-book3s_64-builtin-objs-
$(CONFIG_KVM_BOOK3S_64_HANDLER
) += \
69 book3s_hv_interrupts.o \
71 book3s_64_mmu_radix.o \
74 kvm-hv-
$(CONFIG_PPC_UV
) += \
77 kvm-hv-
$(CONFIG_PPC_TRANSACTIONAL_MEM
) += \
80 kvm-book3s_64-builtin-xics-objs-
$(CONFIG_KVM_XICS
) := \
81 book3s_hv_rm_xics.o book3s_hv_rm_xive.o
83 kvm-book3s_64-builtin-tm-objs-
$(CONFIG_PPC_TRANSACTIONAL_MEM
) += \
84 book3s_hv_tm_builtin.o
86 ifdef CONFIG_KVM_BOOK3S_HV_POSSIBLE
87 kvm-book3s_64-builtin-objs-
$(CONFIG_KVM_BOOK3S_64_HANDLER
) += \
89 book3s_hv_rmhandlers.o \
93 $(kvm-book3s_64-builtin-tm-objs-y
) \
94 $(kvm-book3s_64-builtin-xics-objs-y
)
97 kvm-book3s_64-objs-
$(CONFIG_KVM_XICS
) += \
100 kvm-book3s_64-objs-
$(CONFIG_KVM_XIVE
) += book3s_xive.o book3s_xive_native.o
101 kvm-book3s_64-objs-
$(CONFIG_SPAPR_TCE_IOMMU
) += book3s_64_vio.o
103 kvm-book3s_64-module-objs
:= \
107 $(kvm-book3s_64-objs-y
)
109 kvm-objs-
$(CONFIG_KVM_BOOK3S_64
) := $(kvm-book3s_64-module-objs
)
111 kvm-book3s_32-objs
:= \
115 book3s_paired_singles.o \
119 book3s_interrupts.o \
121 book3s_32_mmu_host.o \
123 kvm-objs-
$(CONFIG_KVM_BOOK3S_32
) := $(kvm-book3s_32-objs
)
125 kvm-objs-
$(CONFIG_KVM_MPIC
) += mpic.o
126 kvm-objs-
$(CONFIG_HAVE_KVM_IRQ_ROUTING
) += $(KVM
)/irqchip.o
128 kvm-objs
:= $(kvm-objs-m
) $(kvm-objs-y
)
130 obj-
$(CONFIG_KVM_E500V2
) += kvm.o
131 obj-
$(CONFIG_KVM_E500MC
) += kvm.o
132 obj-
$(CONFIG_KVM_BOOK3S_64
) += kvm.o
133 obj-
$(CONFIG_KVM_BOOK3S_32
) += kvm.o
135 obj-
$(CONFIG_KVM_BOOK3S_64_PR
) += kvm-pr.o
136 obj-
$(CONFIG_KVM_BOOK3S_64_HV
) += kvm-hv.o
138 obj-y
+= $(kvm-book3s_64-builtin-objs-y
)