Linux: Find out what kernel drivers (modules) are loaded

Posted on in Categories , , , , , , last updated January 3, 2017

How do I find out what Linux kernel drivers are loaded by Linux? How do I list device drivers (or so-called modules) loaded into memory?

Under Linux use the file /proc/modules shows what kernel modules (drivers) are currently loaded into memory.

lsmod is a trivial program which nicely formats the contents of the /proc/modules, showing what kernel modules are currently loaded.

lsmod command

You need to use lsmod command to show the status of modules in the Linux Kernel. Simply type the lsmod at a shell prompt to list all loaded modules:
$ lsmod
Sample outputs:

Module                  Size  Used by
binfmt_misc            12680  1 
rfcomm                 40856  0 
l2cap                  25856  5 rfcomm
bluetooth              55908  4 rfcomm,l2cap
ppdev                  10116  0 
acpi_cpufreq           10056  1 
cpufreq_stats           7360  0 
cpufreq_userspace       5408  0 
cpufreq_conservative     8200  0 
cpufreq_ondemand        9228  4 
cpufreq_powersave       2688  0 
freq_table              5792  3 acpi_cpufreq,cpufreq_stats,cpufreq_ondemand
pcc_acpi               13184  0 
dev_acpi               12292  0 
tc1100_wmi              8068  0 
sony_acpi               6284  0 
dock                   10268  0 
sbs                    15652  0 
asus_acpi              17308  0 
ac                      6020  0 
battery                10756  0 
i2c_ec                  6016  1 sbs
video                  16388  0 
backlight               7040  1 asus_acpi
container               5248  0 
button                  8720  0 
nls_utf8                3072  1 
ntfs                  107764  1 
eeprom                  8336  0 
i2c_i801                9356  0 
sbp2                   23812  0 
lp                     12452  0 
fuse                   46612  0 
af_packet              23816  2 
snd_hda_intel          21912  4 
snd_hda_codec         205056  1 snd_hda_intel
snd_pcm_oss            44544  0 
snd_mixer_oss          17408  1 snd_pcm_oss
snd_pcm                79876  4 snd_hda_intel,snd_hda_codec,snd_pcm_oss
snd_seq_dummy           4740  0 
snd_seq_oss            32896  0 
tuner                  61864  0 
snd_seq_midi            9600  0 
snd_rawmidi            25472  1 snd_seq_midi
bttv                  173684  0 
video_buf              26116  1 bttv
snd_seq_midi_event      8448  2 snd_seq_oss,snd_seq_midi
ir_common              31236  1 bttv
nvidia               6224240  24 
compat_ioctl32          2304  1 bttv
snd_seq                52592  6 snd_seq_dummy,snd_seq_oss,snd_seq_midi,snd_seq_midi_event
i2c_algo_bit            8712  1 bttv
btcx_risc               5896  1 bttv
snd_timer              23684  3 snd_pcm,snd_seq
snd_seq_device          9100  5 snd_seq_dummy,snd_seq_oss,snd_seq_midi,snd_rawmidi,snd_seq
tveeprom               15888  1 bttv
iTCO_wdt               11812  0 
iTCO_vendor_support     4868  1 iTCO_wdt
parport_pc             36388  1 
agpgart                35400  1 nvidia
tsdev                   8768  0 
parport                36936  3 ppdev,lp,parport_pc
snd                    54020  16 snd_hda_intel,snd_hda_codec,snd_pcm_oss,snd_mixer_oss,snd_pcm,snd_seq_oss,snd_rawmidi,snd_seq,snd_timer,snd_seq_device
soundcore               8672  1 snd
i2c_core               22656  8 i2c_ec,eeprom,i2c_i801,tuner,bttv,nvidia,i2c_algo_bit,tveeprom
rt61                  245128  1 
psmouse                38920  0 
snd_page_alloc         10888  2 snd_hda_intel,snd_pcm
videodev               28160  1 bttv
v4l2_common            25216  3 tuner,bttv,videodev
v4l1_compat            15236  1 videodev
serio_raw               7940  0 
shpchp                 34324  0 
pci_hotplug            32576  1 shpchp
evdev                  11008  3 
pcspkr                  4224  0 
ipv6                  268960  20 
ext3                  133128  1 
jbd                    59816  1 ext3
mbcache                 9604  1 ext3
sg                     36252  0 
sr_mod                 17060  0 
sd_mod                 23428  4 
cdrom                  37664  1 sr_mod
generic                 5124  0 [permanent]
ata_generic             9092  0 
ohci1394               36528  0 
ieee1394              299448  2 sbp2,ohci1394
pata_marvell            7936  0 
ata_piix               15492  3 
libata                125720  3 ata_generic,pata_marvell,ata_piix
scsi_mod              142348  5 sbp2,sg,sr_mod,sd_mod,libata
e1000                 126016  0 
ehci_hcd               34188  0 
uhci_hcd               25360  0 
usbcore               134280  3 ehci_hcd,uhci_hcd
thermal                14856  0 
processor              31048  2 acpi_cpufreq,thermal
fan                     5636  0 
fbcon                  42656  0 
tileblit                3584  1 fbcon
font                    9216  1 fbcon
bitblit                 6912  1 fbcon
softcursor              3200  1 bitblit
vesafb                  9220  0 
capability              5896  0 
commoncap               8192  1 capability

Get more information about the driver

To get more information about specific driver use modinfo command. The syntax is:
modinfo {driver-name}
To see information about a Linux Kernel module called e1000, enter:
$ modinfo e1000
Sample outputs:

filename:       /lib/modules/2.6.20-16-generic/kernel/drivers/net/e1000/e1000.ko
version:        7.3.15-k2-NAPI
license:        GPL
description:    Intel(R) PRO/1000 Network Driver
author:         Intel Corporation, <linux.nics@intel.com>
srcversion:     037027F24F37E1AAEFC4360
alias:          pci:v00008086d000010C5sv*sd*bc*sc*i*

See modinfo and lsmod man pages for more info.

Posted by: Vivek Gite

The author is the creator of nixCraft and a seasoned sysadmin and a trainer for the Linux operating system/Unix shell scripting. He has worked with global clients and in various industries, including IT, education, defense and space research, and the nonprofit sector. Follow him on Twitter, Facebook, Google+.

10 comment

  1. Thanks man for the post.

    One thing I cannot find out though is what the “used by” numbers stand for. I can see the other modules using a module for some of them but this usually doesn’t reveal anything.

  2. this list a modules not drivers. there are drivers compiled into kernel and are not loadable modules, so you won’t see them with this command.
    This command list only modules, a module doesn’t have to call driver_register().

Leave a Comment