memory: 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: Roger Quadros <rogerq@ti.com>
Cc: Kukjin Kim <kgene@kernel.org>
Cc: Jonathan Hunter <jonathanh@nvidia.com>
Cc: linux-omap@vger.kernel.org
Cc: linux-arm-kernel@lists.infradead.org
Cc: linux-samsung-soc@vger.kernel.org
Cc: linux-tegra@vger.kernel.org
Acked-by: Thierry Reding <treding@nvidia.com>
Acked-by: Tony Lindgren <tony@atomide.com>
Acked-by: Krzysztof Kozlowski <krzk@kernel.org>
Signed-off-by: Rob Herring <robh@kernel.org>
This commit is contained in:
Rob Herring 2018-08-27 19:57:23 -05:00
parent 2ef790dc44
commit c86f98544f
4 changed files with 18 additions and 22 deletions

View File

@ -2145,8 +2145,8 @@ static int gpmc_probe_generic_child(struct platform_device *pdev,
gpmc_s.device_width = GPMC_DEVWIDTH_16BIT; gpmc_s.device_width = GPMC_DEVWIDTH_16BIT;
break; break;
default: default:
dev_err(&pdev->dev, "%s: invalid 'nand-bus-width'\n", dev_err(&pdev->dev, "%pOFn: invalid 'nand-bus-width'\n",
child->name); child);
ret = -EINVAL; ret = -EINVAL;
goto err; goto err;
} }
@ -2186,8 +2186,8 @@ static int gpmc_probe_generic_child(struct platform_device *pdev,
ret = gpmc_cs_set_timings(cs, &gpmc_t, &gpmc_s); ret = gpmc_cs_set_timings(cs, &gpmc_t, &gpmc_s);
if (ret) { if (ret) {
dev_err(&pdev->dev, "failed to set gpmc timings for: %s\n", dev_err(&pdev->dev, "failed to set gpmc timings for: %pOFn\n",
child->name); child);
goto err_cs; goto err_cs;
} }
@ -2215,7 +2215,7 @@ no_timings:
err_child_fail: err_child_fail:
dev_err(&pdev->dev, "failed to create gpmc child %s\n", child->name); dev_err(&pdev->dev, "failed to create gpmc child %pOFn\n", child);
ret = -ENODEV; ret = -ENODEV;
err_cs: err_cs:
@ -2265,14 +2265,10 @@ static void gpmc_probe_dt_children(struct platform_device *pdev)
struct device_node *child; struct device_node *child;
for_each_available_child_of_node(pdev->dev.of_node, child) { for_each_available_child_of_node(pdev->dev.of_node, child) {
if (!child->name)
continue;
ret = gpmc_probe_generic_child(pdev, child); ret = gpmc_probe_generic_child(pdev, child);
if (ret) { if (ret) {
dev_err(&pdev->dev, "failed to probe DT child '%s': %d\n", dev_err(&pdev->dev, "failed to probe DT child '%pOFn': %d\n",
child->name, ret); child, ret);
} }
} }
} }

View File

@ -139,8 +139,8 @@ static int exynos_srom_probe(struct platform_device *pdev)
for_each_child_of_node(np, child) { for_each_child_of_node(np, child) {
if (exynos_srom_configure_bank(srom, child)) { if (exynos_srom_configure_bank(srom, child)) {
dev_err(dev, dev_err(dev,
"Could not decode bank configuration for %s\n", "Could not decode bank configuration for %pOFn\n",
child->name); child);
bad_bank_config = true; bad_bank_config = true;
} }
} }

View File

@ -345,7 +345,7 @@ static int load_one_timing(struct tegra_mc *mc,
err = of_property_read_u32(node, "clock-frequency", &tmp); err = of_property_read_u32(node, "clock-frequency", &tmp);
if (err) { if (err) {
dev_err(mc->dev, dev_err(mc->dev,
"timing %s: failed to read rate\n", node->name); "timing %pOFn: failed to read rate\n", node);
return err; return err;
} }
@ -360,8 +360,8 @@ static int load_one_timing(struct tegra_mc *mc,
mc->soc->num_emem_regs); mc->soc->num_emem_regs);
if (err) { if (err) {
dev_err(mc->dev, dev_err(mc->dev,
"timing %s: failed to read EMEM configuration\n", "timing %pOFn: failed to read EMEM configuration\n",
node->name); node);
return err; return err;
} }

View File

@ -888,8 +888,8 @@ static int load_one_timing_from_dt(struct tegra_emc *emc,
err = of_property_read_u32(node, "clock-frequency", &value); err = of_property_read_u32(node, "clock-frequency", &value);
if (err) { if (err) {
dev_err(emc->dev, "timing %s: failed to read rate: %d\n", dev_err(emc->dev, "timing %pOFn: failed to read rate: %d\n",
node->name, err); node, err);
return err; return err;
} }
@ -900,16 +900,16 @@ static int load_one_timing_from_dt(struct tegra_emc *emc,
ARRAY_SIZE(timing->emc_burst_data)); ARRAY_SIZE(timing->emc_burst_data));
if (err) { if (err) {
dev_err(emc->dev, dev_err(emc->dev,
"timing %s: failed to read emc burst data: %d\n", "timing %pOFn: failed to read emc burst data: %d\n",
node->name, err); node, err);
return err; return err;
} }
#define EMC_READ_PROP(prop, dtprop) { \ #define EMC_READ_PROP(prop, dtprop) { \
err = of_property_read_u32(node, dtprop, &timing->prop); \ err = of_property_read_u32(node, dtprop, &timing->prop); \
if (err) { \ if (err) { \
dev_err(emc->dev, "timing %s: failed to read " #prop ": %d\n", \ dev_err(emc->dev, "timing %pOFn: failed to read " #prop ": %d\n", \
node->name, err); \ node, err); \
return err; \ return err; \
} \ } \
} }