Hi,

I was making some experiments with gadgetfs in combination with dummy_hcd (kernel vers. 2.6.12) and libusb (vers. 0.1.10a). First I was analyzing the example userspace driver (usb.c). Then I wrote a couple of my own small tests and most of it worked quite like expected (great work folks, thanks) with one exception:

When I reopen a file representing a "normal" endpoint (e.g. "ep-a") and try to configure it (by writing the descriptors to it), I always get "Invalid argument" error.

(I thought that the configure/close works like the enable/disable for endpoints ?!?)

I looked at the gadget/inode.c to understand more and found the functions ep_config and ep_release, which appears to be called on configuring (first time writing) and closing an endpoint-file. It did strike me (without understanding too much of it yet) that unlike ep_config, which calls usb_endpoint_enable, the ep_release doesn't call usb_endpoint_disable as I would expect. After I added the call, everything seems to work fine.

Could someone please check, if it was just forgotten or it's on purpose that way.

If someone is interested I can send an example code that can reproduce this behavior.

Greetings,
Pavol.



-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
linux-usb-devel@lists.sourceforge.net
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to