From 05ad4782bfe89cf76f11bf22bc566dc37469d143 Mon Sep 17 00:00:00 2001 From: "Constantine A. Murenin" Date: Sat, 24 Jan 2009 22:30:19 +0000 Subject: use more appropriate sensor_task_register(9) paradigm; ok mk --- sys/dev/isa/sch311x.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/sys/dev/isa/sch311x.c b/sys/dev/isa/sch311x.c index f769afea708..961015a9cc3 100644 --- a/sys/dev/isa/sch311x.c +++ b/sys/dev/isa/sch311x.c @@ -1,4 +1,4 @@ -/* $OpenBSD: sch311x.c,v 1.2 2009/01/24 22:04:50 cnst Exp $ */ +/* $OpenBSD: sch311x.c,v 1.3 2009/01/24 22:30:18 cnst Exp $ */ /* * Copyright (c) 2008 Mark Kettenis * Copyright (c) 2009 Michael Knudsen @@ -343,9 +343,12 @@ schsio_hwm_init(struct schsio_softc *sc) for (i = 0; i < SCHSIO_SENSORS; i++) sensor_attach(&sc->sc_sensordev, &sc->sc_sensor[i]); + if (sensor_task_register(sc, schsio_hwm_update, + SCHSIO_HWM_INTERVAL) == NULL) { + printf(": unable to register the update task"); + return; + } sensordev_install(&sc->sc_sensordev); - - sensor_task_register(sc, schsio_hwm_update, SCHSIO_HWM_INTERVAL); } void -- cgit v1.2.3