Hi Tom,

Apologies for the delayed reply as I was on a vacation followed with a
business travel.

On Wed, May 28, 2025 at 05:27:04PM -0600, Tom Rini wrote:
> A problem with the logic in upstream_dtsi_include currently is that it
> does not list directories such as dts/upstream/src/arm/nxp/imx and so
> will not findi "imx6ul-pinfunc.h" for example as it is normally and
> correctly included without vendor sub-paths.

I can see the problem you are trying to solve here but I fear in future
we might see some header collisions when going too deeper into
sub-vendor paths include. But let's not worry too much about that at
this point until we see a collision as it's atleast provides a way to
drop redundant DT bindings headers. Thanks for working on this.

FWIW:

Reviewed-by: Sumit Garg <[email protected]>

-Sumit

> 
> Signed-off-by: Tom Rini <[email protected]>
> ---
> This becomes a problem if we remove identical header files from
> arch/arm/dts for example and only always use the upstream one.
> 
> Cc: Sumit Garg <[email protected]>
> ---
>  scripts/Makefile.lib | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
> 
> diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib
> index e89a4a51b74d..ac14e4f9dfb2 100644
> --- a/scripts/Makefile.lib
> +++ b/scripts/Makefile.lib
> @@ -205,8 +205,10 @@ dtsi_include_list = $(strip $(u_boot_dtsi_options_debug) 
> \
>  # Modified for U-Boot
>  upstream_dtsi_include = $(addprefix -I, $(srctree)/dts/upstream/src/ \
>       $(sort $(dir $(wildcard $(srctree)/dts/upstream/src/$(ARCH)/*/*))) \
> +     $(sort $(dir $(wildcard $(srctree)/dts/upstream/src/$(ARCH)/*/*/*))) \
>       $(if (CONFIG_ARM64), \
> -              $(sort $(dir $(wildcard 
> $(srctree)/dts/upstream/src/arm64/*/*)))))
> +              $(sort $(dir $(wildcard 
> $(srctree)/dts/upstream/src/arm64/*/*))) \
> +              $(sort $(dir $(wildcard 
> $(srctree)/dts/upstream/src/arm64/*/*/*)))))
>  dtc_cpp_flags  = -Wp,-MD,$(depfile).pre.tmp -nostdinc                    \
>                $(UBOOTINCLUDE)                                         \
>                -I$(dir $<)                                             \
> -- 
> 2.43.0
> 

Reply via email to