|
@@ -136,6 +136,28 @@ uint32_t fdt_next_tag(const void *fdt, int offset, int *nextoffset);
|
|
|
|
|
|
int fdt_next_node(const void *fdt, int offset, int *depth);
|
|
int fdt_next_node(const void *fdt, int offset, int *depth);
|
|
|
|
|
|
|
|
+/**
|
|
|
|
+ * fdt_first_subnode() - get offset of first direct subnode
|
|
|
|
+ *
|
|
|
|
+ * @fdt: FDT blob
|
|
|
|
+ * @offset: Offset of node to check
|
|
|
|
+ * @return offset of first subnode, or -FDT_ERR_NOTFOUND if there is none
|
|
|
|
+ */
|
|
|
|
+int fdt_first_subnode(const void *fdt, int offset);
|
|
|
|
+
|
|
|
|
+/**
|
|
|
|
+ * fdt_next_subnode() - get offset of next direct subnode
|
|
|
|
+ *
|
|
|
|
+ * After first calling fdt_first_subnode(), call this function repeatedly to
|
|
|
|
+ * get direct subnodes of a parent node.
|
|
|
|
+ *
|
|
|
|
+ * @fdt: FDT blob
|
|
|
|
+ * @offset: Offset of previous subnode
|
|
|
|
+ * @return offset of next subnode, or -FDT_ERR_NOTFOUND if there are no more
|
|
|
|
+ * subnodes
|
|
|
|
+ */
|
|
|
|
+int fdt_next_subnode(const void *fdt, int offset);
|
|
|
|
+
|
|
/**********************************************************************/
|
|
/**********************************************************************/
|
|
/* General functions */
|
|
/* General functions */
|
|
/**********************************************************************/
|
|
/**********************************************************************/
|