Originally Posted by nickolais
My company has designed a new PCIe device and I have developed a new driver for use with the device. To test the driver, I have been loading it with the insmod command.
My customer uses RHEL 5, so I am testing and targeting that distribution. What is the preferred method that I deploy my driver? For instance, how should the user install the driver on their machine? Is it acceptable that they insmod the driver as well? Alternatively, would they want to recompile their kernel with the new driver in it? Do Red Hat users compile their own kernels?
I have not found any discussions or resources about this topic. If someone could point me in the direction of some I would be greatly appreciative. Thanks!
Well, some users do compile their own kernels...some don't. Modprobe/insmod is a fairly 'standard' way of putting a new module into service, with lots of documentation available on getting it to autoload for different systems at boot, etc.
Kernel building can get messy, and if you're running a 24/7 production environment, you want more generic, so the dreaded 2 AM phone-calls won't depend on the one guy who knows how to build a kernel.
Plus, using insmod/modprobe to shove a kernel module in, gives you flexibility...if there's a device problem, you can easily boot to CD/DVD/single-user, and comment it out, to stop any boot-time problems from stopping the boot process. If it's built in the kernel...may not be so easy.....
My $0.02 worth, is to look at the nVidia drivers, and how they do it. They provide an installer, along with several pre-compiled modules for different kernels. When you run the installer, and one of the pre-compiled ones matches what you've got, they shove it in. If not, the kernel source you've got, along with the code they provide, builds one to match your system on the fly.