Re: [PATCH v2] fdtoverlay: Remove bogus type info from help text

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



Uwe's Pengutronix email is bouncing, so switched to kernel.org acct.

+dtc list

On Fri, May 31, 2024 at 9:38 AM Rob Herring <robh@xxxxxxxxxx> wrote:
>
> On Fri, May 31, 2024 at 9:07 AM Geert Uytterhoeven <geert@xxxxxxxxxxxxxx> wrote:
> >
> > Hi Rob,
> >
> > On Fri, May 31, 2024 at 3:43 PM Rob Herring <robh@xxxxxxxxxx> wrote:
> > > On Thu, May 30, 2024 at 8:32 AM Geert Uytterhoeven <geert@xxxxxxxxxxxxxx> wrote:
> > > > On Thu, May 30, 2024 at 2:31 PM Rob Herring <robh@xxxxxxxxxx> wrote:
> > > > > On Wed, May 29, 2024 at 5:11 AM Geert Uytterhoeven
> > > > > <geert+renesas@xxxxxxxxx> wrote:
> > > > > >
> > > > > > "fdtoverlay -h" shows a.o.:
> > > > > >
> > > > > >     <type>      s=string, i=int, u=unsigned, x=hex
> > > > > >             Optional modifier prefix:
> > > > > >                     hh or b=byte, h=2 byte, l=4 byte (default)
> > > > > >
> > > > > > However, unlike fdtget and fdtput, fdtoverlay does not support the
> > > > > > "-t"/"--type" option.
> > > > > >
> > > > > > Signed-off-by: Geert Uytterhoeven <geert+renesas@xxxxxxxxx>
> > > > > > ---
> > > > > > Upstream dtc has Uwe's commit 2cdf93a6d402a161 ("fdtoverlay: Fix usage
> > > > > > string to not mention "<type>"").
> > > > >
> > > > > So you want me to sync upstream? That's how upstream commits get into
> > > > > the kernel. I don't take patches (unless there's some urgent
> > > > > breakage).
> > > >
> > > > If that's the policy, then yes please ;-)
> > >
> > > With current dtc main branch, I get these errors:
> > >
> > > Failed to apply
> > > 'arch/arm64/boot/dts/renesas/salvator-panel-aa104xd12.dtbo':
> > > FDT_ERR_NOTFOUND
> >
> > Interesting...
> >
> > Do you know what's the problem?
>
> No. Since it is conveniently platforms you care about, I thought I'd
> leave it to you. ;)
>
> Well, it seems that if I use the upstream built dtc and fdtoverlay it
> works fine. Using the one in scripts/dtc/ doesn't. Looks like that
> issue is on me...

I figured out the difference. The dtc tree build of fdtoverlay is
picking up the libfdt installed on my system. The kernel tree build is
statically linked.

A bisect points to this commit:

commit 1fad065080e6cae0ec1a4ad6288733cd24c103f9
Author: Uwe Kleine-König <u.kleine-koenig@xxxxxxxxxxxxxx>
Date:   Sun Feb 25 18:54:23 2024 +0100

    libfdt: overlay: ensure that existing phandles are not overwritten

    A phandle in an overlay is not supposed to overwrite a phandle that
    already exists in the base dtb as this breaks references to the
    respective node in the base.

    So add another iteration over the fdto that checks for such overwrites
    and fixes the fdto phandle's value to match the fdt's.

    A test is added that checks that newly added phandles and existing
    phandles work as expected.

    Signed-off-by: Uwe Kleine-König <u.kleine-koenig@xxxxxxxxxxxxxx>
    Message-ID: <20240225175422.156393-2-u.kleine-koenig@xxxxxxxxxxxxxx>
    Signed-off-by: David Gibson <david@xxxxxxxxxxxxxxxxxxxxx>

 libfdt/fdt_overlay.c              | 251 ++++++++++++++++++++++++++++++++++++++
 tests/overlay_base_phandle.dts    |  21 ++++
 tests/overlay_overlay_phandle.dts |  34 ++++++
 tests/run_tests.sh                |  28 +++++
 4 files changed, 334 insertions(+)
 create mode 100644 tests/overlay_base_phandle.dts
 create mode 100644 tests/overlay_overlay_phandle.dts

Rob





[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