Hi Alan :)
* Alan Stern <[EMAIL PROTECTED]> dixit:
> > BTW, and judging from the program I've read, there are lots of
> > operations that must be done using 'usb_control_msg', and libusb
> > implements that function with exactly the same interface as the
> > kernel. The only difference is that libusb uses ioctl and the kernel
> > implements the function using URB's. IMHO libusb doesn't provide a
> > cleaner API, the only advantage of libusb is portability. Anyway,
> > I've not used it enough to judge, I'm more concerned about kernel USB
> > interface, not libusb one.
> You don't seem to understand the difference between a kernel API and a
> user API. Only code that is part of the kernel can use a kernel API, so
> only kernel drivers can use the "URB" interface. By contrast, a user API
> can be used by regular programs, not part of the kernel. libusb provides
> a user API.
I thought that <linux/usb.h> provided a user API, not a kernel
one. In fact I thought that the functions provided throught that
header were syscalls. They are not, I've checked ;)
> So there's really no choice. Unless you're writing a kernel module, your
> program can't use URBs. You can use libusb, or if you don't care about
> portability you can use ioctl calls directly. But you can't use URBs.
OK, that's right. I really thought that there were syscalls
providing USB API for user space programs. That sounded less weird
when I first thought of it ;)) Thanks for the help :)))
Ra�l N��ez de Arenas Coronado
--
Linux Registered User 88736
http://www.dervishd.net & http://www.pleyades.net/
It's my PC and I'll cry if I want to...
-------------------------------------------------------
This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting
Tool for open source databases. Create drag-&-drop reports. Save time
by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc.
Download a FREE copy at http://www.intelliview.com/go/osdn_nl
_______________________________________________
[email protected]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-users