Commit db749d17 authored by Rob Herring's avatar Rob Herring Committed by Arnd Bergmann

memory: Convert to using %pOF instead of full_name

Now that we have a custom printf format specifier, convert users of
full_name to use %pOF instead. This is preparation to remove storing
of the full path string for each node.
Signed-off-by: default avatarRob Herring <robh@kernel.org>
Acked-by: default avatarAlexandre Belloni <alexandre.belloni@free-electrons.com>
Acked-by: default avatarRoger Quadros <rogerq@ti.com>
Cc: Nicolas Ferre <nicolas.ferre@microchip.com>
Cc: Alexandre Belloni <alexandre.belloni@free-electrons.com>
Cc: Tony Lindgren <tony@atomide.com>
Cc: linux-arm-kernel@lists.infradead.org
Cc: linux-omap@vger.kernel.org
Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
parent 37c342cb
...@@ -156,8 +156,8 @@ static int atmel_ebi_xslate_smc_timings(struct atmel_ebi_dev *ebid, ...@@ -156,8 +156,8 @@ static int atmel_ebi_xslate_smc_timings(struct atmel_ebi_dev *ebid,
out: out:
if (ret) { if (ret) {
dev_err(ebid->ebi->dev, dev_err(ebid->ebi->dev,
"missing or invalid timings definition in %s", "missing or invalid timings definition in %pOF",
np->full_name); np);
return ret; return ret;
} }
...@@ -267,8 +267,8 @@ static int atmel_ebi_xslate_smc_config(struct atmel_ebi_dev *ebid, ...@@ -267,8 +267,8 @@ static int atmel_ebi_xslate_smc_config(struct atmel_ebi_dev *ebid,
return -EINVAL; return -EINVAL;
if ((ret > 0 && !required) || (!ret && required)) { if ((ret > 0 && !required) || (!ret && required)) {
dev_err(ebid->ebi->dev, "missing atmel,smc- properties in %s", dev_err(ebid->ebi->dev, "missing atmel,smc- properties in %pOF",
np->full_name); np);
return -EINVAL; return -EINVAL;
} }
...@@ -311,8 +311,7 @@ static int atmel_ebi_dev_setup(struct atmel_ebi *ebi, struct device_node *np, ...@@ -311,8 +311,7 @@ static int atmel_ebi_dev_setup(struct atmel_ebi *ebi, struct device_node *np,
if (cs >= AT91_MATRIX_EBI_NUM_CS || if (cs >= AT91_MATRIX_EBI_NUM_CS ||
!(ebi->caps->available_cs & BIT(cs))) { !(ebi->caps->available_cs & BIT(cs))) {
dev_err(dev, "invalid reg property in %s\n", dev_err(dev, "invalid reg property in %pOF\n", np);
np->full_name);
return -EINVAL; return -EINVAL;
} }
...@@ -321,7 +320,7 @@ static int atmel_ebi_dev_setup(struct atmel_ebi *ebi, struct device_node *np, ...@@ -321,7 +320,7 @@ static int atmel_ebi_dev_setup(struct atmel_ebi *ebi, struct device_node *np,
} }
if (!numcs) { if (!numcs) {
dev_err(dev, "invalid reg property in %s\n", np->full_name); dev_err(dev, "invalid reg property in %pOF\n", np);
return -EINVAL; return -EINVAL;
} }
...@@ -569,8 +568,8 @@ static int atmel_ebi_probe(struct platform_device *pdev) ...@@ -569,8 +568,8 @@ static int atmel_ebi_probe(struct platform_device *pdev)
ret = atmel_ebi_dev_setup(ebi, child, reg_cells); ret = atmel_ebi_dev_setup(ebi, child, reg_cells);
if (ret) { if (ret) {
dev_err(dev, "failed to configure EBI bus for %s, disabling the device", dev_err(dev, "failed to configure EBI bus for %pOF, disabling the device",
child->full_name); child);
ret = atmel_ebi_dev_disable(ebi, child); ret = atmel_ebi_dev_disable(ebi, child);
if (ret) if (ret)
......
...@@ -322,8 +322,8 @@ static int jz4780_nemc_probe(struct platform_device *pdev) ...@@ -322,8 +322,8 @@ static int jz4780_nemc_probe(struct platform_device *pdev)
bank = of_read_number(prop, 1); bank = of_read_number(prop, 1);
if (bank < 1 || bank >= JZ4780_NEMC_NUM_BANKS) { if (bank < 1 || bank >= JZ4780_NEMC_NUM_BANKS) {
dev_err(nemc->dev, dev_err(nemc->dev,
"%s requests invalid bank %u\n", "%pOF requests invalid bank %u\n",
child->full_name, bank); child, bank);
/* Will continue the outer loop below. */ /* Will continue the outer loop below. */
referenced = 0; referenced = 0;
...@@ -334,12 +334,12 @@ static int jz4780_nemc_probe(struct platform_device *pdev) ...@@ -334,12 +334,12 @@ static int jz4780_nemc_probe(struct platform_device *pdev)
} }
if (!referenced) { if (!referenced) {
dev_err(nemc->dev, "%s has no addresses\n", dev_err(nemc->dev, "%pOF has no addresses\n",
child->full_name); child);
continue; continue;
} else if (nemc->banks_present & referenced) { } else if (nemc->banks_present & referenced) {
dev_err(nemc->dev, "%s conflicts with another node\n", dev_err(nemc->dev, "%pOF conflicts with another node\n",
child->full_name); child);
continue; continue;
} }
......
...@@ -105,8 +105,8 @@ static int get_timing_param_ps(struct devbus *devbus, ...@@ -105,8 +105,8 @@ static int get_timing_param_ps(struct devbus *devbus,
err = of_property_read_u32(node, name, &time_ps); err = of_property_read_u32(node, name, &time_ps);
if (err < 0) { if (err < 0) {
dev_err(devbus->dev, "%s has no '%s' property\n", dev_err(devbus->dev, "%pOF has no '%s' property\n",
name, node->full_name); node, name);
return err; return err;
} }
...@@ -127,8 +127,8 @@ static int devbus_get_timing_params(struct devbus *devbus, ...@@ -127,8 +127,8 @@ static int devbus_get_timing_params(struct devbus *devbus,
err = of_property_read_u32(node, "devbus,bus-width", &r->bus_width); err = of_property_read_u32(node, "devbus,bus-width", &r->bus_width);
if (err < 0) { if (err < 0) {
dev_err(devbus->dev, dev_err(devbus->dev,
"%s has no 'devbus,bus-width' property\n", "%pOF has no 'devbus,bus-width' property\n",
node->full_name); node);
return err; return err;
} }
...@@ -180,8 +180,8 @@ static int devbus_get_timing_params(struct devbus *devbus, ...@@ -180,8 +180,8 @@ static int devbus_get_timing_params(struct devbus *devbus,
&w->sync_enable); &w->sync_enable);
if (err < 0) { if (err < 0) {
dev_err(devbus->dev, dev_err(devbus->dev,
"%s has no 'devbus,sync-enable' property\n", "%pOF has no 'devbus,sync-enable' property\n",
node->full_name); node);
return err; return err;
} }
} }
......
...@@ -1930,8 +1930,8 @@ static int gpmc_probe_onenand_child(struct platform_device *pdev, ...@@ -1930,8 +1930,8 @@ static int gpmc_probe_onenand_child(struct platform_device *pdev,
struct omap_onenand_platform_data *gpmc_onenand_data; struct omap_onenand_platform_data *gpmc_onenand_data;
if (of_property_read_u32(child, "reg", &val) < 0) { if (of_property_read_u32(child, "reg", &val) < 0) {
dev_err(&pdev->dev, "%s has no 'reg' property\n", dev_err(&pdev->dev, "%pOF has no 'reg' property\n",
child->full_name); child);
return -ENODEV; return -ENODEV;
} }
...@@ -1979,14 +1979,14 @@ static int gpmc_probe_generic_child(struct platform_device *pdev, ...@@ -1979,14 +1979,14 @@ static int gpmc_probe_generic_child(struct platform_device *pdev,
struct gpmc_device *gpmc = platform_get_drvdata(pdev); struct gpmc_device *gpmc = platform_get_drvdata(pdev);
if (of_property_read_u32(child, "reg", &cs) < 0) { if (of_property_read_u32(child, "reg", &cs) < 0) {
dev_err(&pdev->dev, "%s has no 'reg' property\n", dev_err(&pdev->dev, "%pOF has no 'reg' property\n",
child->full_name); child);
return -ENODEV; return -ENODEV;
} }
if (of_address_to_resource(child, 0, &res) < 0) { if (of_address_to_resource(child, 0, &res) < 0) {
dev_err(&pdev->dev, "%s has malformed 'reg' property\n", dev_err(&pdev->dev, "%pOF has malformed 'reg' property\n",
child->full_name); child);
return -ENODEV; return -ENODEV;
} }
...@@ -2084,8 +2084,8 @@ static int gpmc_probe_generic_child(struct platform_device *pdev, ...@@ -2084,8 +2084,8 @@ static int gpmc_probe_generic_child(struct platform_device *pdev,
ret = of_property_read_u32(child, "bank-width", ret = of_property_read_u32(child, "bank-width",
&gpmc_s.device_width); &gpmc_s.device_width);
if (ret < 0) { if (ret < 0) {
dev_err(&pdev->dev, "%s has no 'bank-width' property\n", dev_err(&pdev->dev, "%pOF has no 'bank-width' property\n",
child->full_name); child);
goto err; goto err;
} }
} }
......
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