mail archive of the barebox mailing list
 help / color / mirror / Atom feed
* [PATCH 0/1] of_property: resolve phandles against the booted device tree
@ 2026-11-13 11:55 Primoz Fiser
  2026-11-13 11:55 ` [PATCH 1/1] commands: of_property: resolve phandles of fixups in the booted tree Primoz Fiser
  2026-11-17  8:44 ` [PATCH 0/1] of_property: resolve phandles against the booted device tree Sascha Hauer
  0 siblings, 2 replies; 4+ messages in thread
From: Primoz Fiser @ 2026-11-13 11:55 UTC (permalink / raw)
  To: barebox

Hi,

I ran into this on a phyBOARD-Mira (i.MX6) secure boot setup. Two board
expansions configure a UART pin group via a fixup along these lines:

  of_property -s -f -e $global.bootm.oftree /soc/.../serial@21ec000 \
      pinctrl-0 </soc/.../pinctrl@20e0000/uart3grp>

The node path is resolved to a phandle immediately, against the
external dtb named by -e. With secure boot the kernel device tree is
part of the FIT image, so that file never exists on disk: of_property
fails, the fixup is never registered, and the UART keeps its default
pin group, which conflicts with other pins on the board (user LEDs,
in this case).

The patch defers phandle resolution to the point the fixup is applied,
against the tree that is actually being booted, so -e is no longer
needed for this and is now ignored (rather than required) when
combined with -f. Existing scripts that still pass -e keep working.

With this applied, setups like the one above can drop the
-e $global.bootm.oftree workaround entirely.

Primoz Fiser (1):
  commands: of_property: resolve phandles of fixups in the booted tree

 commands/of_property.c | 75 ++++++++++++++++++++++++++++--------------
 1 file changed, 51 insertions(+), 24 deletions(-)

-- 
2.34.1




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

end of thread, other threads:[~2026-11-17 10:25 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-11-13 11:55 [PATCH 0/1] of_property: resolve phandles against the booted device tree Primoz Fiser
2026-11-13 11:55 ` [PATCH 1/1] commands: of_property: resolve phandles of fixups in the booted tree Primoz Fiser
2026-11-17  8:23   ` Sascha Hauer
2026-11-17  8:44 ` [PATCH 0/1] of_property: resolve phandles against the booted device tree Sascha Hauer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox