u-boot/include/dm
Patrick Delaunay ce891fcada dm: core: add ofnode and dev function to iterate on node property
Add functions to iterate on all property with livetree
- dev_read_first_prop
- dev_read_next_prop
- dev_read_prop_by_prop
and
- ofnode_get_first_property
- ofnode_get_next_property
- ofnode_get_property_by_prop

And helper: dev_for_each_property

For example:
struct ofprop property;

dev_for_each_property(property, config) {
	value = dev_read_prop_by_prop(&property, &propname, &len);

or:

for (res = ofnode_get_first_property(node, &property);
     !res;
     res = ofnode_get_next_property(&property))
{
     value = ofnode_get_property_by_prop(&property, &propname, &len);
....
}

Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2020-04-16 23:06:54 -04:00
..
platform_data serial: stm32: remove unused include 2019-08-27 11:19:23 +02:00
acpi.h acpi: Add an __ACPI__ preprocessor symbol 2020-04-16 14:36:28 +08:00
device_compat.h dm: core: Create a new header file for 'compat' features 2020-02-05 19:33:46 -07:00
device-internal.h dm: core: Export a new function to read platdata 2020-01-07 16:02:38 -07:00
device.h Functions for reading indexed values from device tree 2020-04-16 13:45:03 -04:00
devres.h dm: core: Require users of devres to include the header 2020-02-05 19:33:46 -07:00
fdtaddr.h dm: core: Use const device for the devfdt...() interface 2020-02-05 19:33:45 -07:00
lists.h dm: Correct pre_reloc_only parameter description in several APIs' comments 2018-11-14 09:16:27 -08:00
of_access.h dm: core: add ofnode and dev function to iterate on node property 2020-04-16 23:06:54 -04:00
of_addr.h dm: core: Introduce xxx_translate_dma_address() 2019-07-22 09:21:28 +02:00
of_extra.h dm: core: Update ofnode to read binman-style flash entry 2018-10-09 04:40:27 -06:00
of.h dm: Fix default address cells return value 2019-10-15 08:40:02 -06:00
ofnode.h dm: core: add ofnode and dev function to iterate on node property 2020-04-16 23:06:54 -04:00
pci.h dm: pci: Move pci_get_devfn() into a common file 2019-12-15 08:52:29 +08:00
pinctrl.h pinctrol: dm: remove the function pinctrl_decode_pin_config 2019-11-14 07:09:34 -06:00
platdata.h SPDX: Convert all of our single license tags to Linux Kernel style 2018-05-07 09:34:12 -04:00
read.h dm: core: add ofnode and dev function to iterate on node property 2020-04-16 23:06:54 -04:00
root.h dm: Correct pre_reloc_only parameter description in several APIs' comments 2018-11-14 09:16:27 -08:00
test.h dm: core: Add a function to find a device by drvdata 2020-02-07 22:41:24 +08:00
uclass-id.h acpi: Add a simple sandbox test 2020-04-16 14:36:28 +08:00
uclass-internal.h dm: core: Correct the return value for uclass_find_first_device() 2019-10-08 13:57:38 +08:00
uclass.h dm: core: Add a function to find a device by drvdata 2020-02-07 22:41:24 +08:00
util.h dm: core: remove the duplicated function dm_ofnode_pre_reloc 2020-04-16 08:07:58 -06:00