summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Larkin <mlarkin@cvs.openbsd.org>2016-05-18 04:33:02 +0000
committerMike Larkin <mlarkin@cvs.openbsd.org>2016-05-18 04:33:02 +0000
commiteb2998f2e9f87154137f19a4ee39b6feaf8e450a (patch)
tree7a48631efd41b6780bc97466f91498507a25d63d
parent3d7d642ad93681b0342653eaeed0d6dccd2e6852 (diff)
add a check for the acpi trampoline data page to match the code check
already there.
-rw-r--r--sys/arch/amd64/amd64/acpi_machdep.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/arch/amd64/amd64/acpi_machdep.c b/sys/arch/amd64/amd64/acpi_machdep.c
index f6885b292a7..68e967b190f 100644
--- a/sys/arch/amd64/amd64/acpi_machdep.c
+++ b/sys/arch/amd64/amd64/acpi_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: acpi_machdep.c,v 1.73 2016/05/16 01:19:27 mlarkin Exp $ */
+/* $OpenBSD: acpi_machdep.c,v 1.74 2016/05/18 04:33:01 mlarkin Exp $ */
/*
* Copyright (c) 2005 Thorsten Lockert <tholo@sigmasoft.com>
*
@@ -287,9 +287,10 @@ acpi_attach_machdep(struct acpi_softc *sc)
#ifndef SMALL_KERNEL
/*
* Sanity check before setting up trampoline.
- * Ensure the trampoline size is < PAGE_SIZE
+ * Ensure the trampoline page sizes are < PAGE_SIZE
*/
KASSERT(acpi_resume_end - acpi_real_mode_resume < PAGE_SIZE);
+ KASSERT(acpi_tramp_data_end - acpi_tramp_data_start < PAGE_SIZE);
/* Map ACPI tramp code and data pages RW for copy */
pmap_kenter_pa(ACPI_TRAMPOLINE, ACPI_TRAMPOLINE,