On 6/1/05, Alan Stern <[EMAIL PROTECTED]> wrote: > It's not so easy to synchronize operations on an attribute with driver > operations if the driver doesn't own the attribute's kobject. In this > case there would have to be a single driver-wide semaphore protecting > intf->dev.driver_data for all interfaces controlled by the driver. And > even that could theoretically fail if more than one driver was capable of > binding to the interface.
Right. In serio/gameport code we take a lock and then check if currently bound driver is still "us". This way we can detect if device was switched to alternate driver. If it still the same driver we asume that the data returned is still relevant even if device was disconnected and reconnected. Maybe we need some kind of versioning to see if attribute object is stale or not. -- Dmitry ------------------------------------------------------- This SF.Net email is sponsored by Yahoo. Introducing Yahoo! Search Developer Network - Create apps using Yahoo! Search APIs Find out how you can build Yahoo! directly into your own Applications - visit http://developer.yahoo.net/?fr=offad-ysdn-ostg-q22005 _______________________________________________ linux-usb-devel@lists.sourceforge.net To unsubscribe, use the last form field at: https://lists.sourceforge.net/lists/listinfo/linux-usb-devel