U-Boot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Anshul Dalal <anshuld@ti.com>
To: Anshul Dalal <anshuld@ti.com>,
	Quentin Schulz <quentin.schulz@cherry.de>,
	 <u-boot@lists.denx.de>, <u-boot@lists.u-boot-project.org>
Cc: Tom Rini <trini@konsulko.com>, Simon Glass <sjg@chromium.org>,
	Moteen Shah <m-shah@ti.com>
Subject: Re: [PATCH v3] fdt: Fix phandles not copying when using templates
Date: Mon, 24 Aug 2026 12:36:55 +0530	[thread overview]
Message-ID: <DKWZFTIBMBBL.2XN2NB4O63S6@ti.com> (raw)
In-Reply-To: <DKL91OUU5LDQ.V2B9UQREH116@ti.com>

I guess this reply got dropped due to the list migration, just a gentle
ping to ask if everyone's okay with this change.

Thanks!

On Mon Aug 10, 2026 at 5:36 PM IST, Anshul Dalal wrote:
> On Wed Jul 29, 2026 at 4:12 PM IST, Quentin Schulz wrote:
>> Hi Anshul,
>>
>> On 7/29/26 12:24 PM, Anshul Dalal wrote:
>>> The phandles used inside a template are not copied to the node inserting
>>> the template, leading to a missing phandle error.
>>> 
>>> The following example can be used to reproduce the issue:
>>> 
>>> &binman {
>>>    some_template: template-0 {
>>>      ti-secure-rom {
>>>        content = <&some_data>;
>>>        keyfile = "some_key";
>>>      };
>>>      some_data: blob-ext {
>>>        optional;
>>>      };
>>>    };
>>>    output-bin {
>>>      insert-template = <&some_template>;
>>>    };
>>> };
>>> 
>>
>> What happens if you insert the template *twice*.
>>
>> e.g. have:
>>
>>   &binman {
>>      some_template: template-0 {
>>        ti-secure-rom {
>>          content = <&some_data>;
>>          keyfile = "some_key";
>>        };
>>        some_data: blob-ext {
>>          optional;
>>        };
>>      };
>>      output-bin {
>>        insert-template = <&some_template>;
>>      };
>>      output-bin2 {
>>        insert-template = <&some_template>;
>>      };
>>   };
>>
>> ? Gut feeling is that this will fail to build because we now have the 
>> same label for two different nodes.
>
> Yes, it will cause a failure due to duplicated phandles. And as per the
> docs[1], it seems to be an expected qwirk of how templates work.
>
> [1]: https://docs.u-boot.org/en/v2026.04/develop/package/binman.html#dealing-with-phandles
>
> Regards,
> Anshul


  parent reply	other threads:[~2026-08-24  7:07 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-29 10:24 [PATCH v3] fdt: Fix phandles not copying when using templates Anshul Dalal
2026-07-29 10:42 ` Quentin Schulz
     [not found]   ` <DKL91OUU5LDQ.V2B9UQREH116@ti.com>
2026-08-24  7:06     ` Anshul Dalal [this message]
2026-08-08 17:33 ` Simon Glass
2026-08-28 18:07 ` Tom Rini

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=DKWZFTIBMBBL.2XN2NB4O63S6@ti.com \
    --to=anshuld@ti.com \
    --cc=m-shah@ti.com \
    --cc=quentin.schulz@cherry.de \
    --cc=sjg@chromium.org \
    --cc=trini@konsulko.com \
    --cc=u-boot@lists.denx.de \
    --cc=u-boot@lists.u-boot-project.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox