Skip to content

Commit 7debf54

Browse files
aafeijoo-suseLaszloGombos
authored andcommitted
feat(kernel-modules): exclude USB drivers in strict hostonly mode
Provide a way to avoid installing all USB drivers in some use cases where they are not needed, i.e., machines without a USB bus.
1 parent a6395e4 commit 7debf54

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

modules.d/90kernel-modules/module-setup.sh

+6-5
Original file line numberDiff line numberDiff line change
@@ -35,13 +35,14 @@ installkernel() {
3535

3636
if [[ -z $drivers ]]; then
3737
hostonly='' instmods \
38-
hid_generic unix \
38+
hid_generic unix
39+
40+
hostonly=$(optional_hostonly) instmods \
3941
ehci-hcd ehci-pci ehci-platform \
4042
ohci-hcd ohci-pci \
4143
uhci-hcd \
42-
xhci-hcd xhci-pci xhci-plat-hcd
43-
44-
hostonly=$(optional_hostonly) instmods \
44+
usbhid \
45+
xhci-hcd xhci-pci xhci-plat-hcd \
4546
"=drivers/hid" \
4647
"=drivers/tty/serial" \
4748
"=drivers/input/serio" \
@@ -54,7 +55,7 @@ installkernel() {
5455

5556
instmods \
5657
yenta_socket \
57-
atkbd i8042 usbhid firewire-ohci pcmcia hv-vmbus \
58+
atkbd i8042 firewire-ohci pcmcia hv-vmbus \
5859
virtio virtio_ring virtio_pci pci_hyperv \
5960
"=drivers/pcmcia"
6061

0 commit comments

Comments
 (0)