[linux-pm] Some thoughts on suspend/resume development

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, 2005-03-11 at 11:42 -0500, Alan Stern wrote:
> On Fri, 11 Mar 2005, Pavel Machek wrote:
> 
> > > This is why I'm in favor of power domains (power parents and children
> > > that can be independent of physical device relations).  Power domains
> > > are common for internal devices, not just external devices.  Still, if
> > > you disable a physical parent, then the device is no longer operational.
> > > Disable the usb host controller, and the external disk drive cannot be
> > > used (in fact data may be lost).  So it's necessary to stop every child
> > > device first, and generally also power it off if we can control the
> > > power source.
> > 
> > I just don't see it like that.
> > 
> > Remember old scsi disks where formatting took half an hour? You may do
> > something like
> > 
> > invoke scsi format operation
> > power down usb controller
> > <half an hour later>
> > power up usb controller
> > get the results
> > 
> > Now, that was probably bad example, but I do think some devices might
> > do usefull work even with their parents disabled.

Yes, but at a logical (class) level the parent device would never be
disabled, right?  I guess it would be possible to model such a situation
if we take advantage of the driver class design.  I hadn't considered it
before, but I'll try to keep it in mind.  It would be interesting to see
how common it might be.

> 
> There's another aspect to it as well.  You can suspend the USB host
> controller and then _still_ use the external disk, if the host controller
> is automatically resumed when the next disk I/O request arrives.  Whereas
> if you would stop the disk and its driver, the next I/O request might
> simply languish in a plugged queue.  I suppose this would depend on
> whether the disk driver was smart enough to leave its queue unplugged
> under the right circumstances, so perhaps this isn't a great example.  
> (And you're right about the possibility of data being lost -- although
> it's pretty unlikely -- which makes this an even worse example.)
> 
> Alan Stern

Yes, so I think if we ensure that the parent device is enabled at a
logical level, and that the power source is active, it would be possible
to do such a thing.  I'm guessing this is something not to worry about
too much now; do you think so?

Thanks,
Adam



[Index of Archives]     [Linux ACPI]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [CPU Freq]     [Kernel Newbies]     [Fedora Kernel]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux