bcachefs-tools/initramfs/hook
Gabriel 944cb4ce32 Register devices with just udev.
This means bcache devices will be registered earlier and in all
cases, not just when the rootfs fails to mount.

The initramfs hook is still there to ensure the bcache module
and udev rules are shipped if an initramfs is used.
2013-04-11 17:08:23 -07:00

23 lines
311 B
Bash
Executable File

#!/bin/sh
PREREQ="udev"
prereqs()
{
echo "$PREREQ"
}
case $1 in
prereqs)
prereqs
exit 0
;;
esac
. /usr/share/initramfs-tools/hook-functions
cp -pt "${DESTDIR}/lib/udev/rules.d" /lib/udev/rules.d/61-bcache.rules
copy_exec /lib/udev/bcache-register
copy_exec /sbin/probe-bcache
manual_add_modules bcache