[PATCH 1/2] global: Clean up arch/*/dts/Makefile

Tom Rini trini at konsulko.com
Sun Nov 19 21:28:02 CET 2023


On Sun, Nov 19, 2023 at 12:09:07PM -0700, Simon Glass wrote:
> Hi Tom,
> 
> On Fri, 17 Nov 2023 at 15:52, Tom Rini <trini at konsulko.com> wrote:
> >
> > With commit 3609e1dc ("dts: automatically build necessary .dtb files")
> > we now have logic that will ensure that all device trees needed in the
> > binary are built automatically. Any device tree that the developer needs
> > while working can still be built normally via make arch/.../foo.dtb so
> > we can simply drop the rest of this logic.
> >
> > Suggested-by: Rasmus Villemoes <rasmus.villemoes at prevas.dk>
> > Signed-off-by: Tom Rini <trini at konsulko.com>
> > ---
> >  arch/arc/dts/Makefile        |    8 -
> >  arch/arm/dts/Makefile        | 1436 +---------------------------------
> >  arch/m68k/dts/Makefile       |   18 -
> >  arch/microblaze/dts/Makefile |    2 -
> >  arch/mips/dts/Makefile       |   37 -
> >  arch/nios2/dts/Makefile      |    2 -
> >  arch/powerpc/dts/Makefile    |   32 -
> >  arch/riscv/dts/Makefile      |    9 -
> >  arch/sandbox/dts/Makefile    |    5 -
> >  arch/sh/dts/Makefile         |    2 +-
> >  arch/x86/dts/Makefile        |   22 -
> >  arch/xtensa/dts/Makefile     |    2 -
> >  configs/iot2050_defconfig    |    1 +
> >  13 files changed, 6 insertions(+), 1570 deletions(-)
> 
> I can see the motivation for this, but it ends up moving us away from
> driver model and devicetree, IMO. For example, rk3399 and other
> rockchip boards use DT for their init so the same U-Boot can be used
> for all, mostly. Ideally that is the way all boards would be, as they
> are in Linux.
> 
> But here I have to manually add all the rk3399 boards to OF_LIST for
> each board and enable SPL_LOAD_FIT (and SPL_FRAMEWORK but that is
> fine) to make this work.

How are you doing this today on N rk3399 boards if you aren't tweaking a
CONFIG option to get the correct dtb in to the final binary? That I
think is where we go back-and-forth on stuff like this. If there's
deconfigs that can support N boards, but only list a, or only a few, dtb
files in the right CONFIG variable how do you get it to run on the
others? I know you noted some Exynos platforms it's a simple concat to
make another platform work instead. But I really don't know how common
that is in theory, and even less so in practice. Picking up rk3399, you
need bl31 and op-tee and you can only get those so generic too.

And part of the issue is that with Linux, the "do board specific things"
just gets pushed down a layer, to us. We have to just know X/Y/Z at
build time so that someone else can know it at run time.

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 659 bytes
Desc: not available
URL: <https://lists.denx.de/pipermail/u-boot/attachments/20231119/602b5dd2/attachment.sig>


More information about the U-Boot mailing list