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] [day] [month] [year] [list]
Date:   Wed, 24 Jun 2020 09:34:13 +0200
From:   Geert Uytterhoeven <geert@...ux-m68k.org>
To:     Adam Ford <aford173@...il.com>
Cc:     linux-clk <linux-clk@...r.kernel.org>,
        Michael Turquette <mturquette@...libre.com>,
        Stephen Boyd <sboyd@...nel.org>,
        Rob Herring <robh+dt@...nel.org>,
        Marek Vasut <marek.vasut@...il.com>,
        "open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS" 
        <devicetree@...r.kernel.org>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH V3 1/3] clk: vc5: Allow Versaclock driver to support
 multiple instances

Hi Adam,

On Wed, Jun 3, 2020 at 5:44 PM Adam Ford <aford173@...il.com> wrote:
> Currently, the Versaclock driver is only expecting one instance and
> uses hard-coded names for the various clock names.  Unfortunately,
> this is a problem when there is more than one instance of the driver,
> because the subsequent instantiations of the driver use the identical
> name.  Each clock after the fist fails to load, because the clock
> subsystem cannot handle two clocks with identical name.

Thanks for your patch, which is now commit f491276a51685987 ("clk: vc5:
Allow Versaclock driver to support multiple instances") in clk-next.

> This patch removes the hard-coded name arrays and uses kasprintf to
> assign clock names based on names of their respective node and parent
> node which gives each clock a unique identifying name.
>
> For a verasaclock node with a name like:
>    versaclock5: versaclock_som@6a
>
> The updated clock names would appear like:
>     versaclock_som.mux
>        versaclock_som.out0_sel_i2cb
>        versaclock_som.pfd
>           versaclock_som.pll
>              versaclock_som.fod3
>                 versaclock_som.out4
>              versaclock_som.fod2
>                 versaclock_som.out3
>              versaclock_som.fod1
>                 versaclock_som.out2
>              versaclock_som.fod0
>                 versaclock_som.out1

I'm afraid this won't help, as all versaclock nodes should be named
"clock-controller@<unit-address>", as per DT generic node name
recommendations.
Incorporating the unit-address won't help, as you can have multiple
i2c buses in the system.
How do other drivers handle this?

Gr{oetje,eeting}s,

                        Geert

-- 
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@...ux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ