summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sys/dev/acpi/acpiec.c6
-rw-r--r--sys/dev/acpi/acpireg.h15
2 files changed, 16 insertions, 5 deletions
diff --git a/sys/dev/acpi/acpiec.c b/sys/dev/acpi/acpiec.c
index e1003efcfa4..a7627b84e57 100644
--- a/sys/dev/acpi/acpiec.c
+++ b/sys/dev/acpi/acpiec.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: acpiec.c,v 1.52 2015/03/14 03:38:46 jsg Exp $ */
+/* $OpenBSD: acpiec.c,v 1.53 2016/05/07 18:03:36 kettenis Exp $ */
/*
* Copyright (c) 2006 Can Erkin Acar <canacar@openbsd.org>
*
@@ -75,8 +75,6 @@ void acpiec_unlock(struct acpiec_softc *);
#define EC_CMD_BD 0x83 /* Burst Disable */
#define EC_CMD_QR 0x84 /* Query */
-#define REG_TYPE_EC 3
-
int acpiec_reg(struct acpiec_softc *);
struct cfattach acpiec_ca = {
@@ -524,7 +522,7 @@ acpiec_reg(struct acpiec_softc *sc)
memset(&arg, 0, sizeof(arg));
arg[0].type = AML_OBJTYPE_INTEGER;
- arg[0].v_integer = REG_TYPE_EC;
+ arg[0].v_integer = ACPI_OPREG_EC;
arg[1].type = AML_OBJTYPE_INTEGER;
arg[1].v_integer = 1;
diff --git a/sys/dev/acpi/acpireg.h b/sys/dev/acpi/acpireg.h
index 14c87482cca..87576bb58e1 100644
--- a/sys/dev/acpi/acpireg.h
+++ b/sys/dev/acpi/acpireg.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: acpireg.h,v 1.34 2016/01/14 21:37:18 kettenis Exp $ */
+/* $OpenBSD: acpireg.h,v 1.35 2016/05/07 18:03:36 kettenis Exp $ */
/*
* Copyright (c) 2005 Thorsten Lockert <tholo@sigmasoft.com>
* Copyright (c) 2005 Marco Peereboom <marco@openbsd.org>
@@ -694,6 +694,19 @@ struct acpi_ivrs {
#define ACPI_PM2_CONTROL 0x06
#define ACPI_PM2_ARB_DIS 0x0001
+/*
+ * Operation Region Address Space Identifiers
+ */
+#define ACPI_OPREG_SYSMEM 0 /* SystemMemory */
+#define ACPI_OPREG_SYSIO 1 /* SystemIO */
+#define ACPI_OPREG_PCICFG 2 /* PCI_Config */
+#define ACPI_OPREG_EC 3 /* EmbeddedControl */
+#define ACPI_OPREG_SMBUS 4 /* SMBus */
+#define ACPI_OPREG_CMOS 5 /* CMOS */
+#define ACPI_OPREG_PCIBAR 6 /* PCIBARTarget */
+#define ACPI_OPREG_IPMI 7 /* IPMI */
+#define ACPI_OPREG_GPIO 8 /* GeneralPurposeIO */
+#define ACPI_OPREG_GSB 9 /* GenericSerialBus */
/*
* Sleeping States