summaryrefslogtreecommitdiffstats
path: root/arch/sparc/kernel/prom_64.c
diff options
context:
space:
mode:
authorRob Herring <robh@kernel.org>2018-11-16 22:06:58 +0100
committerDavid S. Miller <davem@davemloft.net>2018-11-18 22:35:21 +0100
commit29c990dfc77c58b21a0f2ff4640b6a26955d0661 (patch)
treedefc761de237c9456c793e485c00a247ea5ab795 /arch/sparc/kernel/prom_64.c
parentsparc: Convert to using %pOFn instead of device_node.name (diff)
downloadlinux-29c990dfc77c58b21a0f2ff4640b6a26955d0661.tar.xz
linux-29c990dfc77c58b21a0f2ff4640b6a26955d0661.zip
sparc: Use of_node_name_eq for node name comparisons
Convert string compares of DT node names to use of_node_name_eq helper instead. This removes direct access to the node name pointer. Cc: "David S. Miller" <davem@davemloft.net> Cc: sparclinux@vger.kernel.org Signed-off-by: Rob Herring <robh@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch/sparc/kernel/prom_64.c')
-rw-r--r--arch/sparc/kernel/prom_64.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/sparc/kernel/prom_64.c b/arch/sparc/kernel/prom_64.c
index 1667df573f6f..17860d6ed1bd 100644
--- a/arch/sparc/kernel/prom_64.c
+++ b/arch/sparc/kernel/prom_64.c
@@ -335,8 +335,8 @@ static void __init __build_path_component(struct device_node *dp, char *tmp_buf)
ebus_path_component(dp, tmp_buf);
return;
}
- if (!strcmp(parent->name, "usb") ||
- !strcmp(parent->name, "hub")) {
+ if (of_node_name_eq(parent, "usb") ||
+ of_node_name_eq(parent, "hub")) {
usb_path_component(dp, tmp_buf);
return;
}