summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorMarco Peereboom <marco@cvs.openbsd.org>2011-04-07 20:14:39 +0000
committerMarco Peereboom <marco@cvs.openbsd.org>2011-04-07 20:14:39 +0000
commit751d6524b071cf54384b00c7a63ff504dc35a671 (patch)
treeb16246a70d4bb257ed497aab19a8ec89c0985d40 /sys
parent192094876e5e88d7975e7e64576338b355ab6c51 (diff)
Revert prior diff that I ok because I don't know how to read. Real fix
coming soon after this revert. ok jordan
Diffstat (limited to 'sys')
-rw-r--r--sys/dev/acpi/acpitz.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/sys/dev/acpi/acpitz.c b/sys/dev/acpi/acpitz.c
index c5d42b152e3..a459270d30c 100644
--- a/sys/dev/acpi/acpitz.c
+++ b/sys/dev/acpi/acpitz.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: acpitz.c,v 1.40 2011/04/07 19:36:21 miod Exp $ */
+/* $OpenBSD: acpitz.c,v 1.41 2011/04/07 20:14:38 marco Exp $ */
/*
* Copyright (c) 2006 Can Erkin Acar <canacar@openbsd.org>
* Copyright (c) 2005 Marco Peereboom <marco@openbsd.org>
@@ -242,7 +242,7 @@ acpitz_setfan(struct acpitz_softc *sc, int i, char *method)
struct aml_node *node;
struct aml_value res1, *ref;
char name[8];
- int rv = 1, y;
+ int rv = 1, x, y;
int64_t sta;
struct acpi_devlist *dl;
@@ -252,13 +252,13 @@ acpitz_setfan(struct acpitz_softc *sc, int i, char *method)
if (aml_evalname(sc->sc_acpi, dl->dev_node, "_PR0",0 , NULL,
&res1)) {
printf("%s: %s[%d] _PR0 failed\n", DEVNAME(sc),
- name, i);
+ name, x);
aml_freevalue(&res1);
continue;
}
if (res1.type != AML_OBJTYPE_PACKAGE) {
printf("%s: %s[%d] _PR0 not a package\n", DEVNAME(sc),
- name, i);
+ name, x);
aml_freevalue(&res1);
continue;
}
@@ -270,7 +270,7 @@ acpitz_setfan(struct acpitz_softc *sc, int i, char *method)
if (node == NULL) {
printf("%s: %s[%d.%d] _PRO"
" not a valid device\n",
- DEVNAME(sc), name, i, y);
+ DEVNAME(sc), name, x, y);
continue;
}
ref = node->value;
@@ -281,19 +281,19 @@ acpitz_setfan(struct acpitz_softc *sc, int i, char *method)
if (ref->type != AML_OBJTYPE_DEVICE &&
ref->type != AML_OBJTYPE_POWERRSRC) {
printf("%s: %s[%d.%d] _PRO not a package\n",
- DEVNAME(sc), name, i, y);
+ DEVNAME(sc), name, x, y);
continue;
}
if (aml_evalname(sc->sc_acpi, ref->node, method, 0,
NULL, NULL))
printf("%s: %s[%d.%d] %s fails\n",
- DEVNAME(sc), name, i, y, method);
+ DEVNAME(sc), name, x, y, method);
/* save off status of fan */
if (aml_evalinteger(sc->sc_acpi, ref->node, "_STA", 0,
NULL, &sta))
printf("%s: %s[%d.%d] _STA fails\n",
- DEVNAME(sc), name, i, y);
+ DEVNAME(sc), name, x, y);
else {
sc->sc_ac_stat[i] = sta;
}