Re: Possible problem with device_move()

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

 



On Tue, 31 Jul 2007, Cornelia Huck wrote:

> On Mon, 30 Jul 2007 13:34:35 -0400 (EDT),
> Alan Stern <stern@xxxxxxxxxxxxxxxxxxx> wrote:
> 
> > As long as you never hold the device semaphores of both the parent and 
> > the child there shouldn't be any problem.  Could this happen when a 
> > subchannel structure is deallocated?
> 
> This is indeed what happens, since we unregister the child ccw_device
> from the (io_)subchannel's remove function.
> 
> (We used to do unregistering of the ccw_device via a workqueue (in
> order to avoid livelocks on a no longer existing bus semaphore), but
> removed it since it seemed to be needlessly complicated code.)

It sounds like you might be in trouble with suspend anyway (if S390
implemented it).  As things stand now, the PM core would try to suspend
the subchannel before suspending the ccw_device, because the subchannel 
was registered later.

Marcel, you might be in a similar position.  The PM core could try to 
suspend a Bluetooth adapter before suspending its child TTY node.

I wonder if device_move() shouldn't change the order of entries in the 
dpm_active list so that the new parent (and all its ancestors) get 
moved up ahead of the device's position?  But that might cause other 
problems...

Alan Stern

_______________________________________________
linux-pm mailing list
linux-pm@xxxxxxxxxxxxxxxxxxxxxxxxxx
https://lists.linux-foundation.org/mailman/listinfo/linux-pm

[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