mbox series

[v3,0/3] clk: provide new devm helpers for prepared and enabled clocks

Message ID 20210301135053.1462168-1-u.kleine-koenig@pengutronix.de
Headers show
Series clk: provide new devm helpers for prepared and enabled clocks | expand

Message

Uwe Kleine-König March 1, 2021, 1:50 p.m. UTC
Hello,

this is a brown paper bag version (aka v3) of my series adding
devm_clk_get_enabled() et al.

Changes since v2 (sent with Message-Id:
20210301110821.1445756-1-uwe@kleine-koenig.org):

 - send it from the right email account to have the sender matching the
   SoB line
 - make __devm_clk_get static
 - fix EXPORT_SYMBOL usage

The last two were found by the kernel test robot.

Range-diff can be found below.

Best regards
Uwe

Uwe Kleine-König (3):
  clk: generalize devm_clk_get() a bit
  clk: Provide new devm_clk_helpers for prepared and enabled clocks
  pwm: atmel: Simplify using devm_clk_get_prepared()

 drivers/clk/clk-devres.c | 96 +++++++++++++++++++++++++++++++++-------
 drivers/pwm/pwm-atmel.c  | 15 +------
 include/linux/clk.h      | 87 +++++++++++++++++++++++++++++++++++-
 3 files changed, 168 insertions(+), 30 deletions(-)

Range-diff against v2:
1:  7203dc0837af ! 1:  3faadae49fed clk: generalize devm_clk_get a bit
    @@ drivers/clk/clk-devres.c
      }
      
     -struct clk *devm_clk_get(struct device *dev, const char *id)
    -+struct clk *__devm_clk_get(struct device *dev, const char *id,
    -+			   struct clk *(*get)(struct device *dev, const char *id),
    -+			   int (*init)(struct clk *clk),
    -+			   void (*exit)(struct clk *clk))
    ++static struct clk *__devm_clk_get(struct device *dev, const char *id,
    ++				  struct clk *(*get)(struct device *dev, const char *id),
    ++				  int (*init)(struct clk *clk),
    ++				  void (*exit)(struct clk *clk))
      {
     -	struct clk **ptr, *clk;
     +	struct devm_clk_state *state;
2:  4d2107992b8c ! 2:  82005b4a9ea1 clk: Provide new devm_clk_helpers for prepared and enabled clocks
    @@ drivers/clk/clk-devres.c: struct clk *devm_clk_get(struct device *dev, const cha
     +			      clk_prepare_enable, clk_disable_unprepare);
     +
     +}
    -+EXPORT_SYMBOL(devm_clk_get_prepared);
    ++EXPORT_SYMBOL(devm_clk_get_enabled);
     +
      struct clk *devm_clk_get_optional(struct device *dev, const char *id)
      {
    @@ drivers/clk/clk-devres.c: struct clk *devm_clk_get(struct device *dev, const cha
     +			      clk_prepare_enable, clk_disable_unprepare);
     +
     +}
    -+EXPORT_SYMBOL(devm_clk_get_optional_prepared);
    ++EXPORT_SYMBOL(devm_clk_get_optional_enabled);
     +
      struct clk_bulk_devres {
      	struct clk_bulk_data *clks;
3:  63f799a4ff32 = 3:  1f73d17d4da7 pwm: atmel: Simplify using devm_clk_get_prepared()

base-commit: fe07bfda2fb9cdef8a4d4008a409bb02f35f1bd8

Comments

Uwe Kleine-König March 22, 2021, 2:22 p.m. UTC | #1
Hello,

On Mon, Mar 01, 2021 at 02:50:50PM +0100, Uwe Kleine-König wrote:
> Uwe Kleine-König (3):
>   clk: generalize devm_clk_get() a bit
>   clk: Provide new devm_clk_helpers for prepared and enabled clocks
>   pwm: atmel: Simplify using devm_clk_get_prepared()
> 
>  drivers/clk/clk-devres.c | 96 +++++++++++++++++++++++++++++++++-------
>  drivers/pwm/pwm-atmel.c  | 15 +------
>  include/linux/clk.h      | 87 +++++++++++++++++++++++++++++++++++-
>  3 files changed, 168 insertions(+), 30 deletions(-)

can I get some feedback on this series please? The idea is on the list
since October last year with absolutely no maintainer feedback.

I think it's a good idea and not too hard to review, so I wonder what is
stopping you.

Best regards
Uwe