pub unsafe extern "C" fn fdt_parent_offset(
fdt: *const c_void,
nodeoffset: c_int,
) -> c_intExpand description
fdt_parent_offset - find the parent of a given node @fdt: pointer to the device tree blob @nodeoffset: offset of the node whose parent to find
fdt_parent_offset() locates the parent node of a given node (that is, it finds the offset of the node which contains the node at nodeoffset as a subnode).
NOTE: This function is expensive, as it must scan the device tree structure from the start to nodeoffset, twice.
returns: structure block offset of the parent of the node at nodeoffset (>=0), on success -FDT_ERR_BADOFFSET, nodeoffset does not refer to a BEGIN_NODE tag -FDT_ERR_BADMAGIC, -FDT_ERR_BADVERSION, -FDT_ERR_BADSTATE, -FDT_ERR_BADSTRUCTURE, standard meanings