Hi,

sorry for the wrong patch format.

I am trying to detect a change. At the moment I think the change could be 
ignored if a
port connection-change occurs and the port status has again the 
'PORT_CONNECTION' bit set. 

I have a fx3 device which does a re-enumeration after a firmware download. This 
is working
as expected and I am seeing a 'remove event' and a 'add event' monitoring via 
udevadm. But
if I connect multiple devices at the same time via an usb hub I am sometimes 
not receiving
a 'remove event' and 'add event' for a single device.

I think the problem could be that when a device disconnects and the port 
connection-change
occurs and before the 'PORT_CONNECTION' bit is checked the device could already 
be
reconnected and the 'PORT_CONNECTION' bit is set. Therefore I think it is not 
correct to
resuscitate the exisiting device.

On Fri, Sep 20, 2019 at 10:55:56AM +0200, Greg KH wrote:
> On Fri, Sep 20, 2019 at 12:36:28PM +0200, David Heinzelmann wrote:
> > When a port connection-change occurs the hub driver tries to resuscitate an 
> > existing device.
> > Activated from a firmware download a usb device can re-enumerate with new 
> > or changed device
> > descriptors. Therefore it will be checked for changed device descriptors 
> > before the connection
> > is resuscitated and the connection-change event is ignored.
> 
> Please wrap your lines at 72 columns :(
> 
> Anyway, what problem are you trying to solve here?  What is broken with
> how things work today?  Are you trying to ignore a change that is
> currently showing up as a change, or trying to do the opposite?
> 
> thanks,
> 
> greg k-h

Reply via email to