[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

[RFC] Simplify USB detection



Currently we we have a separate udeb usb-discover for USB detection and 
activation, with a boot parameter debian-installer/probe/usb.

The udeb uses PCI ID lists from discover and/or some info from
/sys/bus/pci/devices to load the core USB drivers ({U,O,E}HCI) and then 
loads usb keyboard, hid and serial modules.
This is done during debian-installer-startup.d processing.

IMO this can be simplified a lot because currently the core USB modules 
will be loaded automatically by the kernel/udev anyway, making the 
debian-installer/probe/usb parameter rather useless.

I propose to drop the usb-discover udeb completely and instead add a 
simple script in rootskel (see patch below) to load the keyboard, hid and 
serial modules if USB is supported.

Of course, some changes under installer/build and the manual will be 
needed as well if the udeb and the boot parameter are dropped.

Cheers,
FJP

Index: src/lib/debian-installer-startup.d/S33usb-linux
===================================================================
--- src/lib/debian-installer-startup.d/S33usb-linux     (revision 0)
+++ src/lib/debian-installer-startup.d/S33usb-linux     (revision 0)
@@ -0,0 +1,8 @@
+#!/bin/sh
+
+# Setup USB
+if [ -e /sys/bus/usb ]; then
+       modprobe -q usbkbd || true
+       modprobe -q usbhid || true
+       modprobe -q usbserial || true
+fi

Index: src/lib/debian-installer-startup.d/Makefile
===================================================================
--- src/lib/debian-installer-startup.d/Makefile (revision 46401)
+++ src/lib/debian-installer-startup.d/Makefile (working copy)
@@ -24,6 +24,9 @@
        S35term

 ifeq ($(DEB_HOST_ARCH_OS),linux)
+  files += \
+       S33usb-linux
+
   ifneq (,$(filter i386 amd64,$(DEB_HOST_ARCH_CPU)))
     files += \
        S05acpi-linux-x86 \

Attachment: pgppLTR1GhrDR.pgp
Description: PGP signature


Reply to: