]> Git Repo - qemu.git/commitdiff
device tree: add nop_node
authorAlexander Graf <[email protected]>
Wed, 20 Jul 2011 23:52:57 +0000 (01:52 +0200)
committerAlexander Graf <[email protected]>
Thu, 6 Oct 2011 07:43:34 +0000 (09:43 +0200)
We have a qemu internal abstraction layer on FDT. While I'm not fully convinced
we need it at all, it's missing the nop_node functionality that we now need
on e500. So let's add it and think about the general future of that API later.

Signed-off-by: Alexander Graf <[email protected]>
device_tree.c
device_tree.h

index 3a224d1e0fe6e02bb9925610e987ac58c4144243..23e89e3b90286d12c3fbe237f8de7341c600d5a2 100644 (file)
@@ -107,3 +107,14 @@ int qemu_devtree_setprop_string(void *fdt, const char *node_path,
 
     return fdt_setprop_string(fdt, offset, property, string);
 }
+
+int qemu_devtree_nop_node(void *fdt, const char *node_path)
+{
+    int offset;
+
+    offset = fdt_path_offset(fdt, node_path);
+    if (offset < 0)
+        return offset;
+
+    return fdt_nop_node(fdt, offset);
+}
index cecd98f0422ff2483ab823a0e1272051df6d2b5d..76fce5ffb2bba4073f54915fd100a954a99f3e62 100644 (file)
@@ -22,5 +22,6 @@ int qemu_devtree_setprop_cell(void *fdt, const char *node_path,
                               const char *property, uint32_t val);
 int qemu_devtree_setprop_string(void *fdt, const char *node_path,
                                 const char *property, const char *string);
+int qemu_devtree_nop_node(void *fdt, const char *node_path);
 
 #endif /* __DEVICE_TREE_H__ */
This page took 0.025202 seconds and 4 git commands to generate.