Say, I have a default Gentoo install with all the modules (e.g. device drivers) compiled. From this point, is there an easy way to exclude the unused modules the next time I recompile the kernel?
Howdo I tell which kernel modules are required
gentookernel-modules
Best Answer
make localmodconfig
andmake localyesconfig
(introduced in 2.6.32, which was released in December 3, 2009) will select the modules needed to load the modules in use.More info.
Note that this does not take into account modules that were loaded once, but are currently unloaded. ArchLinux has a modprobed_db thing that workarounds this, I don't know whether Gentoo has one as well.