Merge tag 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost
[cris-mirror.git] / arch / powerpc / kvm / Makefile
blob85ba80de713330e78fa48617ef26fc24658689f6
1 # SPDX-License-Identifier: GPL-2.0
3 # Makefile for Kernel-based Virtual Machine module
6 subdir-ccflags-$(CONFIG_PPC_WERROR) := -Werror
8 ccflags-y := -Ivirt/kvm -Iarch/powerpc/kvm
9 KVM := ../../../virt/kvm
11 common-objs-y = $(KVM)/kvm_main.o $(KVM)/eventfd.o
12 common-objs-$(CONFIG_KVM_VFIO) += $(KVM)/vfio.o
13 common-objs-$(CONFIG_KVM_MMIO) += $(KVM)/coalesced_mmio.o
15 CFLAGS_e500_mmu.o := -I.
16 CFLAGS_e500_mmu_host.o := -I.
17 CFLAGS_emulate.o := -I.
18 CFLAGS_emulate_loadstore.o := -I.
20 common-objs-y += powerpc.o emulate_loadstore.o
21 obj-$(CONFIG_KVM_EXIT_TIMING) += timing.o
22 obj-$(CONFIG_KVM_BOOK3S_HANDLER) += book3s_exports.o
24 AFLAGS_booke_interrupts.o := -I$(objtree)/$(obj)
26 kvm-e500-objs := \
27 $(common-objs-y) \
28 emulate.o \
29 booke.o \
30 booke_emulate.o \
31 booke_interrupts.o \
32 e500.o \
33 e500_mmu.o \
34 e500_mmu_host.o \
35 e500_emulate.o
36 kvm-objs-$(CONFIG_KVM_E500V2) := $(kvm-e500-objs)
38 kvm-e500mc-objs := \
39 $(common-objs-y) \
40 emulate.o \
41 booke.o \
42 booke_emulate.o \
43 bookehv_interrupts.o \
44 e500mc.o \
45 e500_mmu.o \
46 e500_mmu_host.o \
47 e500_emulate.o
48 kvm-objs-$(CONFIG_KVM_E500MC) := $(kvm-e500mc-objs)
50 kvm-book3s_64-builtin-objs-$(CONFIG_SPAPR_TCE_IOMMU) := \
51 book3s_64_vio_hv.o
53 kvm-pr-y := \
54 fpu.o \
55 emulate.o \
56 book3s_paired_singles.o \
57 book3s_pr.o \
58 book3s_pr_papr.o \
59 book3s_emulate.o \
60 book3s_interrupts.o \
61 book3s_mmu_hpte.o \
62 book3s_64_mmu_host.o \
63 book3s_64_mmu.o \
64 book3s_32_mmu.o
66 ifdef CONFIG_KVM_BOOK3S_PR_POSSIBLE
67 kvm-book3s_64-builtin-objs-$(CONFIG_KVM_BOOK3S_64_HANDLER) += \
68 book3s_rmhandlers.o
69 endif
71 kvm-hv-y += \
72 book3s_hv.o \
73 book3s_hv_interrupts.o \
74 book3s_64_mmu_hv.o \
75 book3s_64_mmu_radix.o
77 kvm-book3s_64-builtin-xics-objs-$(CONFIG_KVM_XICS) := \
78 book3s_hv_rm_xics.o book3s_hv_rm_xive.o
80 ifdef CONFIG_KVM_BOOK3S_HV_POSSIBLE
81 kvm-book3s_64-builtin-objs-$(CONFIG_KVM_BOOK3S_64_HANDLER) += \
82 book3s_hv_hmi.o \
83 book3s_hv_rmhandlers.o \
84 book3s_hv_rm_mmu.o \
85 book3s_hv_ras.o \
86 book3s_hv_builtin.o \
87 $(kvm-book3s_64-builtin-xics-objs-y)
88 endif
90 kvm-book3s_64-objs-$(CONFIG_KVM_XICS) += \
91 book3s_xics.o
93 kvm-book3s_64-objs-$(CONFIG_KVM_XIVE) += book3s_xive.o
94 kvm-book3s_64-objs-$(CONFIG_SPAPR_TCE_IOMMU) += book3s_64_vio.o
96 kvm-book3s_64-module-objs := \
97 $(common-objs-y) \
98 book3s.o \
99 book3s_rtas.o \
100 $(kvm-book3s_64-objs-y)
102 kvm-objs-$(CONFIG_KVM_BOOK3S_64) := $(kvm-book3s_64-module-objs)
104 kvm-book3s_32-objs := \
105 $(common-objs-y) \
106 emulate.o \
107 fpu.o \
108 book3s_paired_singles.o \
109 book3s.o \
110 book3s_pr.o \
111 book3s_emulate.o \
112 book3s_interrupts.o \
113 book3s_mmu_hpte.o \
114 book3s_32_mmu_host.o \
115 book3s_32_mmu.o
116 kvm-objs-$(CONFIG_KVM_BOOK3S_32) := $(kvm-book3s_32-objs)
118 kvm-objs-$(CONFIG_KVM_MPIC) += mpic.o
119 kvm-objs-$(CONFIG_HAVE_KVM_IRQ_ROUTING) += $(KVM)/irqchip.o
121 kvm-objs := $(kvm-objs-m) $(kvm-objs-y)
123 obj-$(CONFIG_KVM_E500V2) += kvm.o
124 obj-$(CONFIG_KVM_E500MC) += kvm.o
125 obj-$(CONFIG_KVM_BOOK3S_64) += kvm.o
126 obj-$(CONFIG_KVM_BOOK3S_32) += kvm.o
128 obj-$(CONFIG_KVM_BOOK3S_64_PR) += kvm-pr.o
129 obj-$(CONFIG_KVM_BOOK3S_64_HV) += kvm-hv.o
131 obj-y += $(kvm-book3s_64-builtin-objs-y)