[PATCH] of_property and phandles

Sascha Hauer s.hauer at pengutronix.de
Wed Aug 14 04:11:18 EDT 2013


This adds the support for phandles to the of_property command.

The of_property command is able to manipulate devicetree properties,
but so far it hasn't been able to specify phandles. With this
series the following is possible:

of_property -s /soc/somenode propname </soc/someothernode 0xdeadbeef>

The /soc/someothernode is inserted into the property as phandle.

The projected usecase currently is to chose a display out of several
possible during runtime.

Sascha

----------------------------------------------------------------
Sascha Hauer (7):
      of: fix merge mode in of_unflatten_dtb
      of: parse phandles during unflatten
      of: default to internal tree in of_find_node_by_path_from
      of: introduce some new helpers
      of_property command: allow to specify a node by alias
      of_property command: allow to set phandles
      oftree command: Allow to specify node by alias

 commands/of_property.c |  36 ++++++++++++--
 commands/oftree.c      |   2 +-
 drivers/of/base.c      | 126 ++++++++++++++++++++++++++++++++++++++++++-------
 drivers/of/fdt.c       |   5 +-
 include/of.h           |  14 ++++++
 5 files changed, 160 insertions(+), 23 deletions(-)



More information about the barebox mailing list