David:

Your patch leaves usb_hc_died() looking like this:

void usb_hc_died (struct usb_hcd *hcd)
{
        dev_err (hcd->self.controller, "HC died; cleaning up\n");

        /* make khubd clean up old urbs and devices */
        usb_set_device_state(hcd->self.root_hub, USB_STATE_NOTATTACHED);
        mod_timer(&hcd->rh_timer, jiffies);
}

It's not at all clear to me how that will accomplish what the code used to 
do, i.e., disconnecting all the root hub's children.  When the rh_timer 
expires the status URB may return a change marker for each port.  Or it 
may not -- the root hub code for each HCD will probably need to be changed 
if that is to work.  It might be better to set the appropriate change_bits 
in the root hub's struct hub.

Also, when khubd runs hub_events() it will see that the root hub's state
isn't CONFIGURED -- so it will totally ignore the event.  Maybe what you
should do is mark each of the root hub's children as NOTATTACHED but leave
the root hub alone?

Alan Stern



-------------------------------------------------------
This SF.Net email is sponsored by: YOU BE THE JUDGE. Be one of 170
Project Admins to receive an Apple iPod Mini FREE for your judgement on
who ports your project to Linux PPC the best. Sponsored by IBM. 
Deadline: Sept. 13. Go here: http://sf.net/ppc_contest.php
_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to