[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] [PATCH 2/2] libacpi: Be specific about which DSDT files to build
There is no reason to build, for example, dsdt_pvh.asl for hvmloader. We pass which DSDTs to build via DSDT_FILES parameter. If DSDT_FILES is empty all DSDTs for a particular architecture will be built. Signed-off-by: Boris Ostrovsky <boris.ostrovsky@xxxxxxxxxx> --- tools/firmware/hvmloader/Makefile | 8 ++++---- tools/libacpi/Makefile | 7 +++++-- tools/libxl/Makefile | 15 ++++++++------- 3 files changed, 17 insertions(+), 13 deletions(-) diff --git a/tools/firmware/hvmloader/Makefile b/tools/firmware/hvmloader/Makefile index 002ff18..bb5b92f 100644 --- a/tools/firmware/hvmloader/Makefile +++ b/tools/firmware/hvmloader/Makefile @@ -69,14 +69,14 @@ all: acpi subdirs-all .PHONY: acpi acpi: - $(MAKE) -C $(ACPI_PATH) ACPI_BUILD_DIR=$(CURDIR) + $(MAKE) -C $(ACPI_PATH) ACPI_BUILD_DIR=$(CURDIR) DSDT_FILES="$(DSDT_FILES)" rombios.o: roms.inc smbios.o: CFLAGS += -D__SMBIOS_DATE__="\"$(SMBIOS_REL_DATE)\"" ACPI_PATH = ../../libacpi -ACPI_FILES = dsdt_anycpu.c dsdt_15cpu.c dsdt_anycpu_qemu_xen.c -ACPI_OBJS = $(patsubst %.c,%.o,$(ACPI_FILES)) build.o static_tables.o +DSDT_FILES = dsdt_anycpu.c dsdt_15cpu.c dsdt_anycpu_qemu_xen.c +ACPI_OBJS = $(patsubst %.c,%.o,$(DSDT_FILES)) build.o static_tables.o $(ACPI_OBJS): CFLAGS += -I. -DLIBACPI_STDUTILS=\"$(CURDIR)/util.h\" CFLAGS += -I$(ACPI_PATH) vpath build.c $(ACPI_PATH) @@ -119,7 +119,7 @@ endif clean: subdirs-clean rm -f roms.inc roms.inc.new acpi.h rm -f hvmloader hvmloader.tmp *.o $(DEPS) - $(MAKE) -C $(ACPI_PATH) ACPI_BUILD_DIR=$(CURDIR) clean + $(MAKE) -C $(ACPI_PATH) ACPI_BUILD_DIR=$(CURDIR) DSDT_FILES="$(DSDT_FILES)" clean .PHONY: distclean distclean: clean diff --git a/tools/libacpi/Makefile b/tools/libacpi/Makefile index 506d85e..7b3ec12 100644 --- a/tools/libacpi/Makefile +++ b/tools/libacpi/Makefile @@ -21,9 +21,12 @@ endif MK_DSDT = $(ACPI_BUILD_DIR)/mk_dsdt -C_SRC-$(CONFIG_X86) = dsdt_anycpu.c dsdt_15cpu.c dsdt_anycpu_qemu_xen.c +C_SRC-$(CONFIG_X86) = dsdt_anycpu.c dsdt_15cpu.c dsdt_anycpu_qemu_xen.c dsdt_pvh.c C_SRC-$(CONFIG_ARM_64) = dsdt_anycpu_arm.c -C_SRC = $(addprefix $(ACPI_BUILD_DIR)/, dsdt_pvh.c $(C_SRC-y)) +ifeq ($(DSDT_FILES),) +DSDT_FILES = $(C_SRC-y) +endif +C_SRC = $(addprefix $(ACPI_BUILD_DIR)/, $(DSDT_FILES)) H_SRC = $(addprefix $(ACPI_BUILD_DIR)/, ssdt_s3.h ssdt_s4.h ssdt_pm.h ssdt_tpm.h) # Suffix for temporary files. diff --git a/tools/libxl/Makefile b/tools/libxl/Makefile index af0a3ad..1133ed5 100644 --- a/tools/libxl/Makefile +++ b/tools/libxl/Makefile @@ -76,9 +76,9 @@ LIBXL_OBJS-y += libxl_no_colo.o endif ACPI_PATH = $(XEN_ROOT)/tools/libacpi -ACPI_FILES = dsdt_pvh.c -ACPI_OBJS = $(patsubst %.c,%.o,$(ACPI_FILES)) build.o static_tables.o -$(ACPI_FILES): acpi +DSDT_FILES-$(CONFIG_X86) = dsdt_pvh.c +ACPI_OBJS = $(patsubst %.c,%.o,$(DSDT_FILES-y)) build.o static_tables.o +$(DSDT_FILES-y): acpi $(ACPI_OBJS): CFLAGS += -I. -DLIBACPI_STDUTILS=\"$(CURDIR)/libxl_x86_acpi.h\" vpath build.c $(ACPI_PATH)/ vpath static_tables.c $(ACPI_PATH)/ @@ -86,14 +86,15 @@ LIBXL_OBJS-$(CONFIG_X86) += $(ACPI_OBJS) .PHONY: acpi acpi: - $(MAKE) -C $(ACPI_PATH) ACPI_BUILD_DIR=$(CURDIR) + $(MAKE) -C $(ACPI_PATH) ACPI_BUILD_DIR=$(CURDIR) DSDT_FILES="$(DSDT_FILES-y)" LIBXL_OBJS-$(CONFIG_X86) += libxl_cpuid.o libxl_x86.o libxl_psr.o libxl_x86_acpi.o LIBXL_OBJS-$(CONFIG_ARM) += libxl_nocpuid.o libxl_arm.o libxl_libfdt_compat.o ifeq ($(CONFIG_ARM_64),y) -LIBXL_OBJS-y += libxl_arm_acpi.o dsdt_anycpu_arm.o +DSDT_FILES-y = dsdt_anycpu_arm.c +LIBXL_OBJS-y += libxl_arm_acpi.o $(patsubst %.c,%.o,$(DSDT_FILES-y)) dsdt_anycpu_arm.c: - $(MAKE) -C $(ACPI_PATH) ACPI_BUILD_DIR=$(CURDIR) + $(MAKE) -C $(ACPI_PATH) ACPI_BUILD_DIR=$(CURDIR) DSDT_FILES="$(DSDT_FILES-y)" else LIBXL_OBJS-$(CONFIG_ARM) += libxl_arm_no_acpi.o endif @@ -330,7 +331,7 @@ clean: $(RM) -f testidl.c.new testidl.c *.api-ok $(RM) -f xenlight.pc $(RM) -f xlutil.pc - $(MAKE) -C $(ACPI_PATH) ACPI_BUILD_DIR=$(CURDIR) clean + $(MAKE) -C $(ACPI_PATH) ACPI_BUILD_DIR=$(CURDIR) DSDT_FILES="$(DSDT_FILES-y)" clean distclean: clean $(RM) -f xenlight.pc.in xlutil.pc.in -- 2.7.4 _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx https://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |