clk: gpio: Add debug messages for clock ops
PATCH 1/1 clk: gpio: Add debug messages for clock ops
Debug messages are helpful when debugging the clock tree setup.
Cc Jyri Sarha <[email protected]>
Signed-off-by Sergej Sawazki <[email protected]>
--- drivers/clk/clk-gpio.c | 3 +++ 1 file changed, 3 insertions(+)
drivers/clk/clk-gpio.c +3 -0
@@ -38,6 +38,7 @@ static int clk_gpio_gate_enable(struct clk_hw *hw)struct clk_gpio *clk =to_clk_gpio (hw);gpiod_set_value (clk->gpiod,1 ); +pr_debug ("%s clock enabled\n" ,clk_hw_get_name (hw));return 0 ; }
@@ -47,6 +48,7 @@ static void clk_gpio_gate_disable(struct clk_hw *hw)struct clk_gpio *clk =to_clk_gpio (hw);gpiod_set_value (clk->gpiod,0 ); +pr_debug ("%s clock disabled\n" ,clk_hw_get_name (hw)); }static int clk_gpio_gate_is_enabled (struct clk_hw *hw)
@@ -83,6 +85,7 @@ static int clk_gpio_mux_set_parent(struct clk_hw *hw, u8 index)struct clk_gpio *clk =to_clk_gpio (hw);gpiod_set_value (clk->gpiod, index); +pr_debug ("%s set parent %d\n" ,clk_hw_get_name (hw), index);return 0 ; }
Signature · 1 line
2.7.4
Quoted 5 lines · Sergej Sawazki
Debug messages are helpful when debugging the clock tree setup.
Cc Jyri Sarha <[email protected]>Signed-off-by Sergej Sawazki <[email protected]>
Can you use clk tracepoints instead?
Signature · 2 lines
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, a Linux Foundation Collaborative Project
Quoted 5 lines · Stephen Boyd
Quoted 1 line · Sergej Sawazki
Debug messages are helpful when debugging the clock tree setup.
Can you use clk tracepoints instead?
Probably yes, but I have been debugging the rest of the system with the help of dynamic debug (dmesg) and found it pretty simple. The si5351 driver, for example, has a lot dev_dbg()'s, which were very helpful.