Michael Sternberg wrote:
> Hello everybody
>
> I'm pretty new in Linux kernel development and seeking answers for
> some questions related to binary compatibility between various kernels.
>
> I know that there is no stable kernel interface in Linux.
> Here are appropriate articles that describe the problem:
> http://www.kroah.com/log/linux/stable_api_nonsense.html
> http://tinyurl.com/yane5lb
>
> I understand that the best way to make the GPLed module to be
> supported in all future versions of kernel is to add it into the main
> kernel tree.
>
> Question #1:
> Where do I start if I want to add my module into main tree ?
> What are chances that this process will succeed ?
If your module is well-written, chances are pretty high.
>
> Yet, if it's not an option for the moment and developer wants to
> supply prebuilt binary images of kernel module - what are the
> alternatives ?
That depends - if your module is GPL - build it for some common set of
kernels
and supply your code for those who have their own.
If it really is binary-only, you'll have to go "blob" way - provide your
code inside
a binary which uses your API, and sources for a wrapper, which can be
compiled to
particular kernel. That's how ATI, Nvidia, and other binary-only driver
providers
do it.
>
> Question #2:
> Let's say I built a binary kernel module with headers of
> 2.6.18-92.el5-i686 Red Hat kernel.
> Will it work with another 2.6.18 Red Hat kernels ?
> With plain vanilla 2.6.18 kernels ?
> With other 2.6 kernels ?
Depending on kernel build options, it might work in some very rare
cases. Safe bet is "No"

> Are there any promises for kernel binary compatibility from, at least,
> large vendors like RHEL and SLES ?
No.
>
> Question #3:
> Is it common in Linux to automatically build and install kernel module
> during installation ?
Yes.
> Are there any packages/frameworks that provide this capability ?
The standard Linux build system (Kbuild) does it all for you.
Get any external module, and look at build system.
For example, take a look at how compat-wireless does it
(http://linuxwireless.org/en/users/Download/stable/)
It has to build a lot of modules, depending on user's choices,
so it might be a bit more complex then you need.

-- 
Ilya A. Volynets-Evenbakh
http://www.total-knowledge.com


_______________________________________________
Linux-il mailing list
Linux-il@cs.huji.ac.il
http://mailman.cs.huji.ac.il/mailman/listinfo/linux-il

Reply via email to