[PATCH 0/3] WOL: Add Wake On LAN support

Holger Macht hmacht at suse.de
Thu Aug 30 02:49:24 PDT 2007


On Tue 28. Aug - 21:47:12, Bastien Nocera wrote:
> On Tue, 2007-08-28 at 14:12 -0400, David Zeuthen wrote:
> > On Tue, 2007-08-14 at 16:54 +0200, Holger Macht wrote:
> > > Adding the GetSupported(void) method to the coldplug detection of HAL
> > > might make sense, though. I already have code, partly copied from ethtool,
> > > to detect this from inside C code. It just makes it more complicated IMO
> > > even though I'm an advocator of binary versus script code. However, I'll
> > > check this again.
> > 
> > Actually I think it's nicer to just have a GetSupported() method instead
> > of a property. At least badly written drivers won't crap out until it's
> > called which is preferable to having the system lock up at boot time.
> > Which is what happened back when hal was trying to detect whether a
> > cable was plugged in.
> 
> Do we actually want to care about drivers like that? They'll get fixed,
> and people will downgrade their HAL in the meanwhile. Given that the
> property never changes, it doesn't make much sense to check with
> GetSupported() all the time. HAL checks once, all the apps know it can
> handle it...

Actually after having done the work already, I also think a property is
more clean ;-) I also don't think the code would be too risky to break
drivers. Drivers which don't have ethtool support are unlikely to break,
drivers which do should be fixed in any case to make use of its
functionality.

Regards,
	Holger


More information about the hal mailing list