From: Rob Herring <robh@kernel.org>
To: linux-kernel@vger.kernel.org
Cc: Daniel Lezcano <daniel.lezcano@linaro.org>,
Thomas Gleixner <tglx@linutronix.de>,
Michal Simek <michal.simek@xilinx.com>,
linux-arm-kernel@lists.infradead.org
Subject: [PATCH] clocksource: Convert to using %pOFn instead of device_node.name
Date: Mon, 27 Aug 2018 20:52:14 -0500 [thread overview]
Message-ID: <20180828015252.28511-13-robh@kernel.org> (raw)
In-Reply-To: <20180828015252.28511-1-robh@kernel.org>
In preparation to remove the node name pointer from struct device_node,
convert printf users to use the %pOFn format specifier.
Cc: Daniel Lezcano <daniel.lezcano@linaro.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Michal Simek <michal.simek@xilinx.com>
Cc: linux-arm-kernel@lists.infradead.org
Signed-off-by: Rob Herring <robh@kernel.org>
---
drivers/clocksource/asm9260_timer.c | 2 +-
drivers/clocksource/cadence_ttc_timer.c | 2 +-
drivers/clocksource/dw_apb_timer_of.c | 8 ++++----
drivers/clocksource/pxa_timer.c | 6 +++---
drivers/clocksource/time-orion.c | 8 ++++----
drivers/clocksource/timer-integrator-ap.c | 2 +-
drivers/clocksource/timer-sp804.c | 2 +-
drivers/clocksource/zevio-timer.c | 8 ++++----
8 files changed, 19 insertions(+), 19 deletions(-)
diff --git a/drivers/clocksource/asm9260_timer.c b/drivers/clocksource/asm9260_timer.c
index 38cd2feb87c4..fbaee04fd1d9 100644
--- a/drivers/clocksource/asm9260_timer.c
+++ b/drivers/clocksource/asm9260_timer.c
@@ -193,7 +193,7 @@ static int __init asm9260_timer_init(struct device_node *np)
priv.base = of_io_request_and_map(np, 0, np->name);
if (IS_ERR(priv.base)) {
- pr_err("%s: unable to map resource\n", np->name);
+ pr_err("%pOFn: unable to map resource\n", np);
return PTR_ERR(priv.base);
}
diff --git a/drivers/clocksource/cadence_ttc_timer.c b/drivers/clocksource/cadence_ttc_timer.c
index 29d51755e18b..b33402980b6f 100644
--- a/drivers/clocksource/cadence_ttc_timer.c
+++ b/drivers/clocksource/cadence_ttc_timer.c
@@ -535,7 +535,7 @@ static int __init ttc_timer_init(struct device_node *timer)
if (ret)
return ret;
- pr_info("%s #0 at %p, irq=%d\n", timer->name, timer_baseaddr, irq);
+ pr_info("%pOFn #0 at %p, irq=%d\n", timer, timer_baseaddr, irq);
return 0;
}
diff --git a/drivers/clocksource/dw_apb_timer_of.c b/drivers/clocksource/dw_apb_timer_of.c
index 69866cd8f4bb..fabaa29cc3a4 100644
--- a/drivers/clocksource/dw_apb_timer_of.c
+++ b/drivers/clocksource/dw_apb_timer_of.c
@@ -33,7 +33,7 @@ static void __init timer_get_base_and_rate(struct device_node *np,
*base = of_iomap(np, 0);
if (!*base)
- panic("Unable to map regs for %s", np->name);
+ panic("Unable to map regs for %pOFn", np);
/*
* Not all implementations use a periphal clock, so don't panic
@@ -42,8 +42,8 @@ static void __init timer_get_base_and_rate(struct device_node *np,
pclk = of_clk_get_by_name(np, "pclk");
if (!IS_ERR(pclk))
if (clk_prepare_enable(pclk))
- pr_warn("pclk for %s is present, but could not be activated\n",
- np->name);
+ pr_warn("pclk for %pOFn is present, but could not be activated\n",
+ np);
timer_clk = of_clk_get_by_name(np, "timer");
if (IS_ERR(timer_clk))
@@ -57,7 +57,7 @@ static void __init timer_get_base_and_rate(struct device_node *np,
try_clock_freq:
if (of_property_read_u32(np, "clock-freq", rate) &&
of_property_read_u32(np, "clock-frequency", rate))
- panic("No clock nor clock-frequency property for %s", np->name);
+ panic("No clock nor clock-frequency property for %pOFn", np);
}
static void __init add_clockevent(struct device_node *event_timer)
diff --git a/drivers/clocksource/pxa_timer.c b/drivers/clocksource/pxa_timer.c
index 08cd6eaf3795..395837938301 100644
--- a/drivers/clocksource/pxa_timer.c
+++ b/drivers/clocksource/pxa_timer.c
@@ -191,13 +191,13 @@ static int __init pxa_timer_dt_init(struct device_node *np)
/* timer registers are shared with watchdog timer */
timer_base = of_iomap(np, 0);
if (!timer_base) {
- pr_err("%s: unable to map resource\n", np->name);
+ pr_err("%pOFn: unable to map resource\n", np);
return -ENXIO;
}
clk = of_clk_get(np, 0);
if (IS_ERR(clk)) {
- pr_crit("%s: unable to get clk\n", np->name);
+ pr_crit("%pOFn: unable to get clk\n", np);
return PTR_ERR(clk);
}
@@ -210,7 +210,7 @@ static int __init pxa_timer_dt_init(struct device_node *np)
/* we are only interested in OS-timer0 irq */
irq = irq_of_parse_and_map(np, 0);
if (irq <= 0) {
- pr_crit("%s: unable to parse OS-timer0 irq\n", np->name);
+ pr_crit("%pOFn: unable to parse OS-timer0 irq\n", np);
return -EINVAL;
}
diff --git a/drivers/clocksource/time-orion.c b/drivers/clocksource/time-orion.c
index 12202067fe4b..7d487107e3cd 100644
--- a/drivers/clocksource/time-orion.c
+++ b/drivers/clocksource/time-orion.c
@@ -129,13 +129,13 @@ static int __init orion_timer_init(struct device_node *np)
/* timer registers are shared with watchdog timer */
timer_base = of_iomap(np, 0);
if (!timer_base) {
- pr_err("%s: unable to map resource\n", np->name);
+ pr_err("%pOFn: unable to map resource\n", np);
return -ENXIO;
}
clk = of_clk_get(np, 0);
if (IS_ERR(clk)) {
- pr_err("%s: unable to get clk\n", np->name);
+ pr_err("%pOFn: unable to get clk\n", np);
return PTR_ERR(clk);
}
@@ -148,7 +148,7 @@ static int __init orion_timer_init(struct device_node *np)
/* we are only interested in timer1 irq */
irq = irq_of_parse_and_map(np, 1);
if (irq <= 0) {
- pr_err("%s: unable to parse timer1 irq\n", np->name);
+ pr_err("%pOFn: unable to parse timer1 irq\n", np);
return -EINVAL;
}
@@ -174,7 +174,7 @@ static int __init orion_timer_init(struct device_node *np)
/* setup timer1 as clockevent timer */
ret = setup_irq(irq, &orion_clkevt_irq);
if (ret) {
- pr_err("%s: unable to setup irq\n", np->name);
+ pr_err("%pOFn: unable to setup irq\n", np);
return ret;
}
diff --git a/drivers/clocksource/timer-integrator-ap.c b/drivers/clocksource/timer-integrator-ap.c
index 62d24690ba02..76e526f58620 100644
--- a/drivers/clocksource/timer-integrator-ap.c
+++ b/drivers/clocksource/timer-integrator-ap.c
@@ -190,7 +190,7 @@ static int __init integrator_ap_timer_init_of(struct device_node *node)
clk = of_clk_get(node, 0);
if (IS_ERR(clk)) {
- pr_err("No clock for %s\n", node->name);
+ pr_err("No clock for %pOFn\n", node);
return PTR_ERR(clk);
}
clk_prepare_enable(clk);
diff --git a/drivers/clocksource/timer-sp804.c b/drivers/clocksource/timer-sp804.c
index e01222ea888f..052b230ca312 100644
--- a/drivers/clocksource/timer-sp804.c
+++ b/drivers/clocksource/timer-sp804.c
@@ -249,7 +249,7 @@ static int __init sp804_of_init(struct device_node *np)
if (of_clk_get_parent_count(np) == 3) {
clk2 = of_clk_get(np, 1);
if (IS_ERR(clk2)) {
- pr_err("sp804: %s clock not found: %d\n", np->name,
+ pr_err("sp804: %pOFn clock not found: %d\n", np,
(int)PTR_ERR(clk2));
clk2 = NULL;
}
diff --git a/drivers/clocksource/zevio-timer.c b/drivers/clocksource/zevio-timer.c
index f74689334f7c..6127e8062a71 100644
--- a/drivers/clocksource/zevio-timer.c
+++ b/drivers/clocksource/zevio-timer.c
@@ -148,12 +148,12 @@ static int __init zevio_timer_add(struct device_node *node)
of_address_to_resource(node, 0, &res);
scnprintf(timer->clocksource_name, sizeof(timer->clocksource_name),
- "%llx.%s_clocksource",
- (unsigned long long)res.start, node->name);
+ "%llx.%pOFn_clocksource",
+ (unsigned long long)res.start, node);
scnprintf(timer->clockevent_name, sizeof(timer->clockevent_name),
- "%llx.%s_clockevent",
- (unsigned long long)res.start, node->name);
+ "%llx.%pOFn_clockevent",
+ (unsigned long long)res.start, node);
if (timer->interrupt_regs && irqnr) {
timer->clkevt.name = timer->clockevent_name;
--
2.17.1
next prev parent reply other threads:[~2018-08-28 1:54 UTC|newest]
Thread overview: 163+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-08-28 1:52 [PATCH] ARM: omap: Convert to using %pOFn instead of device_node.name Rob Herring
2018-08-28 1:52 ` [PATCH] ARM: shmobile: " Rob Herring
2018-08-28 7:24 ` Geert Uytterhoeven
2018-08-30 14:37 ` Simon Horman
2018-08-28 1:52 ` [PATCH] ARM: zynq: " Rob Herring
2018-09-05 13:27 ` Michal Simek
2018-08-28 1:52 ` [PATCH] MIPS: " Rob Herring
2018-08-28 16:54 ` Paul Burton
2018-08-28 1:52 ` [PATCH] nios2: " Rob Herring
2018-08-28 15:47 ` Ley Foon Tan
2018-08-28 1:52 ` [PATCH] powerpc: " Rob Herring
2018-10-04 6:14 ` Michael Ellerman
2018-08-28 1:52 ` [PATCH] sparc: " Rob Herring
2018-08-28 14:13 ` Rob Herring
2018-08-28 15:44 ` [PATCH v2] " Rob Herring
2018-10-08 5:57 ` David Miller
2018-08-28 1:52 ` [PATCH] xtensa: " Rob Herring
2018-08-28 15:45 ` Max Filippov
2018-08-28 1:52 ` [PATCH] ata: ahci: " Rob Herring
2018-08-28 14:44 ` Jens Axboe
2018-08-28 1:52 ` [PATCH] bus: fsl-mc: " Rob Herring
2018-08-28 1:52 ` [PATCH] bus: mvebu-mbus: " Rob Herring
2018-08-28 1:52 ` [PATCH] clk: " Rob Herring
2018-08-28 15:44 ` [PATCH v2] " Rob Herring
2018-08-28 22:15 ` Stephen Boyd
2018-08-29 11:13 ` Rob Herring
2018-08-30 16:50 ` Stephen Boyd
2018-09-03 5:29 ` [PATCH] " Chen-Yu Tsai
2018-09-07 15:08 ` Rob Herring
2018-08-28 1:52 ` Rob Herring [this message]
2018-08-29 15:23 ` [PATCH] clocksource: " Daniel Lezcano
2018-08-28 1:52 ` [PATCH] cpufreq: " Rob Herring
2018-09-03 6:34 ` Viresh Kumar
2018-09-14 8:27 ` Rafael J. Wysocki
2018-08-28 1:52 ` [PATCH] devfreq: " Rob Herring
2018-08-28 2:06 ` Chanwoo Choi
[not found] ` <CGME20180828015312epcas2p2fdb2ee1d1b292f212ec773dd8fb4bfc7@epcms1p8>
2018-08-29 2:10 ` MyungJoo Ham
2018-08-28 1:52 ` [PATCH] dmaengine: " Rob Herring
2018-08-28 5:16 ` Vinod
2018-08-28 1:52 ` [PATCH] firmware: " Rob Herring
2018-09-28 21:47 ` Rob Herring
2018-10-01 9:09 ` Sudeep Holla
2018-08-28 1:52 ` [PATCH] gpio: " Rob Herring
2018-08-29 12:02 ` Linus Walleij
2018-08-28 1:52 ` [PATCH] drm: " Rob Herring
2018-08-28 12:54 ` Maarten Lankhorst
2018-08-28 15:04 ` Rob Herring
2018-08-28 15:04 ` Rob Clark
2018-08-28 1:52 ` [PATCH] hwmon: " Rob Herring
2018-08-28 13:57 ` Guenter Roeck
2018-08-28 15:11 ` Rob Herring
2018-08-28 18:43 ` Guenter Roeck
2018-08-28 1:52 ` [PATCH] i2c: " Rob Herring
2018-08-28 6:33 ` Peter Rosin
2018-08-29 18:42 ` Rob Herring
2018-08-29 19:52 ` Peter Rosin
2018-08-30 0:49 ` Rob Herring
2018-08-28 1:52 ` [PATCH] iio: " Rob Herring
2018-09-02 17:55 ` Jonathan Cameron
2018-08-28 1:52 ` [PATCH] input: sun4i-lradc: " Rob Herring
2018-09-28 21:54 ` Rob Herring
2018-09-28 23:59 ` Dmitry Torokhov
2018-08-28 1:52 ` [PATCH] irqchip: " Rob Herring
2018-09-08 12:15 ` Thomas Gleixner
2018-09-10 13:55 ` Rob Herring
2018-08-28 1:52 ` [PATCH] leds: " Rob Herring
2018-08-28 11:07 ` Sakari Ailus
2018-08-28 11:37 ` Pavel Machek
2018-08-28 20:37 ` Jacek Anaszewski
2018-08-28 1:52 ` [PATCH] macintosh: " Rob Herring
2018-08-28 1:52 ` [PATCH] mailbox: " Rob Herring
2018-09-28 21:54 ` Rob Herring
2018-08-28 1:52 ` [PATCH] media: " Rob Herring
2018-08-28 10:06 ` Laurent Pinchart
2018-08-28 12:21 ` Rob Herring
2018-09-12 15:10 ` Mauro Carvalho Chehab
2018-08-28 1:52 ` [PATCH] memory: " Rob Herring
2018-08-28 10:42 ` Thierry Reding
2018-08-28 15:33 ` Tony Lindgren
2018-08-29 7:44 ` Krzysztof Kozlowski
2018-08-28 1:52 ` [PATCH] mfd: max77620: " Rob Herring
2018-09-10 15:24 ` Lee Jones
2018-08-28 1:52 ` [PATCH] misc: " Rob Herring
2018-08-28 2:35 ` Andrew Donnellan
2018-08-28 1:52 ` [PATCH] mmc: " Rob Herring
2018-08-28 7:59 ` Adrian Hunter
2018-08-28 11:41 ` Ulf Hansson
2018-08-28 1:52 ` [PATCH] mtd: rawnand: " Rob Herring
2018-08-28 9:16 ` Boris Brezillon
2018-09-04 21:58 ` Miquel Raynal
2018-08-28 1:52 ` [PATCH] net: ethernet: " Rob Herring
2018-08-28 15:44 ` [PATCH v2] " Rob Herring
2018-08-28 15:45 ` Matthias Brugger
2018-08-29 2:06 ` Sean Wang
2018-08-30 2:41 ` David Miller
2018-08-28 1:52 ` [PATCH] net: phy: " Rob Herring
2018-08-28 16:57 ` Florian Fainelli
2018-08-28 1:52 ` [PATCH] net: wireless: ath: " Rob Herring
2018-08-28 11:19 ` Kalle Valo
2018-09-03 16:58 ` Kalle Valo
2018-08-28 1:52 ` [PATCH] nvmem: " Rob Herring
2018-09-28 22:06 ` Rob Herring
2018-10-01 9:05 ` Srinivas Kandagatla
2018-08-28 1:52 ` [PATCH] perf: " Rob Herring
2018-08-28 17:02 ` Will Deacon
2018-09-28 21:19 ` Rob Herring
2018-10-01 9:18 ` Will Deacon
2018-08-28 1:52 ` [PATCH] phy: " Rob Herring
2018-09-04 2:24 ` Kishon Vijay Abraham I
2018-09-04 14:21 ` Rob Herring
2018-08-28 1:52 ` [PATCH] pinctrl: " Rob Herring
2018-08-28 1:57 ` A.s. Dong
2018-08-28 7:21 ` Alexandre Belloni
2018-08-28 15:34 ` Tony Lindgren
2018-08-29 2:13 ` Sean Wang
2018-08-29 2:15 ` Chen-Yu Tsai
2018-08-29 8:31 ` Heiko Stübner
2018-08-29 12:07 ` Linus Walleij
2018-09-03 9:57 ` Patrice CHOTARD
2018-08-28 1:52 ` [PATCH] regulator: " Rob Herring
2018-08-29 7:47 ` Krzysztof Kozlowski
2018-08-28 1:52 ` [PATCH] rpmsg: " Rob Herring
2018-08-28 3:08 ` Bjorn Andersson
2018-08-28 1:52 ` [PATCH] soc: " Rob Herring
2018-08-28 10:44 ` Thierry Reding
2018-08-28 18:48 ` Li Yang
2018-08-28 22:14 ` Tyrel Datwyler
2018-08-28 22:29 ` Li Yang
2018-08-28 22:46 ` Tyrel Datwyler
2018-08-29 8:21 ` Heiko Stübner
2018-08-29 8:57 ` Qiang Zhao
2018-09-30 17:08 ` Andy Gross
2018-08-28 1:52 ` [PATCH] staging: " Rob Herring
2018-08-28 6:34 ` Ian Arkver
2018-08-28 15:44 ` [PATCH v2] " Rob Herring
2018-09-12 15:17 ` Mauro Carvalho Chehab
2018-09-12 20:26 ` Rob Herring
2018-09-12 21:07 ` Mauro Carvalho Chehab
2018-09-12 22:48 ` Rob Herring
2018-09-13 11:50 ` Joe Perches
2018-09-13 21:26 ` Rob Herring
2018-09-14 11:41 ` Joe Perches
2018-08-28 1:52 ` [PATCH] thermal: " Rob Herring
2018-08-30 14:58 ` Daniel Lezcano
2018-08-28 1:52 ` [PATCH] tty: " Rob Herring
2018-09-28 22:09 ` Rob Herring
2018-09-28 22:32 ` Rob Herring
2018-08-28 1:52 ` [PATCH] uio: " Rob Herring
2018-08-28 1:52 ` [PATCH] backlight: pm8941: " Rob Herring
2018-08-28 1:52 ` [PATCH] fbdev: " Rob Herring
2018-09-28 22:11 ` Rob Herring
2018-10-08 10:41 ` Bartlomiej Zolnierkiewicz
2018-08-28 1:52 ` [PATCH] sound: " Rob Herring
2018-08-28 7:54 ` Andy Shevchenko
2018-08-28 15:44 ` [PATCH v2] " Rob Herring
2018-09-03 21:45 ` [alsa-devel] " Takashi Iwai
2018-08-28 1:52 ` [PATCH] ASoC: " Rob Herring
2018-08-28 7:57 ` Andy Shevchenko
2018-08-28 15:44 ` [PATCH v2] " Rob Herring
2018-08-28 18:03 ` Mark Brown
2018-08-28 6:55 ` [PATCH] ARM: omap: " Joe Perches
2018-08-28 15:44 ` [PATCH v2] " Rob Herring
2018-09-07 17:14 ` Tony Lindgren
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20180828015252.28511-13-robh@kernel.org \
--to=robh@kernel.org \
--cc=daniel.lezcano@linaro.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=michal.simek@xilinx.com \
--cc=tglx@linutronix.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).