On Friday 06 April 2007 11:21 am, Alan Stern wrote: > On Fri, 6 Apr 2007, David Brownell wrote: > > > Again, power_state clearly being on the way out, we have alternate > > solutions for what it previously seemed to solve. > > Yes. However there is still one aspect for which we haven't fashioned a > replacement -- the host controller devices themselves. Both the HCDs and > usbcore are concerned with their power states in various places, and > right now they all rely on checking dev.power.power_state. Perhaps we > should add a field to struct usb_hcd for this purpose. > > Assuming we do, do you think that field would need to indicate anything > other than "powered on" vs. "powered off"?
Assuming the downstream ports are inactive (suspended or disconnected) the controller itself probably has at least three states: - on, fully functional - off, needs complete restart - low-power, some clocks off (and no DMA) but retains power sessions * wakeup capable (fully functional) * no wakeups possible, but won't trash the sessions The generic USB stack (usbcore) should be capable of getting the HCD to the point where the downstream ports are inactive, at which point the transition between "on" and "lowpower, wakeup capable" will be either internal to the HCD or else a side effect of a suspend() from system PM infrastructure. > That is, would the non-PCI > drivers want to store different, more structured values? Or would they go > somewhere else, in the driver's private data? My first inclination is that usbcore should only care about the state of the downstream links. That will help to make sure that the details associated with any given platform's bus glue (PCI etc) don't start to infect usbcore ... the details are very system-specific. Luckily we have two distinct device nodes to encapsulate such issues. The root hub has its own node, distinct from the controller... - Dave ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ [EMAIL PROTECTED] To unsubscribe, use the last form field at: https://lists.sourceforge.net/lists/listinfo/linux-usb-devel