b82e2e94e2
Rename vmx_assym.s to vmx_assym.h to reflect that file's actual use and update vmx_support.S's include to match. Add vmx_assym.h to the SRCS to that it gets properly added to the dependency list. Add vmx_support.S to SRCS as well, so it gets built and needs fewer special-case goo. Remove now-redundant special-case goo. Finally, vmx_genassym.o doesn't need to depend on a hand expanded ${_ILINKS} explicitly, that's all taken care of by beforedepend. With these items fixed, we no longer build vmm.ko every single time through the modules on a KERNFAST build. Sponsored by: Netflix
65 lines
1.2 KiB
Makefile
65 lines
1.2 KiB
Makefile
# $FreeBSD$
|
|
|
|
KMOD= vmm
|
|
|
|
SRCS= opt_acpi.h opt_ddb.h device_if.h bus_if.h pci_if.h vmx_assym.h
|
|
|
|
CFLAGS+= -DVMM_KEEP_STATS -DSMP
|
|
CFLAGS+= -I${.CURDIR}/../../amd64/vmm
|
|
CFLAGS+= -I${.CURDIR}/../../amd64/vmm/io
|
|
CFLAGS+= -I${.CURDIR}/../../amd64/vmm/intel
|
|
|
|
# generic vmm support
|
|
.PATH: ${.CURDIR}/../../amd64/vmm
|
|
SRCS+= vmm.c \
|
|
vmm_dev.c \
|
|
vmm_host.c \
|
|
vmm_instruction_emul.c \
|
|
vmm_ioport.c \
|
|
vmm_ipi.c \
|
|
vmm_lapic.c \
|
|
vmm_mem.c \
|
|
vmm_stat.c \
|
|
vmm_util.c \
|
|
x86.c \
|
|
vmm_support.S
|
|
|
|
.PATH: ${.CURDIR}/../../amd64/vmm/io
|
|
SRCS+= iommu.c \
|
|
ppt.c \
|
|
vatpic.c \
|
|
vatpit.c \
|
|
vhpet.c \
|
|
vioapic.c \
|
|
vlapic.c
|
|
|
|
# intel-specific files
|
|
.PATH: ${.CURDIR}/../../amd64/vmm/intel
|
|
SRCS+= ept.c \
|
|
vmcs.c \
|
|
vmx_msr.c \
|
|
vmx_support.S \
|
|
vmx.c \
|
|
vtd.c
|
|
|
|
# amd-specific files
|
|
.PATH: ${.CURDIR}/../../amd64/vmm/amd
|
|
SRCS+= amdv.c
|
|
|
|
CLEANFILES= vmx_assym.h vmx_genassym.o
|
|
|
|
vmx_assym.h: vmx_genassym.o
|
|
.if exists(@)
|
|
vmx_assym.h: @/kern/genassym.sh
|
|
.endif
|
|
sh @/kern/genassym.sh vmx_genassym.o > ${.TARGET}
|
|
|
|
vmx_support.o:
|
|
${CC} -c -x assembler-with-cpp -DLOCORE ${CFLAGS} \
|
|
${.IMPSRC} -o ${.TARGET}
|
|
|
|
vmx_genassym.o:
|
|
${CC} -c ${CFLAGS:N-fno-common} ${.IMPSRC}
|
|
|
|
.include <bsd.kmod.mk>
|