contrib: dracut: install dependent kernel modules

Eliminates the need for the following workaround

> Add other drivers to dracut:

```
if grep mpt3sas /proc/modules; then
  echo 'force_drivers+=" mpt3sas "'  >> /etc/dracut.conf.d/zfs.conf
fi
if grep virtio_blk /proc/modules; then
  echo 'filesystems+=" virtio_blk "' >> /etc/dracut.conf.d/fs.conf
fi
```

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Jo Zzsi <jozzsicsataban@gmail.com>
Closes #17762
This commit is contained in:
jozzsi 2025-09-23 19:58:38 -04:00 committed by Brian Behlendorf
parent 61a68554de
commit 6dad2f61a3

View File

@ -17,6 +17,7 @@ depends() {
installkernel() {
hostonly='' instmods -c zfs
instmods mpt3sas virtio_blk
}
install() {