forked from Minki/linux
535cf7b3b1
As requested by the KVM maintainers, remove the addprefix used to refer to the main KVM code from the arch code, and replace it with a KVM variable that does the same thing. Tested-by: Christian Borntraeger <borntraeger@de.ibm.com> Cc: Paolo Bonzini <pbonzini@redhat.com> Cc: Gleb Natapov <gleb@redhat.com> Cc: Christoffer Dall <cdall@cs.columbia.edu> Acked-by: Xiantao Zhang <xiantao.zhang@intel.com> Cc: Tony Luck <tony.luck@intel.com> Cc: Fenghua Yu <fenghua.yu@intel.com> Cc: Alexander Graf <agraf@suse.de> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Christian Borntraeger <borntraeger@de.ibm.com> Cc: Cornelia Huck <cornelia.huck@de.ibm.com> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Gleb Natapov <gleb@redhat.com>
68 lines
1.8 KiB
Makefile
68 lines
1.8 KiB
Makefile
#This Make file is to generate asm-offsets.h and build source.
|
|
#
|
|
|
|
#Generate asm-offsets.h for vmm module build
|
|
offsets-file := asm-offsets.h
|
|
|
|
always := $(offsets-file)
|
|
targets := $(offsets-file)
|
|
targets += arch/ia64/kvm/asm-offsets.s
|
|
|
|
# Default sed regexp - multiline due to syntax constraints
|
|
define sed-y
|
|
"/^->/{s:^->\([^ ]*\) [\$$#]*\([^ ]*\) \(.*\):#define \1 \2 /* \3 */:; s:->::; p;}"
|
|
endef
|
|
|
|
quiet_cmd_offsets = GEN $@
|
|
define cmd_offsets
|
|
(set -e; \
|
|
echo "#ifndef __ASM_KVM_OFFSETS_H__"; \
|
|
echo "#define __ASM_KVM_OFFSETS_H__"; \
|
|
echo "/*"; \
|
|
echo " * DO NOT MODIFY."; \
|
|
echo " *"; \
|
|
echo " * This file was generated by Makefile"; \
|
|
echo " *"; \
|
|
echo " */"; \
|
|
echo ""; \
|
|
sed -ne $(sed-y) $<; \
|
|
echo ""; \
|
|
echo "#endif" ) > $@
|
|
endef
|
|
|
|
# We use internal rules to avoid the "is up to date" message from make
|
|
arch/ia64/kvm/asm-offsets.s: arch/ia64/kvm/asm-offsets.c \
|
|
$(wildcard $(srctree)/arch/ia64/include/asm/*.h)\
|
|
$(wildcard $(srctree)/include/linux/*.h)
|
|
$(call if_changed_dep,cc_s_c)
|
|
|
|
$(obj)/$(offsets-file): arch/ia64/kvm/asm-offsets.s
|
|
$(call cmd,offsets)
|
|
|
|
FORCE : $(obj)/$(offsets-file)
|
|
|
|
#
|
|
# Makefile for Kernel-based Virtual Machine module
|
|
#
|
|
|
|
ccflags-y := -Ivirt/kvm -Iarch/ia64/kvm/
|
|
asflags-y := -Ivirt/kvm -Iarch/ia64/kvm/
|
|
KVM := ../../../virt/kvm
|
|
|
|
common-objs = $(KVM)/kvm_main.o $(KVM)/ioapic.o \
|
|
$(KVM)/coalesced_mmio.o $(KVM)/irq_comm.o
|
|
|
|
ifeq ($(CONFIG_KVM_DEVICE_ASSIGNMENT),y)
|
|
common-objs += $(KVM)/assigned-dev.o $(KVM)/iommu.o
|
|
endif
|
|
|
|
kvm-objs := $(common-objs) kvm-ia64.o kvm_fw.o
|
|
obj-$(CONFIG_KVM) += kvm.o
|
|
|
|
CFLAGS_vcpu.o += -mfixed-range=f2-f5,f12-f127
|
|
kvm-intel-objs = vmm.o vmm_ivt.o trampoline.o vcpu.o optvfault.o mmio.o \
|
|
vtlb.o process.o kvm_lib.o
|
|
#Add link memcpy and memset to avoid possible structure assignment error
|
|
kvm-intel-objs += memcpy.o memset.o
|
|
obj-$(CONFIG_KVM_INTEL) += kvm-intel.o
|