[Buildroot] [PATCH v2 3/5] package/dmraid: use modules-load to load the kernel module

Thomas Petazzoni
2020-04-19T12:49:03Z

On Sun, 19 Apr 2020 12:42:39 +0200
"Yann E. MORIN" <yann.morin.1998@free.fr> wrote:

> Can't we simply have a modules table, like we have the device amd user
> tables? Something like:
>
> define DMRAID_MODULES
> dm-stuff
> dm-blurb
> dm-blabla
> endef
>
> And then have the package and rootfs infrastructures handle that like
> the other tables?

If we're going to do that, then we don't need an infra at all,
package/dmraid/ can simply contain a file with the list of modules,
which gets installed to /usr/lib/modules-load.d/.

I think the idea here was to avoid maintaining the list of dmraid
modules, and ensure it is generated automatically from the list of
installed modules. But even that is not guaranteed to work 100%, for
example if one day dmraid adds a module that doesn't match the
dm[_-]mod.ko* expression.

Thomas
--
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering