summaryrefslogtreecommitdiff
path: root/include/dm/ofnode.h
diff options
context:
space:
mode:
authorTom Rini <[email protected]>2021-07-05 11:20:30 -0400
committerTom Rini <[email protected]>2021-07-05 11:20:30 -0400
commit6194b45a83bde42cd2f404123823e5b326702001 (patch)
treeeef0284dfb378d20ee3a21577d3f7abb4f127fd5 /include/dm/ofnode.h
parent840658b093976390e9537724f802281c9c8439f5 (diff)
parent03b61ffe5a780d6e8301df16e4e60b3dcd1d0b66 (diff)
Merge branch 'next'
Diffstat (limited to 'include/dm/ofnode.h')
-rw-r--r--include/dm/ofnode.h27
1 files changed, 27 insertions, 0 deletions
diff --git a/include/dm/ofnode.h b/include/dm/ofnode.h
index 8a69fd87da7..3da05d8b217 100644
--- a/include/dm/ofnode.h
+++ b/include/dm/ofnode.h
@@ -459,6 +459,16 @@ ofnode ofnode_get_parent(ofnode node);
const char *ofnode_get_name(ofnode node);
/**
+ * ofnode_get_path() - get the full path of a node
+ *
+ * @node: valid node to look up
+ * @buf: buffer to write the node path into
+ * @buflen: buffer size
+ * @return 0 if OK, -ve on error
+ */
+int ofnode_get_path(ofnode node, char *buf, int buflen);
+
+/**
* ofnode_get_by_phandle() - get ofnode from phandle
*
* @phandle: phandle to look up
@@ -490,6 +500,23 @@ phys_addr_t ofnode_get_addr_size_index(ofnode node, int index,
fdt_size_t *size);
/**
+ * ofnode_get_addr_size_index_notrans() - get an address/size from a node
+ * based on index, without address
+ * translation
+ *
+ * This reads the register address/size from a node based on index.
+ * The resulting address is not translated. Useful for example for on-disk
+ * addresses.
+ *
+ * @node: node to read from
+ * @index: Index of address to read (0 for first)
+ * @size: Pointer to size of the address
+ * @return address, or FDT_ADDR_T_NONE if not present or invalid
+ */
+phys_addr_t ofnode_get_addr_size_index_notrans(ofnode node, int index,
+ fdt_size_t *size);
+
+/**
* ofnode_get_addr_index() - get an address from a node
*
* This reads the register address from a node