On 14.08.24 11:41, Jan Kiszka wrote: > On 13.08.24 14:52, Nishanth Menon wrote: >> On 11:16-20240813, Jan Kiszka wrote: >>> Hi all, >>> >>> I'm trying to migrate the TI AM65x IOT2050 boards to OF_UPSTREAM but I'm >>> facing issues because I need to still build the u-boot-only overlays. It >>> is also a bit weird (but works) having to specify >>> >>> CONFIG_SPL_OF_LIST="../../../../arch/arm/dts/k3-am65-iot2050-spl" >>> > > Actually, this does NOT work: I just had a long morning debugging SPL > which no longer started because it picked the non-filtered dtb. The > filtered one ended up in a folder outside of the u-boot sources because > of all those ../ and hard-wiring to dts/upstream. > >>> for our spl dtb. >>> >>> Are there means to still build certain dtb[o] files in arch/<arch>/dts? >>> I'm a bit lost in the Makefile forest. >>> >> >> Sumit: Any suggestions? >> > > I would really like to hear some better proposals than my local > workarounds to far. They don't converge although I already patched some > core Makefile (overlays are building now). >
OK, I side-stepped the spl issue by using one of our variant DTBs for spl as well - happens to work. For the overlays, I need to add --- a/scripts/Makefile.dts +++ b/scripts/Makefile.dts @@ -1,5 +1,7 @@ # SPDX-License-Identifier: GPL-2.0+ +include $(srctree)/config.mk + dtb-y += $(patsubst %,%.dtb,$(subst ",,$(CONFIG_DEFAULT_DEVICE_TREE) $(CONFIG_OF_LIST) $(CONFIG_SPL_OF_LIST))) ifeq ($(CONFIG_OF_UPSTREAM_BUILD_VENDOR),y) in order to then be able to do --- a/board/siemens/iot2050/config.mk +++ b/board/siemens/iot2050/config.mk @@ -5,4 +5,12 @@ # Authors: # Jan Kiszka <[email protected]> +ifneq ($(CONFIG_SPL_BUILD),y) +dtbo-list = \ + k3-am6548-iot2050-advanced-m2-bkey-usb3-overlay \ + k3-am6548-iot2050-advanced-m2-bkey-ekey-pcie-overlay + +dtb-y += $(patsubst %,../../../../arch/arm/dts/%.dtbo,$(dtbo-list)) +endif + flash.bin: all Does that make sense? Jan -- Siemens AG, Technology Linux Expert Center

