"Andrew Pargeter" <[EMAIL PROTECTED]> writes: > 1- How do I build the code as a module? Is there a way to build > JUST the usb modules, or better yet just the skeleton usb module? >
from TOPDIR, make modules SUBDIRS=drivers/usb > 2- What does "make modules_install" do? Apparently this is run after make > modules. This installs all the modules into the appropriate directory in /lib/modules. If you're careful you can just copy your skeleton.o file to the appropriate directory. That directory is (probably) /lib/modules/`uname -r`/kernel/drivers/usb. > 3- Okay, so now I've got my skeleton.o or whatever. What has to be > configured as far as hotplug goes to get it loaded when I plug in my device? /me goes out on a limb. If you have the userland tools for hotplug and hotplug-utils, then I think you're done. Basically depmod takes care of setting up hotplug to know about your driver with respect to the VIN/PIN. > 4- how do the /dev/usb entries get setup properly so I can open() the device > from a user mode app.? Sorry, here's where I get off the train. I'm not familiar with usbdevfs. I'm using something reffered to as "driver fs". Greg can definitely talk more about it. However, a very good place to start is the article he wrote about something very similar that he did in the PCI Hotplug module. That article is here: http://www.linuxjournal.com/article.php?sid=5633 I don't know that I necessarily recommend this approach. It's cost me several weeks of study to understand what it is and how it works. However, the impetus for this approach is that Linux has declared a moritorium on assigning major/minor numbers for devices in /dev. Using character type device inodes requires those major/minor numbers. Going with something like driver fs doesn't require major/minor number character special files. You just operate on normal files. Anyway, YMMV. -- (__) Doug Alcorn - Unix/Linux/Web Developing oo / PGP 02B3 1E26 BCF2 9AAF 93F1 61D7 450C B264 3E63 D543 |_/ mailto:[EMAIL PROTECTED] http://www.lathi.net ------------------------------------------------------- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf _______________________________________________ [EMAIL PROTECTED] To unsubscribe, use the last form field at: https://lists.sourceforge.net/lists/listinfo/linux-usb-devel