summaryrefslogtreecommitdiffstats
path: root/sys/modules/acpi
diff options
context:
space:
mode:
authorjkim <jkim@FreeBSD.org>2010-03-08 19:40:31 +0000
committerjkim <jkim@FreeBSD.org>2010-03-08 19:40:31 +0000
commit2adbaaffe49e189520bb04b4737cc5658451b610 (patch)
treea3627a4703c460988aa3d70445ba7b77d4ae86da /sys/modules/acpi
parentb17e796fd715160e83fee9fab75e3a838213fdef (diff)
downloadFreeBSD-src-2adbaaffe49e189520bb04b4737cc5658451b610.zip
FreeBSD-src-2adbaaffe49e189520bb04b4737cc5658451b610.tar.gz
Enable ACPI module build on amd64. Although we strongly recommend building
it into kernel, there is no need to prevent it from building at all.
Diffstat (limited to 'sys/modules/acpi')
-rw-r--r--sys/modules/acpi/acpi/Makefile14
1 files changed, 9 insertions, 5 deletions
diff --git a/sys/modules/acpi/acpi/Makefile b/sys/modules/acpi/acpi/Makefile
index 91d0ced..6fa36ff 100644
--- a/sys/modules/acpi/acpi/Makefile
+++ b/sys/modules/acpi/acpi/Makefile
@@ -1,11 +1,11 @@
# $FreeBSD$
-.if ${MACHINE_ARCH} == "amd64" || ${MACHINE_ARCH} == "ia64"
-.error "ACPI can only be compiled into the kernel on the amd64 and ia64 platforms"
+.if ${MACHINE_ARCH} == "ia64"
+.error "ACPI can only be compiled into the kernel on the ia64 platform"
.endif
-.if ${MACHINE} != "i386"
-.error "The ACPI module is only for i386"
+.if ${MACHINE} != "amd64" && ${MACHINE} != "i386"
+.error "The ACPI module is only for amd64 and i386"
.endif
.PATH: ${.CURDIR}/../../../contrib/dev/acpica/debugger \
@@ -97,9 +97,13 @@ opt_ddb.h: Makefile
SRCS+= acpi_machdep.c acpi_wakecode.h acpi_wakeup.c
SRCS+= assym.s madt.c
CLEANFILES+= acpi_wakecode.bin acpi_wakecode.h acpi_wakecode.o
+
.if ${MACHINE_ARCH} == "amd64"
-SRCS+= opt_global.h
+SRCS+= acpi_switch.S opt_global.h
CLEANFILES+= acpi_wakedata.h
+ASM_CFLAGS= -x assembler-with-cpp -DLOCORE ${CFLAGS}
+acpi_switch.o: acpi_switch.S
+ ${CC} -c ${ASM_CFLAGS} ${WERROR} ${.IMPSRC}
.endif
acpi_wakecode.h: acpi_wakecode.S assym.s
OpenPOWER on IntegriCloud