[PATCH v3 2/2] cpufreq: qoriq: Don't look at clock implementation details

Y.T. Tang yuantian.tang at nxp.com
Mon Feb 6 17:12:40 AEDT 2017


> -----Original Message-----
> From: Leo Li [mailto:pku.leo at gmail.com]
> Sent: Friday, February 03, 2017 2:12 AM
> To: Y.T. Tang <yuantian.tang at nxp.com>
> Cc: Scott Wood <oss at buserror.net>; Michael Turquette
> <mturquette at baylibre.com>; Russell King <linux at armlinux.org.uk>;
> Stephen Boyd <sboyd at codeaurora.org>; Viresh Kumar
> <viresh.kumar at linaro.org>; Rafael J. Wysocki <rjw at rjwysocki.net>; linux-
> clk at vger.kernel.org; linux-pm at vger.kernel.org; linuxppc-
> dev at lists.ozlabs.org; Leo Li <leoyang.li at nxp.com>; X.F. Ren
> <xiaofeng.ren at nxp.com>
> Subject: Re: [PATCH v3 2/2] cpufreq: qoriq: Don't look at clock
> implementation details
> 
> On Tue, Jul 19, 2016 at 10:02 PM, Yuantian Tang <yuantian.tang at nxp.com>
> wrote:
> >
> > PING.
> >
> > Regards,
> > Yuantian
> >
> > > -----Original Message-----
> > > From: Scott Wood [mailto:oss at buserror.net]
> > > Sent: Saturday, July 09, 2016 5:07 AM
> > > To: Michael Turquette <mturquette at baylibre.com>; Russell King
> > > <linux at armlinux.org.uk>; Stephen Boyd <sboyd at codeaurora.org>;
> Viresh
> > > Kumar <viresh.kumar at linaro.org>; Rafael J. Wysocki
> > > <rjw at rjwysocki.net>
> > > Cc: linux-clk at vger.kernel.org; linux-pm at vger.kernel.org; linuxppc-
> > > dev at lists.ozlabs.org; Yuantian Tang <yuantian.tang at nxp.com>;
> > > Yang-Leo Li <leoyang.li at nxp.com>; Xiaofeng Ren
> > > <xiaofeng.ren at nxp.com>
> > > Subject: Re: [PATCH v3 2/2] cpufreq: qoriq: Don't look at clock
> > > implementation details
> > >
> > > On Thu, 2016-07-07 at 19:26 -0700, Michael Turquette wrote:
> > > > Quoting Scott Wood (2016-07-06 21:13:23)
> > > > >
> > > > > On Wed, 2016-07-06 at 18:30 -0700, Michael Turquette wrote:
> > > > > >
> > > > > > Quoting Scott Wood (2016-06-15 23:21:25)
> > > > > > >
> > > > > > >
> > > > > > > -static struct device_node *cpu_to_clk_node(int cpu)
> > > > > > > +static struct clk *cpu_to_clk(int cpu)
> > > > > > >  {
> > > > > > > -       struct device_node *np, *clk_np;
> > > > > > > +       struct device_node *np;
> > > > > > > +       struct clk *clk;
> > > > > > >
> > > > > > >         if (!cpu_present(cpu))
> > > > > > >                 return NULL; @@ -112,37 +80,28 @@ static
> > > > > > > struct device_node *cpu_to_clk_node(int
> > > > > > > cpu)
> > > > > > >         if (!np)
> > > > > > >                 return NULL;
> > > > > > >
> > > > > > > -       clk_np = of_parse_phandle(np, "clocks", 0);
> > > > > > > -       if (!clk_np)
> > > > > > > -               return NULL;
> > > > > > > -
> > > > > > > +       clk = of_clk_get(np, 0);
> > > > > > Why not use devm_clk_get here?
> > > > > devm_clk_get() is a wrapper around clk_get() which is not the
> > > > > same as of_clk_get().  What device would you pass to
> > > > > devm_clk_get(), and what name would you pass?
> > > > I'm fuzzy on whether or not you get a struct device from a cpufreq
> > > > driver. If so, then that would be the one to use. I would hope
> > > > that cpufreq drivers model cpus as devices, but I'm really not
> > > > sure without looking into the code.
> > >
> > > It's not the cpufreq code that provides it, but get_cpu_device()
> > > could be used.
> > >
> > > Do you have any comments on the first patch of this set?
> 
> 
> Any action on this patch?  This patch is still a dependency for cpufreq to work
> on all QorIQ platforms.
> 
This patch can be accepted on condition that the attached patch is accepted.
But unfortunately, the attached patch has been sent for a really long time and no feedback.

Regards,
Yuantian

> Regards,
> Leo
-------------- next part --------------
An embedded message was scrubbed...
From: Scott Wood <oss at buserror.net>
Subject: [RESEND PATCH 1/2] clk: Add consumer APIs for discovering possible parent clocks
Date: Sun, 12 Jun 2016 03:16:25 +0000
Size: 6256
URL: <http://lists.ozlabs.org/pipermail/linuxppc-dev/attachments/20170206/69b9bb1c/attachment-0001.mht>


More information about the Linuxppc-dev mailing list