Re: [PATCH 0/6] Extend fdt_overlay_apply() to allow merge of overlay blobs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



On Mon, Mar 19, 2018 at 11:20:19AM +0530, Srivatsa Vaddagiri wrote:
> * Maxime Ripard <maxime.ripard@xxxxxxxxxxx> [2018-03-18 19:09:16]:
> 
> > > In addition to compiling DT code outside core kernel tree, we also want to merge
> > > the blobs back to respective blobs found in kernel build tree (soc.dtb or
> > > boardX.dtbo), as otherwise relying on bootloader to do all the overlay impacts
> > > boot-time.
> > > 
> > > This brings up the need to merge two overlay blobs (fingerprint-overlay.dtbo +
> > > boardX.dtbo), which currently doesn't seem to be supported and which this patch
> > > series aims to support.
> > 
> > If I understood you right, you want in your "feature" overlay to
> > depend on nodes that are only defined in your board overlay?
> 
> Actually the feature overlay can depend on nodes that are both in soc dtb and
> board overlay. To explain this further, feature overlay can be split into two
> portions:
> 
> feature-soc.dts -> this part represents feature DT code that is common across
> all board configuration using given SOC. This will attempt to changde nodes
> found only in soc.dts
> 
> feature-boardX.dts -> this part represents feature DT code that is specific to a
> given board . It can attempt to change nodes in both boardX.dts as well as
> soc.dts
> 
> We could compile both feature-soc.dts and feauture-boardX.dts as
> feature-soc.dtbo/feature-boardX.dtbo respectively and overlay them one after
> other at runtime (in bootloader), but that introduces impact to boot-time. This
> is the reason why we want to merge offline at compile time.
> 
> feature-soc.dtbo needs to merge with soc.dtb (found in kernel obj tree)
> feature-boardX.dtbo needs to merge with boardX.dtbo (found in kernel obj tree)

Right, but then, you just depend on something that is already depend
on something in the base tree (whether the base tree is just a single
tree or the aggregation of a base tree and previously applied
overlays).

> > If so, why not simply merge the __symbols__ node when we apply an
> > overlay with the base tree, and just call fdt_apply_overlay as many
> > times as needed?
> 
> Not sure if I follow you here. Please see my comment on not wanting
> to merge feature DTBOs at runtime in bootloader.

fdtoverlay also allow you to build a single blob at build time.

Maxime

-- 
Maxime Ripard, Bootlin (formerly Free Electrons)
Embedded Linux and Kernel engineering
https://bootlin.com
--
To unsubscribe from this list: send the line "unsubscribe devicetree-compiler" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Device Tree]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]

  Powered by Linux