lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <163424761868.1688384.7017177221097736499@swboyd.mtv.corp.google.com>
Date:   Thu, 14 Oct 2021 14:40:18 -0700
From:   Stephen Boyd <sboyd@...nel.org>
To:     Will McVicker <willmcvicker@...gle.com>
Cc:     Chanwoo Choi <cw00.choi@...sung.com>,
        Krzysztof Kozlowski <krzysztof.kozlowski@...onical.com>,
        Michael Turquette <mturquette@...libre.com>,
        Sylwester Nawrocki <s.nawrocki@...sung.com>,
        Tomasz Figa <tomasz.figa@...il.com>, Cc:
        Android Kernel <kernel-team@...roid.com>,
        linux-samsung-soc <linux-samsung-soc@...r.kernel.org>,
        linux-clk <linux-clk@...r.kernel.org>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
        Linux ARM <linux-arm-kernel@...ts.infradead.org>, ;
Subject: Re: [PATCH v3 1/2] [RFT] clk: samsung: add support for CPU clocks

Quoting Will McVicker (2021-10-14 12:35:57)
> On Wed, Oct 13, 2021 at 6:49 PM Stephen Boyd <sboyd@...nel.org> wrote:
> >
> > Quoting Will McVicker (2021-10-13 15:10:19)
> > > diff --git a/drivers/clk/samsung/clk-cpu.c b/drivers/clk/samsung/clk-cpu.c
> > > index 00ef4d1b0888..b5017934fc41 100644
> > > --- a/drivers/clk/samsung/clk-cpu.c
> > > +++ b/drivers/clk/samsung/clk-cpu.c
> > > @@ -469,3 +469,29 @@ int __init exynos_register_cpu_clock(struct samsung_clk_provider *ctx,
> > >         kfree(cpuclk);
> > >         return ret;
> > >  }
> > > +
> > > +void samsung_clk_register_cpu(struct samsung_clk_provider *ctx,
> > > +               const struct samsung_cpu_clock *list, unsigned int nr_clk)
> > > +{
> > > +       unsigned int idx;
> > > +       unsigned int num_cfgs;
> > > +       struct clk *parent_clk, *alt_parent_clk;
> > > +       const struct clk_hw *parent_clk_hw = NULL;
> > > +       const struct clk_hw *alt_parent_clk_hw = NULL;
> > > +
> > > +       for (idx = 0; idx < nr_clk; idx++, list++) {
> > > +               /* find count of configuration rates in cfg */
> > > +               for (num_cfgs = 0; list->cfg[num_cfgs].prate != 0; )
> > > +                       num_cfgs++;
> > > +
> > > +               parent_clk = __clk_lookup(list->parent_name);
> >
> > Please stop using __clk_lookup()
> 
> Thanks, I believe I have a way around this. I'll fix this up in the
> follow-up version.

Great!

> 
> >
> > > +               if (parent_clk)
> > > +                       parent_clk_hw = __clk_get_hw(parent_clk);
> > > +               alt_parent_clk = __clk_lookup(list->alt_parent_name);
> >
> > Can the DT binding be updated?
> 
> Are you referring to removing alt_parent and just adding it as another
> parent clock?
> 

I was wondering if this is an external clk that feeds into here or if it
is all internal to the clk controller. It sounds like it's all internal
to the clk controller? In which case a binding update isn't needed.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ