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: <CAMuHMdUV_2DbbUqp+0=XARyLCwPya1RqFCrr6VoTJjVAZiKJzg@mail.gmail.com>
Date:   Mon, 6 Jul 2020 17:32:51 +0200
From:   Geert Uytterhoeven <geert@...ux-m68k.org>
To:     Adrian Fiergolski <adrian.fiergolski@...tree3d.com>
Cc:     Lukas Wunner <lukas@...ner.de>, Mark Brown <broonie@...nel.org>,
        Rob Herring <robh+dt@...nel.org>,
        linux-spi <linux-spi@...r.kernel.org>,
        "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 v2 2/2] dt-bindings: Add documentation for SPI daisy chain driver.

Hi Adrian,

On Mon, Jul 6, 2020 at 5:19 PM Adrian Fiergolski
<adrian.fiergolski@...tree3d.com> wrote:
> On 06.07.2020 17:10, Geert Uytterhoeven wrote:
> > On Mon, Jul 6, 2020 at 11:23 AM Adrian Fiergolski
> > <adrian.fiergolski@...tree3d.com> wrote:
> >> Add documentation for SPI daisy chain driver.
> >>
> >> Signed-off-by: Adrian Fiergolski <adrian.fiergolski@...tree3d.com>
> > Thanks for your patch!
> >
> >> --- /dev/null
> >> +++ b/Documentation/devicetree/bindings/spi/spi-daisy_chain.txt
> >> @@ -0,0 +1,56 @@
> >> +spi-daisy_chain : The driver handling SPI daisy chains.
> >> +-----------------------------------------------------------
> >> +
> >> +Required properties:
> >> +- compatible           : Should be "spi,daisy_chain"
> >> +- reg                  : Chip select assigned to the chain
> >> +
> >> +  For the SPI devices on a common SPI chain - nodes of daisy_chain):
> >> +- spi-daisy-chain-len  : Length (in bytes) of the SPI transfer,
> >> +                        when the SPI device is part of a device chain.
> >> +- spi-daisy-chain-noop : Byte string of no-operation command which should
> >> +                        be send when device is not addressed during the
> >> +                        given SPI transfer
> > The above two properties are device-specific, and the same for all
> > devices of the same type, thus leading to duplication.
> > Hence I think this should not be specified in DT, but instead handled
> > by the driver.  I.e. for Linux, you would retrieve this from struct
> > spi_device, as filled in by the slave driver.
> The problem is that then this patch would not be compatible out of the
> box with all SPI devices (as it's now) and would require rewrite (adding
> this extra information in the spi_driver struct) of all SPI drivers
> which support daisy chain.

That's correct.
However, that information would need to be added to each driver only once.
With your proposal, it has to be added to all affected nodes of all DTSes
of all users.

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