On Monday 09 May 2005 11:06 am, Alan Stern wrote: > There's an issue here that needs to be discussed explicitly. How finely > should the kernel allow userspace to control runtime power management? > > ... > (B) Or should the kernel export a relatively small set of power > domains and a small set of primitives for each domain? Like: > suspend, turn off remote wakeup, go to full power, suspend > after N seconds of inactivity? > > ... > > In general (A) most resembles what sysfs does right now. I suspect that > (B) will be a better solution in the end. Yes. > Regarding Dave's comments about hdparm and xset dpms -- what matters most > about these interfaces is not that they are application-specific but that > they are ad-hoc. How does "application-specific" differ from "ad-hoc" though? In practical terms; one is more pejorative than the other, but how exactly does one measure a difference? For example, the kernel doesn't know about X11 protocol at all, or those particular IDE protocol requests. And most folk would probably say that it shouldn't need to ... > I don't see why we can't strive to present a much more > uniform interface, even if it does describe widely varying subsystems. I > also don't see anything wrong with implementing this interface by means of > sysfs instead of using driver-specific ioctls. For new things, or things being generalized into kernel support, I've no fundamental issue with using sysfs. But for things that are widely deployed today, I don't see much point in changing interfaces. - Dave