summaryrefslogtreecommitdiff
path: root/sys/dev/acpi
diff options
context:
space:
mode:
authorJoshua Stein <jcs@cvs.openbsd.org>2017-09-04 13:47:57 +0000
committerJoshua Stein <jcs@cvs.openbsd.org>2017-09-04 13:47:57 +0000
commiteb4d90b46aec37e18cc72aad20f6ad04e087147b (patch)
treef678a3c4f27e9bbb85a2e77c0847e9fcd3e31972 /sys/dev/acpi
parentaf6a300e99f56f9cc01b617ec985a18182e0ae4a (diff)
Don't require exactly 20 elements in the _BIX package if at least 20
are returned since extras may be OEM-specific values we end up ignoring anyway, such as on the Lenovo X1C 5th Gen which returns 21 elements. ok mpi
Diffstat (limited to 'sys/dev/acpi')
-rw-r--r--sys/dev/acpi/acpibat.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/dev/acpi/acpibat.c b/sys/dev/acpi/acpibat.c
index 94a65926d22..82f6fc61d9c 100644
--- a/sys/dev/acpi/acpibat.c
+++ b/sys/dev/acpi/acpibat.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: acpibat.c,v 1.65 2017/07/25 21:32:07 jcs Exp $ */
+/* $OpenBSD: acpibat.c,v 1.66 2017/09/04 13:47:56 jcs Exp $ */
/*
* Copyright (c) 2005 Marco Peereboom <marco@openbsd.org>
*
@@ -332,10 +332,10 @@ acpibat_getbix(struct acpibat_softc *sc)
if (aml_evalname(sc->sc_acpi, sc->sc_devnode, "_BIX", 0, NULL,
&res) == 0) {
- if (res.length == 20)
+ if (res.length >= 20)
sc->sc_use_bif = 0;
else
- dnprintf(10, "%s: invalid _BIX (%d != 20)\n",
+ dnprintf(10, "%s: invalid _BIX (%d < 20)\n",
DEVNAME(sc), res.length);
}