mirror of
https://salsa.debian.org/kernel-team/initramfs-tools.git
synced 2026-01-27 01:44:25 +00:00
If the busybox-static package is installed, the modprobe implementation used will be the one from busybox, which behaves slightly differently. Specifically, the busybox implementation does not support `install` commands from modprobe.d conf files: https://git.busybox.net/busybox/tree/modutils/modprobe.c?h=1_31_stable#n279 Since mkinitramfs already ensures that /sbin/modprobe is copied into /sbin for the initrd, it is safe to fully-qualify the modprobe call and never invoke the busybox version.
29 lines
396 B
Bash
Executable File
29 lines
396 B
Bash
Executable File
#!/bin/sh
|
|
|
|
PREREQ=""
|
|
prereqs()
|
|
{
|
|
echo "$PREREQ"
|
|
}
|
|
case $1 in
|
|
# get pre-requisites
|
|
prereqs)
|
|
prereqs
|
|
exit 0
|
|
;;
|
|
esac
|
|
|
|
# shellcheck disable=SC2013
|
|
for x in $(cat /proc/cmdline); do
|
|
case ${x} in
|
|
all_generic_ide)
|
|
/sbin/modprobe ata_generic all_generic_ide=1
|
|
;;
|
|
all_generic_ide=*)
|
|
if [ -n "${x#all_generic_ide=}" ]; then
|
|
/sbin/modprobe ata_generic all_generic_ide=1
|
|
fi
|
|
;;
|
|
esac
|
|
done
|