linux-clk.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] clk: Fix __set_clk_rates error print-string
@ 2017-05-15 10:58 Bryan O'Donoghue
  2017-06-01  9:15 ` Stephen Boyd
  0 siblings, 1 reply; 2+ messages in thread
From: Bryan O'Donoghue @ 2017-05-15 10:58 UTC (permalink / raw)
  To: mturquette, sboyd, linux-clk, cw00.choi; +Cc: Bryan O'Donoghue

When failing to set a clock the printout emitted is incorrect.
"u32 rate" is formatted as %d and should be %u whereas "unsigned long
clk_set_rate()" is formatted as %ld and should be %lu as per
Documentation/printk-formats.txt.

Fixes: 2885c3b2a3da ("clk: Show correct information when fail to set clock
                      rate")

Signed-off-by: Bryan O'Donoghue <pure.logic@nexus-software.ie>
---
 drivers/clk/clk-conf.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/clk/clk-conf.c b/drivers/clk/clk-conf.c
index e0e02a6..7ec3672 100644
--- a/drivers/clk/clk-conf.c
+++ b/drivers/clk/clk-conf.c
@@ -109,7 +109,7 @@ static int __set_clk_rates(struct device_node *node, bool clk_supplier)
 
 			rc = clk_set_rate(clk, rate);
 			if (rc < 0)
-				pr_err("clk: couldn't set %s clk rate to %d (%d), current rate: %ld\n",
+				pr_err("clk: couldn't set %s clk rate to %u (%d), current rate: %lu\n",
 				       __clk_get_name(clk), rate, rc,
 				       clk_get_rate(clk));
 			clk_put(clk);
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] clk: Fix __set_clk_rates error print-string
  2017-05-15 10:58 [PATCH] clk: Fix __set_clk_rates error print-string Bryan O'Donoghue
@ 2017-06-01  9:15 ` Stephen Boyd
  0 siblings, 0 replies; 2+ messages in thread
From: Stephen Boyd @ 2017-06-01  9:15 UTC (permalink / raw)
  To: Bryan O'Donoghue; +Cc: mturquette, linux-clk, cw00.choi

On 05/15, Bryan O'Donoghue wrote:
> When failing to set a clock the printout emitted is incorrect.
> "u32 rate" is formatted as %d and should be %u whereas "unsigned long
> clk_set_rate()" is formatted as %ld and should be %lu as per
> Documentation/printk-formats.txt.
> 
> Fixes: 2885c3b2a3da ("clk: Show correct information when fail to set clock
>                       rate")
> 
> Signed-off-by: Bryan O'Donoghue <pure.logic@nexus-software.ie>
> ---

Applied to clk-next but I fixed up the Fixes: tag to be on one
line and next to the signed-off one.

-- 
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum,
a Linux Foundation Collaborative Project

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2017-06-01  9:15 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-05-15 10:58 [PATCH] clk: Fix __set_clk_rates error print-string Bryan O'Donoghue
2017-06-01  9:15 ` Stephen Boyd

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).