summaryrefslogtreecommitdiff
path: root/arch/powerpc/kernel/prom.c
diff options
context:
space:
mode:
authorStephen Rothwell <sfr@canb.auug.org.au>2007-04-24 07:16:16 (GMT)
committerStephen Rothwell <sfr@canb.auug.org.au>2007-07-20 03:32:58 (GMT)
commite679c5f445fe142940e0962de9c5c82f10d9357c (patch)
tree997daf76cc643fdc495ce0a667cfdc5b1c9515ab /arch/powerpc/kernel/prom.c
parent581b605a83ec241a2aff8ef780e08b9414c8dfd8 (diff)
downloadlinux-fsl-qoriq-e679c5f445fe142940e0962de9c5c82f10d9357c.tar.xz
Consolidate of_get_parent
This requires creating dummy of_node_{get,put} routines for sparc and sparc64. It also adds a read_lock around the parent accesses. Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au> Acked-by: Paul Mackerras <paulus@samba.org> Acked-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch/powerpc/kernel/prom.c')
-rw-r--r--arch/powerpc/kernel/prom.c21
1 files changed, 0 insertions, 21 deletions
diff --git a/arch/powerpc/kernel/prom.c b/arch/powerpc/kernel/prom.c
index 3f6238d..1ad56d3 100644
--- a/arch/powerpc/kernel/prom.c
+++ b/arch/powerpc/kernel/prom.c
@@ -1241,27 +1241,6 @@ struct device_node *of_find_all_nodes(struct device_node *prev)
EXPORT_SYMBOL(of_find_all_nodes);
/**
- * of_get_parent - Get a node's parent if any
- * @node: Node to get parent
- *
- * Returns a node pointer with refcount incremented, use
- * of_node_put() on it when done.
- */
-struct device_node *of_get_parent(const struct device_node *node)
-{
- struct device_node *np;
-
- if (!node)
- return NULL;
-
- read_lock(&devtree_lock);
- np = of_node_get(node->parent);
- read_unlock(&devtree_lock);
- return np;
-}
-EXPORT_SYMBOL(of_get_parent);
-
-/**
* of_get_next_child - Iterate a node childs
* @node: parent node
* @prev: previous child of the parent node, or NULL to get first