All of lore.kernel.org
 help / color / mirror / Atom feed
* Applying dtb overlays on pre-compiled dtb's
@ 2023-02-27 14:25 Igor Opaniuk
       [not found] ` <CAL6CDMFiV0_rmE+gTow0X7Wnj7eS6YDu0Ya7dmNACnL1rRy4_w-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
  0 siblings, 1 reply; 3+ messages in thread
From: Igor Opaniuk @ 2023-02-27 14:25 UTC (permalink / raw)
  To: devicetree-compiler-u79uwXL29TY76Z2rM5mHXA

Hi everyone,

I apologize in advance for the possibly wrong ML for this question.

I'm currently looking for any existing ways of adjusting pre-compiled device
tree blobs. I know that dtc doesn't have such ability (and obviously its purpose
is different), but maybe there is something you can recommend in this case
(kind of userland analogy of U-Boot's runtime "fdt apply" cmd).

For instance, I would like to add one property to "/firmware" (its value
 is generated during compile time) node into multiple device tree
blobs built with-in
Linux/U-Boot/TF-A, avoiding any additional intrusive changes to these source
trees (so, for example, adding dtsi with needed firmware property
unfortunately doesn't work for me).

The only solution I see is a custom app that uses libfdt, implemented
specifically
for this task, but maybe there is something which already exists.

Thanks and looking forward to your replies.

-- 
Best regards - Freundliche Grüsse - Meilleures salutations

Igor Opaniuk
Embedded Software Engineer
T:  +380 938364067
E: igor.opaniuk-WQOgUJUq/S3vYQKSrp0J2Q@public.gmane.org
W: www.foundries.io

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Applying dtb overlays on pre-compiled dtb's
       [not found] ` <CAL6CDMFiV0_rmE+gTow0X7Wnj7eS6YDu0Ya7dmNACnL1rRy4_w-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
@ 2023-02-27 16:17   ` Simon Glass
  2023-02-27 16:47   ` Rob Herring
  1 sibling, 0 replies; 3+ messages in thread
From: Simon Glass @ 2023-02-27 16:17 UTC (permalink / raw)
  To: Igor Opaniuk; +Cc: devicetree-compiler-u79uwXL29TY76Z2rM5mHXA

Hi Igor,

On Mon, 27 Feb 2023 at 07:26, Igor Opaniuk <igor.opaniuk-WQOgUJUq/S3vYQKSrp0J2Q@public.gmane.org> wrote:
>
> Hi everyone,
>
> I apologize in advance for the possibly wrong ML for this question.
>
> I'm currently looking for any existing ways of adjusting pre-compiled device
> tree blobs. I know that dtc doesn't have such ability (and obviously its purpose
> is different), but maybe there is something you can recommend in this case
> (kind of userland analogy of U-Boot's runtime "fdt apply" cmd).
>
> For instance, I would like to add one property to "/firmware" (its value
>  is generated during compile time) node into multiple device tree
> blobs built with-in
> Linux/U-Boot/TF-A, avoiding any additional intrusive changes to these source
> trees (so, for example, adding dtsi with needed firmware property
> unfortunately doesn't work for me).
>
> The only solution I see is a custom app that uses libfdt, implemented
> specifically
> for this task, but maybe there is something which already exists.

There is fdtput which can add simple properties and nodes.

I suppose you are aware of binman[1], which might be useful if your
signing/production scheme were supported there.

>
> Thanks and looking forward to your replies.
>
> --
> Best regards - Freundliche Grüsse - Meilleures salutations
>
> Igor Opaniuk
> Embedded Software Engineer
> T:  +380 938364067
> E: igor.opaniuk-WQOgUJUq/S3vYQKSrp0J2Q@public.gmane.org
> W: www.foundries.io

Regards,
Simon

[1] https://u-boot.readthedocs.io/en/latest/develop/package/binman.html
 (pip install binary-manager)

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Applying dtb overlays on pre-compiled dtb's
       [not found] ` <CAL6CDMFiV0_rmE+gTow0X7Wnj7eS6YDu0Ya7dmNACnL1rRy4_w-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
  2023-02-27 16:17   ` Simon Glass
@ 2023-02-27 16:47   ` Rob Herring
  1 sibling, 0 replies; 3+ messages in thread
From: Rob Herring @ 2023-02-27 16:47 UTC (permalink / raw)
  To: Igor Opaniuk; +Cc: devicetree-compiler-u79uwXL29TY76Z2rM5mHXA

On Mon, Feb 27, 2023 at 8:25 AM Igor Opaniuk <igor.opaniuk@foundries.io> wrote:
>
> Hi everyone,
>
> I apologize in advance for the possibly wrong ML for this question.
>
> I'm currently looking for any existing ways of adjusting pre-compiled device
> tree blobs. I know that dtc doesn't have such ability (and obviously its purpose
> is different), but maybe there is something you can recommend in this case
> (kind of userland analogy of U-Boot's runtime "fdt apply" cmd).

fdtoverlay (in dtc) is the Linux CLI equivalent (and same underlying
implementation).

Rob

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2023-02-27 16:47 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-02-27 14:25 Applying dtb overlays on pre-compiled dtb's Igor Opaniuk
     [not found] ` <CAL6CDMFiV0_rmE+gTow0X7Wnj7eS6YDu0Ya7dmNACnL1rRy4_w-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2023-02-27 16:17   ` Simon Glass
2023-02-27 16:47   ` Rob Herring

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.