summaryrefslogtreecommitdiff
path: root/sys/dev/usb/umbg.c
diff options
context:
space:
mode:
authorConstantine A. Murenin <cnst@cvs.openbsd.org>2009-04-26 02:20:59 +0000
committerConstantine A. Murenin <cnst@cvs.openbsd.org>2009-04-26 02:20:59 +0000
commitd344f77a9af3c3c22eb56bc584b6c9aaf65c605c (patch)
tree84ab585bb039ea99486cbd37458c0cb00de6cd95 /sys/dev/usb/umbg.c
parent38575b1fbbb6e32a06e3a20a41031ba6500b0e61 (diff)
in ca_attach() there is no need to set .value and .flags of sensors to 0,
since autoconf(9) allocates softc with M_ZERO; ok deraadt
Diffstat (limited to 'sys/dev/usb/umbg.c')
-rw-r--r--sys/dev/usb/umbg.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/sys/dev/usb/umbg.c b/sys/dev/usb/umbg.c
index 877eac73075..b204edb4e50 100644
--- a/sys/dev/usb/umbg.c
+++ b/sys/dev/usb/umbg.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: umbg.c,v 1.8 2008/11/21 11:38:12 mbalmer Exp $ */
+/* $OpenBSD: umbg.c,v 1.9 2009/04/26 02:20:58 cnst Exp $ */
/*
* Copyright (c) 2007 Marc Balmer <mbalmer@openbsd.org>
@@ -191,15 +191,11 @@ umbg_attach(struct device *parent, struct device *self, void *aux)
sc->sc_timedelta.type = SENSOR_TIMEDELTA;
sc->sc_timedelta.status = SENSOR_S_UNKNOWN;
- sc->sc_timedelta.value = 0LL;
- sc->sc_timedelta.flags = 0;
strlcpy(sc->sc_timedelta.desc, "USB5131",
sizeof(sc->sc_timedelta.desc));
sensor_attach(&sc->sc_sensordev, &sc->sc_timedelta);
sc->sc_signal.type = SENSOR_PERCENT;
- sc->sc_signal.value = 0LL;
- sc->sc_signal.flags = 0;
strlcpy(sc->sc_signal.desc, "Signal", sizeof(sc->sc_signal.desc));
sensor_attach(&sc->sc_sensordev, &sc->sc_signal);
sensordev_install(&sc->sc_sensordev);