diff options
author | Rob Herring <robh@kernel.org> | 2018-08-27 20:02:33 -0500 |
---|---|---|
committer | Rob Herring <robh@kernel.org> | 2018-10-04 14:16:01 -0500 |
commit | dc37a25252717aab7efa4802dc1a1430392b145a (patch) | |
tree | d8121794be829c5f452b50e5cfb9932de2b886d2 /drivers/soc/dove/pmu.c | |
parent | 75afbfc1156c8f7de5717a8d278a4da0d98a8532 (diff) |
soc: 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.
Cc: Li Yang <leoyang.li@nxp.com>
Cc: David Brown <david.brown@linaro.org>
Cc: Jonathan Hunter <jonathanh@nvidia.com>
Cc: Santosh Shilimkar <ssantosh@kernel.org>
Cc: linuxppc-dev@lists.ozlabs.org
Cc: linux-arm-kernel@lists.infradead.org
Cc: linux-soc@vger.kernel.org
Acked-by: Thierry Reding <treding@nvidia.com>
Acked-by: Heiko Stuebner <heiko@sntech.de>
Acked-by: Qiang Zhao <qiang.zhao@nxp.com>
Acked-by: Andy Gross <andy.gross@linaro.org>
Signed-off-by: Rob Herring <robh@kernel.org>
Diffstat (limited to 'drivers/soc/dove/pmu.c')
-rw-r--r-- | drivers/soc/dove/pmu.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/soc/dove/pmu.c b/drivers/soc/dove/pmu.c index 5abb08ffb74d..ffc5311c0ed8 100644 --- a/drivers/soc/dove/pmu.c +++ b/drivers/soc/dove/pmu.c @@ -383,7 +383,7 @@ int __init dove_init_pmu(void) domains_node = of_get_child_by_name(np_pmu, "domains"); if (!domains_node) { - pr_err("%s: failed to find domains sub-node\n", np_pmu->name); + pr_err("%pOFn: failed to find domains sub-node\n", np_pmu); return 0; } @@ -396,7 +396,7 @@ int __init dove_init_pmu(void) pmu->pmc_base = of_iomap(pmu->of_node, 0); pmu->pmu_base = of_iomap(pmu->of_node, 1); if (!pmu->pmc_base || !pmu->pmu_base) { - pr_err("%s: failed to map PMU\n", np_pmu->name); + pr_err("%pOFn: failed to map PMU\n", np_pmu); iounmap(pmu->pmu_base); iounmap(pmu->pmc_base); kfree(pmu); @@ -414,7 +414,7 @@ int __init dove_init_pmu(void) break; domain->pmu = pmu; - domain->base.name = kstrdup(np->name, GFP_KERNEL); + domain->base.name = kasprintf(GFP_KERNEL, "%pOFn", np); if (!domain->base.name) { kfree(domain); break; @@ -444,7 +444,7 @@ int __init dove_init_pmu(void) /* Loss of the interrupt controller is not a fatal error. */ parent_irq = irq_of_parse_and_map(pmu->of_node, 0); if (!parent_irq) { - pr_err("%s: no interrupt specified\n", np_pmu->name); + pr_err("%pOFn: no interrupt specified\n", np_pmu); } else { ret = dove_init_pmu_irq(pmu, parent_irq); if (ret) |