[PATCH v6 6/8] kbuild: Allow adding modules into the FIT ramdisk

Thomas Weißschuh thomas.weissschuh at linutronix.de
Tue Nov 25 23:16:38 PST 2025


On Tue, Nov 25, 2025 at 02:58:12PM -0700, Simon Glass wrote:
> On Thu, 20 Nov 2025 at 00:49, Thomas Weißschuh
> <thomas.weissschuh at linutronix.de> wrote:
> >
> > On Wed, Nov 19, 2025 at 11:13:27AM -0700, Simon Glass wrote:

(...)

> > >  quiet_cmd_fit = FIT     $@
> > >        cmd_fit = $(MAKE_FIT) -o $@ --arch $(UIMAGE_ARCH) --os linux \
> > > -             --name '$(UIMAGE_NAME)' \
> > > +             --name '$(UIMAGE_NAME)' $(MAKE_FIT_FLAGS) \
> >
> > Remnant of a previous revision?
> 
> The flags are there to allow extra options to be passed if needed.

Are they necessary for the module functionality added here?
If not I'd put them into a dedicated commit.

> >
> > >               $(if $(findstring 1,$(KBUILD_VERBOSE)),-v) \
> > >               $(if $(FIT_DECOMPOSE_DTBS),--decompose-dtbs) \
> > > +             $(if $(FIT_MODULES),--modules @$(objtree)/modules.order) \
> >
> > I am wondering how module dependencies work without the depmod invocation
> > and modules.dep file.
> 
> We have a mechanism to place a pre-build initrd with the filesystem,
> etc. into the FIT. But for this particular feature (suggested by Ahmad
> Fatoum) we are just providing the raw modules. Presumably another
> initrd would be needed to provide the startup files?

modules.dep is more than optional and generic startup files but an integral
part of a module tree. Without it, any module depending on another module's
symbols will fail to load. Also the modules will be unsigned, potentially
making them unloadable. Ahmad's patch does produce a complete and fully
functional module tree by means of 'make headers_install'.

> > >               --compress $(FIT_COMPRESSION) -k $< @$(word 2,$^)
> > >
> > >  # XZ
> > > --
> > > 2.43.0



More information about the linux-arm-kernel mailing list