linux-arch.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Stephen Boyd <sboyd@codeaurora.org>
To: Chen-Yu Tsai <wens@csie.org>
Cc: Michael Turquette <mturquette@baylibre.com>,
	linux-kernel <linux-kernel@vger.kernel.org>,
	linux-clk <linux-clk@vger.kernel.org>,
	"open list:GENERIC INCLUDE/A..." <linux-arch@vger.kernel.org>,
	Maxime Ripard <maxime.ripard@free-electrons.com>
Subject: Re: [PATCH 4/5] clk: sunxi: Use CLK_IS_CRITICAL flag for critical clks
Date: Wed, 3 Jan 2018 09:01:30 -0800	[thread overview]
Message-ID: <20180103170130.GW7997@codeaurora.org> (raw)
In-Reply-To: <CAGb2v67s6JR87nvZ4s1MQ0jG7xj7y0s4C257YWB66xaVCR3c0Q@mail.gmail.com>

On 01/03, Chen-Yu Tsai wrote:
> On Wed, Jan 3, 2018 at 9:35 AM, Stephen Boyd <sboyd@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.ripard@free-electrons.com>
> > Cc: Chen-Yu Tsai <wens@csie.org>
> > Signed-off-by: Stephen Boyd <sboyd@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?

Ah thanks. I hadn't run sparse yet.

> 
> Otherwise
> 
> Reviewed-by: Chen-Yu Tsai <wens@csie.org>
> 
> Looks like you picked the easiest (least code changes) for each type
> of clock?

Yep.

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

  reply	other threads:[~2018-01-03 17:01 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-01-03  1:35 [PATCH 0/5] Remove asm/clkdev.h and privatize __clk{get,put}() Stephen Boyd
2018-01-03  1:35 ` Stephen Boyd
2018-01-03  1:35 ` [PATCH 1/5] blackfin: Use generic clkdev.h header Stephen Boyd
2018-01-10 21:20   ` Stephen Boyd
2018-01-10 21:20     ` Stephen Boyd
2018-01-03  1:35 ` [PATCH 2/5] clk: Prepare to remove asm-generic/clkdev.h Stephen Boyd
2018-01-10 21:20   ` Stephen Boyd
2018-01-10 21:20     ` Stephen Boyd
2018-01-03  1:35 ` [PATCH 3/5] arch: Remove clkdev.h asm-generic from Kbuild Stephen Boyd
2018-01-03  8:43   ` Geert Uytterhoeven
2018-01-03  8:43     ` Geert Uytterhoeven
2018-01-03 15:37   ` Arnd Bergmann
2018-01-03 15:37     ` Arnd Bergmann
2018-01-10 21:20   ` Stephen Boyd
2018-01-10 21:20     ` Stephen Boyd
2018-01-03  1:35 ` [PATCH 4/5] clk: sunxi: Use CLK_IS_CRITICAL flag for critical clks Stephen Boyd
2018-01-03  2:58   ` Chen-Yu Tsai
2018-01-03 17:01     ` Stephen Boyd [this message]
2018-01-04 13:13   ` Maxime Ripard
2018-01-10 21:20   ` Stephen Boyd
2018-01-10 21:20     ` Stephen Boyd
2018-01-03  1:35 ` [PATCH 5/5] clk: Move __clk_{get,put}() into private clk.h API Stephen Boyd
2018-01-03  1:35   ` Stephen Boyd
2018-01-10 21:20   ` Stephen Boyd
2018-01-10 21:20     ` Stephen Boyd

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20180103170130.GW7997@codeaurora.org \
    --to=sboyd@codeaurora.org \
    --cc=linux-arch@vger.kernel.org \
    --cc=linux-clk@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=maxime.ripard@free-electrons.com \
    --cc=mturquette@baylibre.com \
    --cc=wens@csie.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).