1

To what I see the modules for different kernel versions are stored below /lib/modules, i.e as /lib/modules/{version}/...../...ko

Now, while this makes it evident where to store the modules for each different kernel version, I have currently changed the .config (i.e. what I think is the configuration) of a kernel I have already have.

My question is where would the modules for this new kernel configuration of the now two times existing kernel version go? Would /lib/modules/{version}_{configsuffix}/...../...ko be the way?

How would a tool like modprobe know where to find those modules?

Additionally I also want to state my suspicion that for a fair share of the modules, even different values in the kernel's configuration .config would lead to the same identical kernel module. Yet even in this case there might be some settings in the .config to make adjust the modules and hence create different modules even for the same kernel version

1

Whenever you change the configuration, add a suffix that succintly describes the configuration to the EXTRAVERSION field of the Makefile.

EXTRAVERSION=-lpae

and another time

EXTRAVERSION=-486

That way different configurations are different versions as far as all the tooling is involved: different output from uname -r, different subdirectories in /lib/modules, etc.

That's what most distributions do.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.