Re: [PATCH v9 REBASE 6/9] USB: notify phy when root hub port connect change

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

 



Dear Richard Zhao,

[...]

> > > --- a/drivers/usb/core/hub.c
> > > +++ b/drivers/usb/core/hub.c
> > > @@ -1924,6 +1924,11 @@ void usb_disconnect(struct usb_device **pdev)
> > > 
> > >  	 */
> > >  	
> > >  	device_del(&udev->dev);
> > > 
> > > +	if (udev->parent && !udev->parent->parent) {
> > > +		struct usb_hcd *hcd = bus_to_hcd(udev->bus);
> > > +		usb_phy_notify_disconnect(hcd->phy, udev->portnum);
> > > +	}
> > 
> > Shouldn't that go before device_del() ?
> 
> Any difference?

I was worried some corruption of other members in udev structure might happen, 
but I'm not so sure anymore after taking deer look.

> Thanks
> Richard

Best regards,
Marek Vasut
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux