Skip to content

Commit f263b39

Browse files
chewittgitbook-bot
authored andcommitted
GitBook: [master] one page modified
1 parent 64b1dcf commit f263b39

File tree

1 file changed

+14
-11
lines changed

1 file changed

+14
-11
lines changed

how-to/blacklist-kernel-module.md

Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,24 @@
11
# Blacklist Kernel Module
22

3+
In most Linux distros modules are blacklisted by creating `/etc/modprobe.d/blacklist.conf` which contains the name of the module. In LibreELEC `/etc` is inside the read-only `SYSTEM` file so we provide an alternate location `/storage/.config/modprobe.d` which is overlaid onto the normal `/etc` location during boot.
34

5+
### Example
46

5-
In this example there is a module named `rc-pinnacle-pctv-hd` that should be blacklisted.
7+
To blacklist the `rc-pinnacle-pctv-hd` module. Login to your LibreELEC box using SSH and confirm the module is loaded:
68

7-
* Connect with SSH to your LibreELEC box.
8-
* list all used modules \(search for rc, ir or cir\)
9+
```text
10+
lsmod
11+
```
912

10-
```text
11-
lsmod
12-
```
13+
If the module is loaded, append the module name to `blacklist.conf`:
1314

14-
* add blacklisted module to blacklist.conf
15+
```text
16+
echo "blacklist rc-pinnacle-pctv-hd" >> /storage/.config/modprobe.d/blacklist.conf
17+
```
1518

16-
```text
17-
echo "blacklist rc-pinnacle-pctv-hd" > /storage/.config/modprobe.d/blacklist.conf
18-
```
19+
Now reboot to effect the change.
1920

20-
* reboot
21+
### Module vs Driver
22+
23+
This approach to blacklisting only works with modules that are compiled with `=m` to create an independent module; meaning they are loaded via modprobe. If the module has been compiled directly into the kernel with `=y` modprobe is not used and this method has no effect. Drivers that are compiled-in are normally controlled via kernel boot params.
2124

0 commit comments

Comments
 (0)