diff options
author | 2009-11-24 21:37:42 +0000 | |
---|---|---|
committer | 2009-11-24 21:37:42 +0000 | |
commit | 104ea23e3eed7843a53566be9c3f6bab9904a20a (patch) | |
tree | f4d56232330ad855f7d931de8af39425e63b2a55 /sys | |
parent | Add event framework. (diff) | |
download | wireguard-openbsd-104ea23e3eed7843a53566be9c3f6bab9904a20a.tar.xz wireguard-openbsd-104ea23e3eed7843a53566be9c3f6bab9904a20a.zip |
Reporting battery insert/removal was debug code. dmesg is not
a place to spam informational messages about unimportant events.
That is what the sensor framework is for (and that is already
done)
ok kettenis
Diffstat (limited to 'sys')
-rw-r--r-- | sys/dev/acpi/acpibat.c | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/sys/dev/acpi/acpibat.c b/sys/dev/acpi/acpibat.c index f3f390f3d4e..ea6e1876b07 100644 --- a/sys/dev/acpi/acpibat.c +++ b/sys/dev/acpi/acpibat.c @@ -1,4 +1,4 @@ -/* $OpenBSD: acpibat.c,v 1.54 2009/03/11 21:54:15 jordan Exp $ */ +/* $OpenBSD: acpibat.c,v 1.55 2009/11/24 21:37:42 deraadt Exp $ */ /* * Copyright (c) 2005 Marco Peereboom <marco@openbsd.org> * @@ -406,16 +406,10 @@ acpibat_notify(struct aml_node *node, int notify_type, void *arg) /* Check if installed state of battery has changed */ if (aml_evalinteger(sc->sc_acpi, node, "_STA", 0, NULL, &sta) == 0) { present = sta & STA_BATTERY; - if (!sc->sc_bat_present && present) { - printf("%s: %s inserted\n", DEVNAME(sc), - sc->sc_devnode->name); + if (!sc->sc_bat_present && present) sc->sc_bat_present = 1; - } - else if (sc->sc_bat_present && !present) { - printf("%s: %s removed\n", DEVNAME(sc), - sc->sc_devnode->name); + else if (sc->sc_bat_present && !present) sc->sc_bat_present = 0; - } } switch (notify_type) { case 0x80: /* _BST changed */ |