Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

While I can use lsmod in order to show currently active kernel modules, how can I see which drivers are statically built into the kernel AND currently active?

share|improve this question
up vote 11 down vote accepted

You could do a cat /lib/modules/$(uname -r)/modules.builtin

From the Kernel Documentaton

modules.builtin

This file lists all modules that are built into the kernel. This is used by modprobe to not fail when trying to load something builtin.

share|improve this answer

If your linux has a /proc/config.gz

That has all the built modules. Copy it elsewhere and unzip it. Open the file everything with a "=M" is built as a module. Everything with a "=Y" is statically built.

hwinfo will list the "Driver:" check the above file to see if it is statically built.

FYI: All statically built drivers are always loaded into memory and ready for action. Without the corresponding hardware they will not do anything, but use memory.

share|improve this answer
1  
What if there is no /proc/config.gz? – JohnnyFromBF Apr 5 '13 at 13:25
    
Ok I just found a .config file in the directory where I compiled the kernel, that's obviously what you meant. – JohnnyFromBF Apr 5 '13 at 13:51
1  
This file also exists here: /boot/config-$(uname -r). – JohnnyFromBF Apr 5 '13 at 13:58

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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