diff mbox series

[U-Boot,v2,02/19] clk: Improve debug message in clk_set_default_rates()

Message ID 20190121215336.74802-3-sjg@chromium.org
State Accepted
Delegated to: Philipp Tomsich
Headers show
Series rockchip: Add support for Bob Chromebook | expand

Commit Message

Simon Glass Jan. 21, 2019, 9:53 p.m. UTC
It is helpful to print the clock number as well as the index, so that this
can be looked up in the binding file. Update the debug() statement to do
this.

Signed-off-by: Simon Glass <sjg@chromium.org>
---

Changes in v2: None

 drivers/clk/clk-uclass.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comments

Philipp Tomsich Jan. 31, 2019, 9:18 p.m. UTC | #1
> It is helpful to print the clock number as well as the index, so that this
> can be looked up in the binding file. Update the debug() statement to do
> this.
> 
> Signed-off-by: Simon Glass <sjg@chromium.org>
> ---
> 
> Changes in v2: None
> 
>  drivers/clk/clk-uclass.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 

Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
Philipp Tomsich April 21, 2019, 4:56 p.m. UTC | #2
> It is helpful to print the clock number as well as the index, so that this
> can be looked up in the binding file. Update the debug() statement to do
> this.
> 
> Signed-off-by: Simon Glass <sjg@chromium.org>
> Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
> ---
> 
> Changes in v2: None
> 
>  drivers/clk/clk-uclass.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 

Reviewed-by: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
diff mbox series

Patch

diff --git a/drivers/clk/clk-uclass.c b/drivers/clk/clk-uclass.c
index 6d7a514006..844b87cc33 100644
--- a/drivers/clk/clk-uclass.c
+++ b/drivers/clk/clk-uclass.c
@@ -228,8 +228,8 @@  static int clk_set_default_rates(struct udevice *dev)
 
 		ret = clk_set_rate(&clk, rates[index]);
 		if (ret < 0) {
-			debug("%s: failed to set rate on clock %d for %s\n",
-			      __func__, index, dev_read_name(dev));
+			debug("%s: failed to set rate on clock index %d (%ld) for %s\n",
+			      __func__, index, clk.id, dev_read_name(dev));
 			break;
 		}
 	}