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

Re: [Xen-devel] bug in usbback



Hi,

Do you think it's good idea that the method for the notification
of hotplug is switched from xenbus to RING (like pv network's
rx_ring)?

I like the idea of having the port states in the xenstore. It is a low
speed and (mostly) relatively infrequently changing thing so I think
keeping it in xenstore is appropriate.

I think the problem could be solved by simply including a port change
counter for each port, either as part of the existing port-N value or as
an additional 'port-N-generation' field. The backend would just
increment that every time there is a plug or unplug event, and the
frontend could compare the value to what it was last time to see if the
port had changed.


So maybe "port-N=S" would become "port-N=GGS", where S is the current
'speed' value, and "GG" is a change counter. As an example:

1. port-1=000
2. <hot plug>
3. port-1=013
4. <hot unplug>
5. port-1=020
6. <hot plug>
7. port-1=033

I don't think it's a good idea.

If disconnection happened, the urb transfer is sure to make an error, and usbfront can detect this error without counter.

Furthermore, usbfront only emulates the roothub ports' virtual status
by the value of port-N's speed, and, even if the counter value is wrong,
this value cannot be associated to the rootport's status.

As I mentioned, if notifications by xenbus has the problem, I prefer using RING.


Regards,
Noboru




_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.