From: Mike Turquette <mturquette@linaro.org>
To: Stephen Boyd <sboyd@codeaurora.org>,
"Heikki Krogerus" <heikki.krogerus@linux.intel.com>
Cc: linux-kernel@vger.kernel.org
Subject: Re: [PATCH] clk: fractional-divider: support for divider bypassing
Date: Wed, 25 Feb 2015 12:16:07 -0800 [thread overview]
Message-ID: <20150225201607.421.64225@quantum> (raw)
In-Reply-To: <54CFD33F.3000103@codeaurora.org>
Quoting Stephen Boyd (2015-02-02 11:42:55)
> On 02/02/15 05:37, Heikki Krogerus wrote:
> > If the divider or multiplier values values are 0 in the
>
> s/values//
>
> > register, bypassing the divider and returning the parent
> > clock rate in clk_fd_recalc_rate().
> >
> > Signed-off-by: Heikki Krogerus <heikki.krogerus@linux.intel.com>
> > ---
>
> Reviewed-by: Stephen Boyd <sboyd@codeaurora.org>
Applied to clk-next.
Regards,
Mike
>
> > drivers/clk/clk-fractional-divider.c | 3 +++
> > 1 file changed, 3 insertions(+)
> >
> > diff --git a/drivers/clk/clk-fractional-divider.c b/drivers/clk/clk-fractional-divider.c
> > index dc91da7..34d6c51 100644
> > --- a/drivers/clk/clk-fractional-divider.c
> > +++ b/drivers/clk/clk-fractional-divider.c
> > @@ -36,6 +36,9 @@ static unsigned long clk_fd_recalc_rate(struct clk_hw *hw,
> > m = (val & fd->mmask) >> fd->mshift;
> > n = (val & fd->nmask) >> fd->nshift;
> >
> > + if (!n || !m)
> > + return parent_rate;
> > +
> > ret = (u64)parent_rate * m;
> > do_div(ret, n);
> >
>
>
> --
> Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum,
> a Linux Foundation Collaborative Project
>
prev parent reply other threads:[~2015-02-25 20:16 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-02-02 13:37 [PATCH] clk: fractional-divider: support for divider bypassing Heikki Krogerus
2015-02-02 19:42 ` Stephen Boyd
2015-02-25 20:13 ` Mike Turquette
2015-02-25 20:16 ` Mike Turquette [this message]
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=20150225201607.421.64225@quantum \
--to=mturquette@linaro.org \
--cc=heikki.krogerus@linux.intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=sboyd@codeaurora.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