Ubuntu 10.10 - Unable to blacklist some modules

Asked by Greg Hormann

I've tried a few different ways to blacklist a module, yet they still autoload on boot.

# tail -3 /etc/modprobe.d/blacklist.conf
blacklist ir_rc6_decoder
blacklist rc_rc6_mce
blacklist ir_rc5_decoder

# tail -3 /etc/modprobe.d/blacklist-greg.conf
blacklist ir_rc6_decoder
blacklist rc_rc6_mce
blacklist ir_rc5_decoder

After reboot, they are still loaded. :-(

Googling only resulting in more individuals with the same problem. - http://ubuntuforums.org/showthread.php?p=10662708

Thanks,
Greg.

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu linux-meta Edit question
Assignee:
No assignee Edit question
Solved by:
Chris Boot
Solved:
Last query:
Last reply:
Revision history for this message
Eliah Kagan (degeneracypressure) said :
#1

If I recall correctly, those modules have dashes (-) rather than underscores (_) in their names. If that's true, then the names you've blacklisted aren't actually the names of the modules.

If that advice doesn't help, please post the output of the lsmod command.

Revision history for this message
Greg Hormann (ghormann) said :
#2

It doesn't matter. lsmod shows them as underscore.

$ cat /etc/modprobe.d/blacklist-greg.conf
blacklist ir-rc6-decoder
blacklist ir-rc5-decoder
blacklist rc-rc6-mce

Module Size Used by
lirc_zilog 16725 0
nfsd 306088 13
exportfs 4226 1 nfsd
nfs 321943 0
lockd 75956 2 nfsd,nfs
fscache 50226 1 nfs
nfs_acl 2701 2 nfsd,nfs
auth_rpcgss 44898 2 nfsd,nfs
sunrpc 229477 14 nfsd,nfs,lockd,nfs_acl,auth_rpcgss
snd_hda_codec_nvhdmi 15451 4
ir_lirc_codec 4890 3
lirc_dev 14906 2 lirc_zilog,ir_lirc_codec
ir_sony_decoder 2285 0
ir_jvc_decoder 2410 0
ir_rc6_decoder 2858 0
ir_rc5_decoder 2378 0
snd_hda_codec_via 62447 1
hdpvr 25627 0
v4l2_common 9558 1 hdpvr
videodev 90501 2 hdpvr,v4l2_common
snd_hda_intel 26147 0
nvidia 10221046 28
snd_hda_codec 100951 3 snd_hda_codec_nvhdmi,snd_hda_codec_via,snd_hda_i ntel
snd_hwdep 6660 1 snd_hda_codec
media 13920 1 videodev
ir_nec_decoder 2826 0
snd_pcm 89104 2 snd_hda_intel,snd_hda_codec
snd_seq_midi 5932 0
rc_rc6_mce 1502 0
snd_rawmidi 22207 1 snd_seq_midi
snd_seq_midi_event 7291 1 snd_seq_midi
snd_seq 57512 2 snd_seq_midi,snd_seq_midi_event
snd_timer 23850 2 snd_pcm,snd_seq
snd_seq_device 6912 3 snd_seq_midi,snd_rawmidi,snd_seq
intel_agp 32334 0
v4l2_compat_ioctl32 8818 1 videodev
snd 64181 9 snd_hda_codec_via,snd_hda_intel,snd_hda_codec,sn d_hwdep,snd_pcm,snd_rawmidi,snd_seq,snd_timer,snd_seq_device
mceusb 15223 0
asus_atk0110 12987 0
rc_core 20468 9 ir_lirc_codec,ir_sony_decoder,ir_jvc_decoder,ir_ rc6_decoder,ir_rc5_decoder,ir_nec_decoder,rc_rc6_mce,mceusb
xhci_hcd 60496 0
soundcore 1240 1 snd
snd_page_alloc 8588 2 snd_hda_intel,snd_pcm
joydev 11395 0
psmouse 62080 0
lp 10201 0
serio_raw 4910 0
parport 37032 1 lp
usbhid 42030 0
hid 84710 1 usbhid
ahci 22210 0
r8169 42254 0
libahci 26148 1 ahci
mii 5261 1 r8169
pata_jmicron 2771 0

Revision history for this message
Eliah Kagan (degeneracypressure) said :
#3

"It doesn't matter. lsmod shows them as underscore."

Indeed, you're quite right. It turns out that what I thought I was remembering, I was in fact remembering about something else altogether.

I'll try to look into this further, but I'm leaving the question open as perhaps someone else will be able to help you before I get around to doing so.

Revision history for this message
actionparsnip (andrew-woodhead666) said :
#4

andy@D420:~$ sudo modprobe ir
ircomm irda-usb ir-kbd-i2c ir-nec-decoder ir-rc5-sz-decoder irtty-sir
ircomm-tty iris irlan irnet ir-rc6-decoder ir-usb
irda ir-jvc-decoder ir-lirc-codec ir-rc5-decoder ir-sony-decoder

They are minuses. Perhaps the fact you have them blacklisted in TWO files may be an issue. You could work around this with:

gksudo gedit /etc/rc.local

and add:

rmmod ir-rc6-decoder
rmmod ir-rc5-decoder
rmmod rc-rc6-mce

ABOVE the 'exit 0' line and reboot, may help

Revision history for this message
Greg Hormann (ghormann) said :
#5

I've tried underscores and dashes (minus signs). Neither work.

While doing rmmod is an workaround, blacklisting should work. I'm guessing somewhere modprobe is being called with the -b option, but I have no idea what script that would be in. A search of /etc and /usr/share didn't turn it up.

Greg

Revision history for this message
Chris Boot (bootc) said :
#6

It looks like the modules are forcefully loaded in the kernel LIRC driver. On line 347 of linux-2.6.38/drivers/media/rc/ir-raw.c is a init_decoders() function that loads all the modules into the kernel.

This makes me think that we need to disable the keyboard emulation some other way. I'll keep looking.

Revision history for this message
Best Chris Boot (bootc) said :
#7

The fix for the MCE remotes is very simple:

echo lirc > /sys/class/rc/rc0/protocols

Just put that in /etc/rc.local and all will be well.

Revision history for this message
Greg Hormann (ghormann) said :
#8

Thanks Chris B, that solved my question.