[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20221104170031.zr76bv6u5yuxhsyq@skbuf>
Date: Fri, 4 Nov 2022 19:00:31 +0200
From: Vladimir Oltean <olteanv@...il.com>
To: Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>
Cc: Andrew Lunn <andrew@...n.ch>,
Vivien Didelot <vivien.didelot@...il.com>,
Florian Fainelli <f.fainelli@...il.com>,
"David S. Miller" <davem@...emloft.net>,
Eric Dumazet <edumazet@...gle.com>,
Jakub Kicinski <kuba@...nel.org>,
Paolo Abeni <pabeni@...hat.com>,
Rob Herring <robh+dt@...nel.org>,
Krzysztof Kozlowski <krzysztof.kozlowski+dt@...aro.org>,
netdev@...r.kernel.org, devicetree@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH v2] dt-bindings: net: nxp,sja1105: document spi-cpol/cpha
On Fri, Nov 04, 2022 at 09:09:02AM -0400, Krzysztof Kozlowski wrote:
> It is not valid to put spi-max-frequency = 1 GHz in
> spi-peripheral-props.yaml.
...
> IOW, CPHA/CPOL are not valid for most devices, so they cannot be in
> spi-peripheral-props.yaml.
Your understanding of SPI clock polarity/phase is probably not the same
as mine. "Not valid for most devices" is a gross misrepresentation.
There are 4 electrical modes of communication between a SPI controller
and a peripheral, formed by the 0/1 combination of the CPOL and CPHA bits.
Some peripherals support only a subset of these modes of operation, that
is completely true and I agree with it. But they're still SPI devices,
and all 4 modes of communication apply to them all. That's why I made
the comparison with the 1 GHz frequency. The spi-peripheral-props.yaml
schema only says what properties are valid for a peripheral, and both
CPOL and CPHA are valid for all SPI peripherals, even if some combos
don't work (when neither spi-cpol nor spi-cpha is present, they are 0
and 0, so the connection works in SPI mode 0).
Powered by blists - more mailing lists