[PATCH v2] Makefile: Fix include directory for OF_UPSTREAM

Tony Dinh mibodhi at gmail.com
Thu Jun 13 07:04:49 CEST 2024


Hi Michael,

On Wed, Jun 12, 2024 at 12:46 PM Michael Nazzareno Trimarchi
<michael at amarulasolutions.com> wrote:
>
> HI
>
> On Wed, Jun 12, 2024 at 7:25 PM Tom Rini <trini at konsulko.com> wrote:
> >
> > On Wed, Jun 12, 2024 at 10:17:12AM +0200, Michael Nazzareno Trimarchi wrote:
> > > Hi Tom
> > >
> > > On Mon, Jun 3, 2024 at 5:08 PM Patrick Barsanti
> > > <patrick.barsanti at amarulasolutions.com> wrote:
> > > >
> > > > Always prioritizing u-boot includes causes problems when trying to migrate
> > > > boards to OF_UPSTREAM that have different local devicetree files with
> > > > respect to the upstream ones, if local DT headers are not dropped.
> > > > At the same time if local and upstream files are the same, migrations
> > > > can be, and have been, introduced without dropping local DT headers.
> > > > This also causes problems whenever upstream DTS and DT headers are patched.
> > > >
> > > > For example, now migrating a board based on `imx6ul.dtsi` to OF_UPSTREAM
> > > > breaks it, as there are some missing defines in a local DT header file
> > > > (`imx6ul-clock.h`); the solution would be to drop it, which has not always
> > > > been done in previous OF_UPSTREAM migration patches for other boards
> > > > because most of the time the two are the same. This solution is also
> > > > vulnerable to ABI breakage, although this has not yet happened since the
> > > > introduction of OF_UPSTREAM support and is unlikely.
> > > >
> > > > Maintainers assure backwards compatibility for DT headers when syncing the
> > > > upstream folder with the kernel.
> > > > The problem is that, at the current state, all boards that have not dropped
> > > > their local headers when migrating to OF_UPSTREAM will break once the
> > > > upstream devicetrees are patched, for example, to use any newly added
> > > > define which is not present in the local DT header file, even if those
> > > > changes are backwards compatible.
> > > >
> > > > This patch fixes these problems by prioritizing upstream includes when
> > > > `CONFIG_OF_UPSTREAM=y`, while keeping current prioritization when it is
> > > > not.
> > >
> > > Do you have some comments here? We would like to move upstream dts for
> > > imx6 boards
> > > too
> >
> > I've been waiting for the people that wanted the commit message
> > clarified to Ack/Review the patch. Did I just miss that? Sorry.
> >
>
> Agreed, let's wait for more feedback

I have migrated to OF_UPSTREAM for ARCH_KIRWOOD boards, and also for a
single board (DS116, Armada 385), and have given a lot of thoughts
about this problem. I agreed with Michael. Either the whole Arch is
migrated at the same time, or we need to prioritize upstream includes
to avoid breakage for boards that have been migrated and also boards
that have not been.

Reviewed-by: Tony Dinh <mibodhi at gmail.com>

All the best,
Tony

>
> Michael
>
> > --
> > Tom


More information about the U-Boot mailing list