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: <CAHp75VfQkAqLWSXZYsdZKDphBwGH+phXe49MA3C9kZ=DxPM0Lg@mail.gmail.com>
Date:   Thu, 17 Jun 2021 10:28:14 +0300
From:   Andy Shevchenko <andy.shevchenko@...il.com>
To:     Marcin Wojtas <mw@...ihalf.com>
Cc:     Andrew Lunn <andrew@...n.ch>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
        netdev <netdev@...r.kernel.org>,
        "David S. Miller" <davem@...emloft.net>,
        Jakub Kicinski <kuba@...nel.org>,
        Russell King - ARM Linux <linux@...linux.org.uk>,
        Grzegorz Jaszczyk <jaz@...ihalf.com>,
        Grzegorz Bernacki <gjb@...ihalf.com>, upstream@...ihalf.com,
        Samer El-Haj-Mahmoud <Samer.El-Haj-Mahmoud@....com>,
        Jon Nettleton <jon@...id-run.com>,
        Tomasz Nowicki <tn@...ihalf.com>,
        "Rafael J. Wysocki" <rjw@...ysocki.net>,
        Len Brown <lenb@...nel.org>
Subject: Re: [net-next: PATCH v2 4/7] net: mvmdio: simplify clock handling

On Thu, Jun 17, 2021 at 2:25 AM Marcin Wojtas <mw@...ihalf.com> wrote:
>
> śr., 16 cze 2021 o 21:48 Andrew Lunn <andrew@...n.ch> napisał(a):
> >
> > > +     dev->clks[0].id = "core";
> > > +     dev->clks[1].id = "mg";
> > > +     dev->clks[2].id = "mg_core";
> > > +     dev->clks[3].id = "axi";
> > > +     ret = devm_clk_bulk_get_optional(&pdev->dev, MVMDIO_CLOCK_COUNT,
> > > +                                      dev->clks);
> >
> > Kirkwood:
> >
> >                 mdio: mdio-bus@...04 {
> >                         compatible = "marvell,orion-mdio";
> >                         #address-cells = <1>;
> >                         #size-cells = <0>;
> >                         reg = <0x72004 0x84>;
> >                         interrupts = <46>;
> >                         clocks = <&gate_clk 0>;
> >                         status = "disabled";
> >
> > Does this work? There is no clock-names in DT.
> >
>
> Neither are the clocks in Armada 7k8k / CN913x:
>
>                 CP11X_LABEL(mdio): mdio@...200 {
>                         #address-cells = <1>;
>                         #size-cells = <0>;
>                         compatible = "marvell,orion-mdio";
>                         reg = <0x12a200 0x10>;
>                         clocks = <&CP11X_LABEL(clk) 1 9>,
> <&CP11X_LABEL(clk) 1 5>,
>                                  <&CP11X_LABEL(clk) 1 6>,
> <&CP11X_LABEL(clk) 1 18>;
>                         status = "disabled";
>                 };
>
> Apparently I misread the code and got convinced that contrary to
> devm_clk_get_optional(), the devm_clk_get_bulk_optional() obtains the
> clocks directly by index, not name (on the tested boards, the same
> clocks are enabled by the other interfaces, so the problems

Me too. Sorry for the wrong suggestion. I think we need something that
actually gets clocks by indices in a bulk, but this is another story.

> I will drop this patch. Thank you for spotting the issue.

I'm fine with this.

-- 
With Best Regards,
Andy Shevchenko

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ