Commit 9475e90f authored by Rob Herring's avatar Rob Herring Committed by Paul Burton

MIPS: Convert to using %pOFn instead of device_node.name

In preparation to remove the node name pointer from struct device_node,
convert printf users to use the %pOFn format specifier.
Signed-off-by: default avatarRob Herring <robh@kernel.org>
Signed-off-by: default avatarPaul Burton <paul.burton@mips.com>
Patchwork: https://patchwork.linux-mips.org/patch/20315/
Cc: Ralf Baechle <ralf@linux-mips.org>
Cc: James Hogan <jhogan@kernel.org>
Cc: John Crispin <john@phrozen.org>
Cc: linux-mips@linux-mips.org
Cc: linux-kernel@vger.kernel.org
parent 33f2ac54
...@@ -1180,8 +1180,8 @@ static int octeon_irq_gpio_xlat(struct irq_domain *d, ...@@ -1180,8 +1180,8 @@ static int octeon_irq_gpio_xlat(struct irq_domain *d,
type = IRQ_TYPE_LEVEL_LOW; type = IRQ_TYPE_LEVEL_LOW;
break; break;
default: default:
pr_err("Error: (%s) Invalid irq trigger specification: %x\n", pr_err("Error: (%pOFn) Invalid irq trigger specification: %x\n",
node->name, node,
trigger); trigger);
type = IRQ_TYPE_LEVEL_LOW; type = IRQ_TYPE_LEVEL_LOW;
break; break;
...@@ -2271,8 +2271,8 @@ static int __init octeon_irq_init_cib(struct device_node *ciu_node, ...@@ -2271,8 +2271,8 @@ static int __init octeon_irq_init_cib(struct device_node *ciu_node,
parent_irq = irq_of_parse_and_map(ciu_node, 0); parent_irq = irq_of_parse_and_map(ciu_node, 0);
if (!parent_irq) { if (!parent_irq) {
pr_err("ERROR: Couldn't acquire parent_irq for %s\n", pr_err("ERROR: Couldn't acquire parent_irq for %pOFn\n",
ciu_node->name); ciu_node);
return -EINVAL; return -EINVAL;
} }
...@@ -2283,7 +2283,7 @@ static int __init octeon_irq_init_cib(struct device_node *ciu_node, ...@@ -2283,7 +2283,7 @@ static int __init octeon_irq_init_cib(struct device_node *ciu_node,
addr = of_get_address(ciu_node, 0, NULL, NULL); addr = of_get_address(ciu_node, 0, NULL, NULL);
if (!addr) { if (!addr) {
pr_err("ERROR: Couldn't acquire reg(0) %s\n", ciu_node->name); pr_err("ERROR: Couldn't acquire reg(0) %pOFn\n", ciu_node);
return -EINVAL; return -EINVAL;
} }
host_data->raw_reg = (u64)phys_to_virt( host_data->raw_reg = (u64)phys_to_virt(
...@@ -2291,7 +2291,7 @@ static int __init octeon_irq_init_cib(struct device_node *ciu_node, ...@@ -2291,7 +2291,7 @@ static int __init octeon_irq_init_cib(struct device_node *ciu_node,
addr = of_get_address(ciu_node, 1, NULL, NULL); addr = of_get_address(ciu_node, 1, NULL, NULL);
if (!addr) { if (!addr) {
pr_err("ERROR: Couldn't acquire reg(1) %s\n", ciu_node->name); pr_err("ERROR: Couldn't acquire reg(1) %pOFn\n", ciu_node);
return -EINVAL; return -EINVAL;
} }
host_data->en_reg = (u64)phys_to_virt( host_data->en_reg = (u64)phys_to_virt(
...@@ -2299,8 +2299,8 @@ static int __init octeon_irq_init_cib(struct device_node *ciu_node, ...@@ -2299,8 +2299,8 @@ static int __init octeon_irq_init_cib(struct device_node *ciu_node,
r = of_property_read_u32(ciu_node, "cavium,max-bits", &val); r = of_property_read_u32(ciu_node, "cavium,max-bits", &val);
if (r) { if (r) {
pr_err("ERROR: Couldn't read cavium,max-bits from %s\n", pr_err("ERROR: Couldn't read cavium,max-bits from %pOFn\n",
ciu_node->name); ciu_node);
return r; return r;
} }
host_data->max_bits = val; host_data->max_bits = val;
......
...@@ -291,7 +291,7 @@ static int __init xlp_of_pic_init(struct device_node *node, ...@@ -291,7 +291,7 @@ static int __init xlp_of_pic_init(struct device_node *node,
/* we need a hack to get the PIC's SoC chip id */ /* we need a hack to get the PIC's SoC chip id */
ret = of_address_to_resource(node, 0, &res); ret = of_address_to_resource(node, 0, &res);
if (ret < 0) { if (ret < 0) {
pr_err("PIC %s: reg property not found!\n", node->name); pr_err("PIC %pOFn: reg property not found!\n", node);
return -EINVAL; return -EINVAL;
} }
...@@ -304,21 +304,21 @@ static int __init xlp_of_pic_init(struct device_node *node, ...@@ -304,21 +304,21 @@ static int __init xlp_of_pic_init(struct device_node *node,
break; break;
} }
if (socid == NLM_NR_NODES) { if (socid == NLM_NR_NODES) {
pr_err("PIC %s: Node mapping for bus %d not found!\n", pr_err("PIC %pOFn: Node mapping for bus %d not found!\n",
node->name, bus); node, bus);
return -EINVAL; return -EINVAL;
} }
} else { } else {
socid = (res.start >> 18) & 0x3; socid = (res.start >> 18) & 0x3;
if (!nlm_node_present(socid)) { if (!nlm_node_present(socid)) {
pr_err("PIC %s: node %d does not exist!\n", pr_err("PIC %pOFn: node %d does not exist!\n",
node->name, socid); node, socid);
return -EINVAL; return -EINVAL;
} }
} }
if (!nlm_node_present(socid)) { if (!nlm_node_present(socid)) {
pr_err("PIC %s: node %d does not exist!\n", node->name, socid); pr_err("PIC %pOFn: node %d does not exist!\n", node, socid);
return -EINVAL; return -EINVAL;
} }
...@@ -326,7 +326,7 @@ static int __init xlp_of_pic_init(struct device_node *node, ...@@ -326,7 +326,7 @@ static int __init xlp_of_pic_init(struct device_node *node,
nlm_irq_to_xirq(socid, PIC_IRQ_BASE), PIC_IRQ_BASE, nlm_irq_to_xirq(socid, PIC_IRQ_BASE), PIC_IRQ_BASE,
&xlp_pic_irq_domain_ops, NULL); &xlp_pic_irq_domain_ops, NULL);
if (xlp_pic_domain == NULL) { if (xlp_pic_domain == NULL) {
pr_err("PIC %s: Creating legacy domain failed!\n", node->name); pr_err("PIC %pOFn: Creating legacy domain failed!\n", node);
return -EINVAL; return -EINVAL;
} }
pr_info("Node %d: IRQ domain created for PIC@%pR\n", socid, &res); pr_info("Node %d: IRQ domain created for PIC@%pR\n", socid, &res);
......
...@@ -134,7 +134,7 @@ static int __init ralink_systick_init(struct device_node *np) ...@@ -134,7 +134,7 @@ static int __init ralink_systick_init(struct device_node *np)
systick.dev.min_delta_ticks = 0x3; systick.dev.min_delta_ticks = 0x3;
systick.dev.irq = irq_of_parse_and_map(np, 0); systick.dev.irq = irq_of_parse_and_map(np, 0);
if (!systick.dev.irq) { if (!systick.dev.irq) {
pr_err("%s: request_irq failed", np->name); pr_err("%pOFn: request_irq failed", np);
return -EINVAL; return -EINVAL;
} }
...@@ -146,8 +146,8 @@ static int __init ralink_systick_init(struct device_node *np) ...@@ -146,8 +146,8 @@ static int __init ralink_systick_init(struct device_node *np)
clockevents_register_device(&systick.dev); clockevents_register_device(&systick.dev);
pr_info("%s: running - mult: %d, shift: %d\n", pr_info("%pOFn: running - mult: %d, shift: %d\n",
np->name, systick.dev.mult, systick.dev.shift); np, systick.dev.mult, systick.dev.shift);
return 0; return 0;
} }
......
...@@ -62,7 +62,7 @@ static int __init ill_acc_of_setup(void) ...@@ -62,7 +62,7 @@ static int __init ill_acc_of_setup(void)
pdev = of_find_device_by_node(np); pdev = of_find_device_by_node(np);
if (!pdev) { if (!pdev) {
pr_err("%s: failed to lookup pdev\n", np->name); pr_err("%pOFn: failed to lookup pdev\n", np);
return -EINVAL; return -EINVAL;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment