On Wed, Dec 30, 2009 at 03:48:01PM +0200, Jukka Ruohonen wrote:
> > +static int
> > +aibs_detach(device_t self, int flags)
> > +{
> > +   struct aibs_softc       *sc = device_private(self);
> > +
> > +   sysmon_envsys_unregister(sc->sc_sme);
> > +   if (sc->sc_asens_volt != NULL)
> > +           free(sc->sc_asens_volt, M_DEVBUF);
> > +   if (sc->sc_asens_temp != NULL)
> > +           free(sc->sc_asens_temp, M_DEVBUF);
> > +   if (sc->sc_asens_fan != NULL)
> > +           free(sc->sc_asens_fan, M_DEVBUF);
> > +   return 0;
> > +}
> 
> I wonder if the detach routine is needed at all?

Detach routines are important in the modular era. :-) Each detach
routine should be tested using drvctl -d.

Dave

-- 
David Young             OJC Technologies
[email protected]      Urbana, IL * (217) 278-3933

Reply via email to