On Tue, 18 Apr 2006 [EMAIL PROTECTED] wrote:

> Now the problem is PCMCIA powers of the card when it gets the suspend
> event. So consider the following case:
> 
>       Let the device,port,roothub interface and the Host controller,
> which are the nodes of the device tree are not suspened.Now a user
> suspends the PCMCIA card. So PCMCIA gets the suspend event and powers of
> the card. We have a check in PCMCIA suspend event that whether the Host
> controller is suspended or not. So considering the above case we find
> that Host controller is not suspended. Now according to LINUX USB
> framework, parent node should not be supended if all the child devices
> are not suspended. So we thought up three solutions for this.
> 
> First is, fail the suspend event which we cant do because PCMCIA powes
> off the card.

You can do it.  And you should.

> Second is, mark Host Controller as suspended. But I hope this is against
> the LINUX USB framework because we should not suspend the host
> controller when the bus,port and the device connected to the port are
> still active.So you suspend the device connected to the port first, then
> the port ,then the roothub interface and then the Host controller.

No, don't do this.  If those devices aren't already suspended then the
PCMCIA socket shouldn't get suspended.

> Third is, as the card is physically powered off, we shutdown the
> controller. So we thought up doing this.

I don't see how.  You can't do anything to the controller (shut it down, 
suspend it, anything) if it doesn't have power.

>       As you have replied, PCMCIA should not make assumption about its
> client. So doing second and third solution are not feasible as we will
> be handling/changing HCD stuff from PCMCIA layer. So only thing can be
> done is, when PCMCIA gets the suspend event ,it should check whether the
> Host Controller is suspended or not. Acoording to the check result,
> PCMCIA should handle the suspend event. i.e. it should power off the
> card if the Controller is suspended. Otherwise fail the suspend event by
> not powering off the card. But PCMCIA behavior is, power off the card
> irrespective anything. Then what should be the solution ?

The solution is simple and obvious: Fix the PCMCIA layer.

Alan Stern



-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
_______________________________________________
linux-usb-devel@lists.sourceforge.net
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to