On Wed, Jan 3, 2018 at 9:35 AM, Stephen Boyd <sb...@codeaurora.org> wrote:
> We'd like to privatize __clk_get(), but the sunxi clk driver is
> calling this function to keep a reference held on the clk and
> call clk_prepare_enable() on it. We support this design in the
> clk core now with the CLK_IS_CRITICAL flag, so let's just use
> that instead.
>
> Cc: Maxime Ripard <maxime.rip...@free-electrons.com>
> Cc: Chen-Yu Tsai <w...@csie.org>
> Signed-off-by: Stephen Boyd <sb...@codeaurora.org>
> ---
>  drivers/clk/sunxi/clk-factors.c    | 26 +++++++++++++++++++++-----
>  drivers/clk/sunxi/clk-factors.h    |  4 ++++
>  drivers/clk/sunxi/clk-mod0.c       |  9 ++-------
>  drivers/clk/sunxi/clk-sun8i-mbus.c |  7 ++-----
>  drivers/clk/sunxi/clk-sun9i-core.c |  9 ++-------
>  drivers/clk/sunxi/clk-sunxi.c      | 36 +++++++++++++-----------------------
>  6 files changed, 44 insertions(+), 47 deletions(-)
>
> diff --git a/drivers/clk/sunxi/clk-factors.c b/drivers/clk/sunxi/clk-factors.c
> index 856fef65433b..f6f4757d2dd1 100644
> --- a/drivers/clk/sunxi/clk-factors.c
> +++ b/drivers/clk/sunxi/clk-factors.c
> @@ -176,10 +176,10 @@ static const struct clk_ops clk_factors_ops = {
>         .set_rate = clk_factors_set_rate,
>  };
>
> -struct clk *sunxi_factors_register(struct device_node *node,
> -                                  const struct factors_data *data,
> -                                  spinlock_t *lock,
> -                                  void __iomem *reg)
> +struct clk *__sunxi_factors_register(struct device_node *node,

This looks like it's only used within the file by the two wrapper
functions. Mark it static?

Otherwise

Reviewed-by: Chen-Yu Tsai <w...@csie.org>

Looks like you picked the easiest (least code changes) for each type
of clock?

Reply via email to