linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/6] dt-bindings: iio/panel/eeprom/misc/net/spi: drop SPI CPHA and CPOL
@ 2022-07-21 15:31 Krzysztof Kozlowski
  2022-07-21 15:31 ` [PATCH 1/6] dt-bindings: panel: explicitly list " Krzysztof Kozlowski
                   ` (5 more replies)
  0 siblings, 6 replies; 11+ messages in thread
From: Krzysztof Kozlowski @ 2022-07-21 15:31 UTC (permalink / raw)
  To: Thierry Reding, Sam Ravnborg, David Airlie, Daniel Vetter,
	Rob Herring, Krzysztof Kozlowski, Linus Walleij, Markuss Broks,
	Lars-Peter Clausen, Michael Hennerich, Jonathan Cameron,
	Alexandru Tachici, Marcelo Schmitt, Tomislav Denis,
	Cosmin Tanislav, Nishant Malpani, Dragos Bogdan, Nuno Sa,
	Jean-Baptiste Maneyrol, David S. Miller, Eric Dumazet,
	Jakub Kicinski, Paolo Abeni, Mark Brown, Tomi Valkeinen,
	Andrzej Hajda, Maxime Ripard, Marek Belisko,
	H. Nikolaus Schaller, Christian Eggers, Beniamin Bia,
	Stefan Popa, Oskar Andero, Mårten Lindahl, Dan Murphy,
	Sean Nyekjaer, Cristian Pop, Lukas Wunner, Matt Ranostay,
	Matheus Tavares, Sankar Velliangiri, Lubomir Rintel,
	Stefan Wahren, Pratyush Yadav, dri-devel, devicetree,
	linux-kernel, linux-iio, linux-fbdev, netdev, linux-spi
  Cc: Krzysztof Kozlowski

Hi,

Rebased on next-20220714

Merging
=======
1. The first five patches (panel, eeprom, iio, misc and net) are independent
   and could be taken as is.
2. The last SPI patch depends on all previous five, so:
   a. either everything goes through one tree (e.g. DT bindings),
   b. or SPI patch waits one cycle till dependencies get to rcX.

Preference is (2a) - everything through one tree because I plan to include
spi-peripheral-props.yaml in several SPI client bindings (continuation of [1]).

However IIO and SPI patch might not apply cleanly on DT bindings tree, as I
based it on linux-next. I can rebase if such merging is preferred.

Description
===========
The spi-cpha and spi-cpol properties are device specific and should be
accepted only if device really needs them.  Inspired by [1].

[1] https://lore.kernel.org/all/20220718220012.GA3625497-robh@kernel.org/

Best regards,
Krzysztof

Krzysztof Kozlowski (6):
  dt-bindings: panel: explicitly list SPI CPHA and CPOL
  dt-bindings: eeprom: at25: explicitly list SPI CPHA and CPOL
  dt-bindings: iio: explicitly list SPI CPHA and CPOL
  dt-bindings: misc: explicitly list SPI CPHA and CPOL
  dt-bindings: net: explicitly list SPI CPHA and CPOL
  spi: dt-bindings: drop CPHA and CPOL from common properties

 .../bindings/display/panel/lgphilips,lb035q02.yaml   | 10 ++++++++++
 .../bindings/display/panel/samsung,ld9040.yaml       | 10 ++++++++++
 .../bindings/display/panel/samsung,lms380kf01.yaml   | 12 +++++++++---
 .../bindings/display/panel/samsung,lms397kf04.yaml   | 12 +++++++++---
 .../bindings/display/panel/samsung,s6d27a1.yaml      | 12 +++++++++---
 .../bindings/display/panel/sitronix,st7789v.yaml     | 10 ++++++++++
 .../devicetree/bindings/display/panel/tpo,td.yaml    | 10 ++++++++++
 Documentation/devicetree/bindings/eeprom/at25.yaml   | 10 ++++++++--
 .../devicetree/bindings/iio/accel/adi,adxl345.yaml   | 10 ++++++++--
 .../devicetree/bindings/iio/adc/adi,ad7192.yaml      | 10 ++++++++--
 .../devicetree/bindings/iio/adc/adi,ad7292.yaml      |  5 ++++-
 .../devicetree/bindings/iio/adc/adi,ad7606.yaml      | 10 ++++++++--
 .../devicetree/bindings/iio/adc/adi,ad7768-1.yaml    | 10 ++++++++--
 .../bindings/iio/adc/microchip,mcp3201.yaml          | 12 ++++++++++--
 .../devicetree/bindings/iio/adc/ti,adc084s021.yaml   | 11 +++++++++--
 .../devicetree/bindings/iio/adc/ti,ads124s08.yaml    |  5 ++++-
 .../devicetree/bindings/iio/adc/ti,ads131e08.yaml    |  5 ++++-
 .../devicetree/bindings/iio/addac/adi,ad74413r.yaml  |  5 ++++-
 .../devicetree/bindings/iio/dac/adi,ad5592r.yaml     |  5 ++++-
 .../devicetree/bindings/iio/dac/adi,ad5755.yaml      | 10 ++++++++--
 .../devicetree/bindings/iio/dac/adi,ad5758.yaml      |  6 +++++-
 .../devicetree/bindings/iio/dac/adi,ad5766.yaml      |  5 ++++-
 .../devicetree/bindings/iio/dac/ti,dac082s085.yaml   |  9 +++++++--
 .../bindings/iio/gyroscope/adi,adxrs290.yaml         | 10 ++++++++--
 .../devicetree/bindings/iio/imu/adi,adis16460.yaml   | 12 +++++++++---
 .../devicetree/bindings/iio/imu/adi,adis16475.yaml   | 10 ++++++++--
 .../devicetree/bindings/iio/imu/adi,adis16480.yaml   | 11 +++++++++--
 .../bindings/iio/imu/invensense,icm42600.yaml        | 12 ++++++++++--
 .../bindings/iio/proximity/ams,as3935.yaml           |  5 ++++-
 .../devicetree/bindings/iio/resolver/adi,ad2s90.yaml | 10 ++++++++--
 .../bindings/iio/temperature/maxim,max31855k.yaml    |  6 +++++-
 .../bindings/iio/temperature/maxim,max31856.yaml     |  6 +++++-
 .../bindings/iio/temperature/maxim,max31865.yaml     |  6 +++++-
 .../devicetree/bindings/misc/olpc,xo1.75-ec.yaml     |  5 ++++-
 .../devicetree/bindings/net/nfc/marvell,nci.yaml     | 12 ++++++++++--
 .../devicetree/bindings/net/vertexcom-mse102x.yaml   | 12 +++++++++---
 .../bindings/spi/spi-peripheral-props.yaml           | 10 ----------
 37 files changed, 264 insertions(+), 67 deletions(-)

-- 
2.34.1


^ permalink raw reply	[flat|nested] 11+ messages in thread

* [PATCH 1/6] dt-bindings: panel: explicitly list SPI CPHA and CPOL
  2022-07-21 15:31 [PATCH 0/6] dt-bindings: iio/panel/eeprom/misc/net/spi: drop SPI CPHA and CPOL Krzysztof Kozlowski
@ 2022-07-21 15:31 ` Krzysztof Kozlowski
  2022-07-21 19:30   ` Rob Herring
  2022-07-21 15:31 ` [PATCH 2/6] dt-bindings: eeprom: at25: " Krzysztof Kozlowski
                   ` (4 subsequent siblings)
  5 siblings, 1 reply; 11+ messages in thread
From: Krzysztof Kozlowski @ 2022-07-21 15:31 UTC (permalink / raw)
  To: Thierry Reding, Sam Ravnborg, David Airlie, Daniel Vetter,
	Rob Herring, Krzysztof Kozlowski, Linus Walleij, Markuss Broks,
	Lars-Peter Clausen, Michael Hennerich, Jonathan Cameron,
	Alexandru Tachici, Marcelo Schmitt, Tomislav Denis,
	Cosmin Tanislav, Nishant Malpani, Dragos Bogdan, Nuno Sa,
	Jean-Baptiste Maneyrol, David S. Miller, Eric Dumazet,
	Jakub Kicinski, Paolo Abeni, Mark Brown, Tomi Valkeinen,
	Andrzej Hajda, Maxime Ripard, Marek Belisko,
	H. Nikolaus Schaller, Christian Eggers, Beniamin Bia,
	Stefan Popa, Oskar Andero, Mårten Lindahl, Dan Murphy,
	Sean Nyekjaer, Cristian Pop, Lukas Wunner, Matt Ranostay,
	Matheus Tavares, Sankar Velliangiri, Lubomir Rintel,
	Stefan Wahren, Pratyush Yadav, dri-devel, devicetree,
	linux-kernel, linux-iio, linux-fbdev, netdev, linux-spi
  Cc: Krzysztof Kozlowski

The spi-cpha and spi-cpol properties are device specific and should be
accepted only if device really needs them.  Explicitly list them in
device bindings in preparation of their removal from generic
spi-peripheral-props.yaml schema.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 .../bindings/display/panel/lgphilips,lb035q02.yaml   | 10 ++++++++++
 .../bindings/display/panel/samsung,ld9040.yaml       | 10 ++++++++++
 .../bindings/display/panel/samsung,lms380kf01.yaml   | 12 +++++++++---
 .../bindings/display/panel/samsung,lms397kf04.yaml   | 12 +++++++++---
 .../bindings/display/panel/samsung,s6d27a1.yaml      | 12 +++++++++---
 .../bindings/display/panel/sitronix,st7789v.yaml     | 10 ++++++++++
 .../devicetree/bindings/display/panel/tpo,td.yaml    | 10 ++++++++++
 7 files changed, 67 insertions(+), 9 deletions(-)

diff --git a/Documentation/devicetree/bindings/display/panel/lgphilips,lb035q02.yaml b/Documentation/devicetree/bindings/display/panel/lgphilips,lb035q02.yaml
index 5e4e0e552c2f..0bd7bbad5b94 100644
--- a/Documentation/devicetree/bindings/display/panel/lgphilips,lb035q02.yaml
+++ b/Documentation/devicetree/bindings/display/panel/lgphilips,lb035q02.yaml
@@ -21,6 +21,16 @@ properties:
   enable-gpios: true
   port: true
 
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
+
+  spi-cpol:
+    type: boolean
+    description:
+      The device requires inverse clock polarity (CPOL) mode.
+
 required:
   - compatible
   - enable-gpios
diff --git a/Documentation/devicetree/bindings/display/panel/samsung,ld9040.yaml b/Documentation/devicetree/bindings/display/panel/samsung,ld9040.yaml
index d525165d6d63..ee6a61549916 100644
--- a/Documentation/devicetree/bindings/display/panel/samsung,ld9040.yaml
+++ b/Documentation/devicetree/bindings/display/panel/samsung,ld9040.yaml
@@ -42,6 +42,16 @@ properties:
   panel-height-mm:
     description: physical panel height [mm]
 
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
+
+  spi-cpol:
+    type: boolean
+    description:
+      The device requires inverse clock polarity (CPOL) mode.
+
 required:
   - compatible
   - reg
diff --git a/Documentation/devicetree/bindings/display/panel/samsung,lms380kf01.yaml b/Documentation/devicetree/bindings/display/panel/samsung,lms380kf01.yaml
index 251f0c7115aa..7f010cb4aa20 100644
--- a/Documentation/devicetree/bindings/display/panel/samsung,lms380kf01.yaml
+++ b/Documentation/devicetree/bindings/display/panel/samsung,lms380kf01.yaml
@@ -43,9 +43,15 @@ properties:
 
   backlight: true
 
-  spi-cpha: true
-
-  spi-cpol: true
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
+
+  spi-cpol:
+    type: boolean
+    description:
+      The device requires inverse clock polarity (CPOL) mode.
 
   spi-max-frequency:
     maximum: 1200000
diff --git a/Documentation/devicetree/bindings/display/panel/samsung,lms397kf04.yaml b/Documentation/devicetree/bindings/display/panel/samsung,lms397kf04.yaml
index cd62968426fb..794da8b45896 100644
--- a/Documentation/devicetree/bindings/display/panel/samsung,lms397kf04.yaml
+++ b/Documentation/devicetree/bindings/display/panel/samsung,lms397kf04.yaml
@@ -33,9 +33,15 @@ properties:
 
   backlight: true
 
-  spi-cpha: true
-
-  spi-cpol: true
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
+
+  spi-cpol:
+    type: boolean
+    description:
+      The device requires inverse clock polarity (CPOL) mode.
 
   spi-max-frequency:
     description: inherited as a SPI client node, the datasheet specifies
diff --git a/Documentation/devicetree/bindings/display/panel/samsung,s6d27a1.yaml b/Documentation/devicetree/bindings/display/panel/samsung,s6d27a1.yaml
index 26e3c820a2f7..468111b1a1b4 100644
--- a/Documentation/devicetree/bindings/display/panel/samsung,s6d27a1.yaml
+++ b/Documentation/devicetree/bindings/display/panel/samsung,s6d27a1.yaml
@@ -41,9 +41,15 @@ properties:
 
   backlight: true
 
-  spi-cpha: true
-
-  spi-cpol: true
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
+
+  spi-cpol:
+    type: boolean
+    description:
+      The device requires inverse clock polarity (CPOL) mode.
 
   spi-max-frequency:
     maximum: 1200000
diff --git a/Documentation/devicetree/bindings/display/panel/sitronix,st7789v.yaml b/Documentation/devicetree/bindings/display/panel/sitronix,st7789v.yaml
index 9e1d707c2ace..0eea7de51689 100644
--- a/Documentation/devicetree/bindings/display/panel/sitronix,st7789v.yaml
+++ b/Documentation/devicetree/bindings/display/panel/sitronix,st7789v.yaml
@@ -23,6 +23,16 @@ properties:
   backlight: true
   port: true
 
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
+
+  spi-cpol:
+    type: boolean
+    description:
+      The device requires inverse clock polarity (CPOL) mode.
+
 required:
   - compatible
   - reg
diff --git a/Documentation/devicetree/bindings/display/panel/tpo,td.yaml b/Documentation/devicetree/bindings/display/panel/tpo,td.yaml
index f902a9d74141..9b0e8659d6bd 100644
--- a/Documentation/devicetree/bindings/display/panel/tpo,td.yaml
+++ b/Documentation/devicetree/bindings/display/panel/tpo,td.yaml
@@ -28,6 +28,16 @@ properties:
   backlight: true
   port: true
 
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
+
+  spi-cpol:
+    type: boolean
+    description:
+      The device requires inverse clock polarity (CPOL) mode.
+
 required:
   - compatible
   - port
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH 2/6] dt-bindings: eeprom: at25: explicitly list SPI CPHA and CPOL
  2022-07-21 15:31 [PATCH 0/6] dt-bindings: iio/panel/eeprom/misc/net/spi: drop SPI CPHA and CPOL Krzysztof Kozlowski
  2022-07-21 15:31 ` [PATCH 1/6] dt-bindings: panel: explicitly list " Krzysztof Kozlowski
@ 2022-07-21 15:31 ` Krzysztof Kozlowski
  2022-07-21 15:31 ` [PATCH 3/6] dt-bindings: iio: " Krzysztof Kozlowski
                   ` (3 subsequent siblings)
  5 siblings, 0 replies; 11+ messages in thread
From: Krzysztof Kozlowski @ 2022-07-21 15:31 UTC (permalink / raw)
  To: Thierry Reding, Sam Ravnborg, David Airlie, Daniel Vetter,
	Rob Herring, Krzysztof Kozlowski, Linus Walleij, Markuss Broks,
	Lars-Peter Clausen, Michael Hennerich, Jonathan Cameron,
	Alexandru Tachici, Marcelo Schmitt, Tomislav Denis,
	Cosmin Tanislav, Nishant Malpani, Dragos Bogdan, Nuno Sa,
	Jean-Baptiste Maneyrol, David S. Miller, Eric Dumazet,
	Jakub Kicinski, Paolo Abeni, Mark Brown, Tomi Valkeinen,
	Andrzej Hajda, Maxime Ripard, Marek Belisko,
	H. Nikolaus Schaller, Christian Eggers, Beniamin Bia,
	Stefan Popa, Oskar Andero, Mårten Lindahl, Dan Murphy,
	Sean Nyekjaer, Cristian Pop, Lukas Wunner, Matt Ranostay,
	Matheus Tavares, Sankar Velliangiri, Lubomir Rintel,
	Stefan Wahren, Pratyush Yadav, dri-devel, devicetree,
	linux-kernel, linux-iio, linux-fbdev, netdev, linux-spi
  Cc: Krzysztof Kozlowski

The spi-cpha and spi-cpol properties are device specific and should be
accepted only if device really needs them.  Explicitly list them in
device bindings in preparation of their removal from generic
spi-peripheral-props.yaml schema.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 Documentation/devicetree/bindings/eeprom/at25.yaml | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/Documentation/devicetree/bindings/eeprom/at25.yaml b/Documentation/devicetree/bindings/eeprom/at25.yaml
index fbf99e346966..64666624b6aa 100644
--- a/Documentation/devicetree/bindings/eeprom/at25.yaml
+++ b/Documentation/devicetree/bindings/eeprom/at25.yaml
@@ -65,9 +65,15 @@ properties:
       For 9 bits, the MSB of the address is sent as bit 3 of the instruction
       byte, before the address byte.
 
-  spi-cpha: true
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
 
-  spi-cpol: true
+  spi-cpol:
+    type: boolean
+    description:
+      The device requires inverse clock polarity (CPOL) mode.
 
   read-only:
     description:
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH 3/6] dt-bindings: iio: explicitly list SPI CPHA and CPOL
  2022-07-21 15:31 [PATCH 0/6] dt-bindings: iio/panel/eeprom/misc/net/spi: drop SPI CPHA and CPOL Krzysztof Kozlowski
  2022-07-21 15:31 ` [PATCH 1/6] dt-bindings: panel: explicitly list " Krzysztof Kozlowski
  2022-07-21 15:31 ` [PATCH 2/6] dt-bindings: eeprom: at25: " Krzysztof Kozlowski
@ 2022-07-21 15:31 ` Krzysztof Kozlowski
  2022-07-21 19:32   ` Rob Herring
  2022-07-21 15:31 ` [PATCH 4/6] dt-bindings: misc: " Krzysztof Kozlowski
                   ` (2 subsequent siblings)
  5 siblings, 1 reply; 11+ messages in thread
From: Krzysztof Kozlowski @ 2022-07-21 15:31 UTC (permalink / raw)
  To: Thierry Reding, Sam Ravnborg, David Airlie, Daniel Vetter,
	Rob Herring, Krzysztof Kozlowski, Linus Walleij, Markuss Broks,
	Lars-Peter Clausen, Michael Hennerich, Jonathan Cameron,
	Alexandru Tachici, Marcelo Schmitt, Tomislav Denis,
	Cosmin Tanislav, Nishant Malpani, Dragos Bogdan, Nuno Sa,
	Jean-Baptiste Maneyrol, David S. Miller, Eric Dumazet,
	Jakub Kicinski, Paolo Abeni, Mark Brown, Tomi Valkeinen,
	Andrzej Hajda, Maxime Ripard, Marek Belisko,
	H. Nikolaus Schaller, Christian Eggers, Beniamin Bia,
	Stefan Popa, Oskar Andero, Mårten Lindahl, Dan Murphy,
	Sean Nyekjaer, Cristian Pop, Lukas Wunner, Matt Ranostay,
	Matheus Tavares, Sankar Velliangiri, Lubomir Rintel,
	Stefan Wahren, Pratyush Yadav, dri-devel, devicetree,
	linux-kernel, linux-iio, linux-fbdev, netdev, linux-spi
  Cc: Krzysztof Kozlowski

The spi-cpha and spi-cpol properties are device specific and should be
accepted only if device really needs them.  Explicitly list them in
device bindings in preparation of their removal from generic
spi-peripheral-props.yaml schema.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 .../devicetree/bindings/iio/accel/adi,adxl345.yaml   | 10 ++++++++--
 .../devicetree/bindings/iio/adc/adi,ad7192.yaml      | 10 ++++++++--
 .../devicetree/bindings/iio/adc/adi,ad7292.yaml      |  5 ++++-
 .../devicetree/bindings/iio/adc/adi,ad7606.yaml      | 10 ++++++++--
 .../devicetree/bindings/iio/adc/adi,ad7768-1.yaml    | 10 ++++++++--
 .../bindings/iio/adc/microchip,mcp3201.yaml          | 12 ++++++++++--
 .../devicetree/bindings/iio/adc/ti,adc084s021.yaml   | 11 +++++++++--
 .../devicetree/bindings/iio/adc/ti,ads124s08.yaml    |  5 ++++-
 .../devicetree/bindings/iio/adc/ti,ads131e08.yaml    |  5 ++++-
 .../devicetree/bindings/iio/addac/adi,ad74413r.yaml  |  5 ++++-
 .../devicetree/bindings/iio/dac/adi,ad5592r.yaml     |  5 ++++-
 .../devicetree/bindings/iio/dac/adi,ad5755.yaml      | 10 ++++++++--
 .../devicetree/bindings/iio/dac/adi,ad5758.yaml      |  6 +++++-
 .../devicetree/bindings/iio/dac/adi,ad5766.yaml      |  5 ++++-
 .../devicetree/bindings/iio/dac/ti,dac082s085.yaml   |  9 +++++++--
 .../bindings/iio/gyroscope/adi,adxrs290.yaml         | 10 ++++++++--
 .../devicetree/bindings/iio/imu/adi,adis16460.yaml   | 12 +++++++++---
 .../devicetree/bindings/iio/imu/adi,adis16475.yaml   | 10 ++++++++--
 .../devicetree/bindings/iio/imu/adi,adis16480.yaml   | 11 +++++++++--
 .../bindings/iio/imu/invensense,icm42600.yaml        | 12 ++++++++++--
 .../bindings/iio/proximity/ams,as3935.yaml           |  5 ++++-
 .../devicetree/bindings/iio/resolver/adi,ad2s90.yaml | 10 ++++++++--
 .../bindings/iio/temperature/maxim,max31855k.yaml    |  6 +++++-
 .../bindings/iio/temperature/maxim,max31856.yaml     |  6 +++++-
 .../bindings/iio/temperature/maxim,max31865.yaml     |  6 +++++-
 25 files changed, 166 insertions(+), 40 deletions(-)

diff --git a/Documentation/devicetree/bindings/iio/accel/adi,adxl345.yaml b/Documentation/devicetree/bindings/iio/accel/adi,adxl345.yaml
index 9bb039e2f533..0b498b9c9823 100644
--- a/Documentation/devicetree/bindings/iio/accel/adi,adxl345.yaml
+++ b/Documentation/devicetree/bindings/iio/accel/adi,adxl345.yaml
@@ -28,9 +28,15 @@ properties:
   reg:
     maxItems: 1
 
-  spi-cpha: true
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
 
-  spi-cpol: true
+  spi-cpol:
+    type: boolean
+    description:
+      The device requires inverse clock polarity (CPOL) mode.
 
   spi-max-frequency: true
 
diff --git a/Documentation/devicetree/bindings/iio/adc/adi,ad7192.yaml b/Documentation/devicetree/bindings/iio/adc/adi,ad7192.yaml
index 22b7ed3723f6..d533eb6e9233 100644
--- a/Documentation/devicetree/bindings/iio/adc/adi,ad7192.yaml
+++ b/Documentation/devicetree/bindings/iio/adc/adi,ad7192.yaml
@@ -26,9 +26,15 @@ properties:
   reg:
     maxItems: 1
 
-  spi-cpol: true
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
 
-  spi-cpha: true
+  spi-cpol:
+    type: boolean
+    description:
+      The device requires inverse clock polarity (CPOL) mode.
 
   spi-max-frequency: true
 
diff --git a/Documentation/devicetree/bindings/iio/adc/adi,ad7292.yaml b/Documentation/devicetree/bindings/iio/adc/adi,ad7292.yaml
index a3e39a40c9b3..c0be5c87bd5c 100644
--- a/Documentation/devicetree/bindings/iio/adc/adi,ad7292.yaml
+++ b/Documentation/devicetree/bindings/iio/adc/adi,ad7292.yaml
@@ -28,7 +28,10 @@ properties:
     description: |
       The regulator supply for ADC and DAC reference voltage.
 
-  spi-cpha: true
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
 
   spi-max-frequency: true
 
diff --git a/Documentation/devicetree/bindings/iio/adc/adi,ad7606.yaml b/Documentation/devicetree/bindings/iio/adc/adi,ad7606.yaml
index 73775174cf57..181358c90f8e 100644
--- a/Documentation/devicetree/bindings/iio/adc/adi,ad7606.yaml
+++ b/Documentation/devicetree/bindings/iio/adc/adi,ad7606.yaml
@@ -29,9 +29,15 @@ properties:
   reg:
     maxItems: 1
 
-  spi-cpha: true
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
 
-  spi-cpol: true
+  spi-cpol:
+    type: boolean
+    description:
+      The device requires inverse clock polarity (CPOL) mode.
 
   spi-max-frequency: true
 
diff --git a/Documentation/devicetree/bindings/iio/adc/adi,ad7768-1.yaml b/Documentation/devicetree/bindings/iio/adc/adi,ad7768-1.yaml
index a85a28145ef6..6f9457f41ac3 100644
--- a/Documentation/devicetree/bindings/iio/adc/adi,ad7768-1.yaml
+++ b/Documentation/devicetree/bindings/iio/adc/adi,ad7768-1.yaml
@@ -52,9 +52,15 @@ properties:
 
   spi-max-frequency: true
 
-  spi-cpol: true
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
 
-  spi-cpha: true
+  spi-cpol:
+    type: boolean
+    description:
+      The device requires inverse clock polarity (CPOL) mode.
 
   "#io-channel-cells":
     const: 1
diff --git a/Documentation/devicetree/bindings/iio/adc/microchip,mcp3201.yaml b/Documentation/devicetree/bindings/iio/adc/microchip,mcp3201.yaml
index fcc1ba53b20d..b880354567e3 100644
--- a/Documentation/devicetree/bindings/iio/adc/microchip,mcp3201.yaml
+++ b/Documentation/devicetree/bindings/iio/adc/microchip,mcp3201.yaml
@@ -33,8 +33,16 @@ properties:
     maxItems: 1
 
   spi-max-frequency: true
-  spi-cpha: true
-  spi-cpol: true
+
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
+
+  spi-cpol:
+    type: boolean
+    description:
+      The device requires inverse clock polarity (CPOL) mode.
 
   vref-supply:
     description: External reference.
diff --git a/Documentation/devicetree/bindings/iio/adc/ti,adc084s021.yaml b/Documentation/devicetree/bindings/iio/adc/ti,adc084s021.yaml
index 1a113b30a414..07e1d54e93fe 100644
--- a/Documentation/devicetree/bindings/iio/adc/ti,adc084s021.yaml
+++ b/Documentation/devicetree/bindings/iio/adc/ti,adc084s021.yaml
@@ -24,8 +24,15 @@ properties:
   vref-supply:
     description: External reference, needed to establish input scaling
 
-  spi-cpol: true
-  spi-cpha: true
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
+
+  spi-cpol:
+    type: boolean
+    description:
+      The device requires inverse clock polarity (CPOL) mode.
 
   "#io-channel-cells":
     const: 1
diff --git a/Documentation/devicetree/bindings/iio/adc/ti,ads124s08.yaml b/Documentation/devicetree/bindings/iio/adc/ti,ads124s08.yaml
index 9f5e96439c01..74be1b4a4c27 100644
--- a/Documentation/devicetree/bindings/iio/adc/ti,ads124s08.yaml
+++ b/Documentation/devicetree/bindings/iio/adc/ti,ads124s08.yaml
@@ -20,7 +20,10 @@ properties:
 
   spi-max-frequency: true
 
-  spi-cpha: true
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
 
   reset-gpios:
     maxItems: 1
diff --git a/Documentation/devicetree/bindings/iio/adc/ti,ads131e08.yaml b/Documentation/devicetree/bindings/iio/adc/ti,ads131e08.yaml
index e0670e3fbb72..b05426a4cae5 100644
--- a/Documentation/devicetree/bindings/iio/adc/ti,ads131e08.yaml
+++ b/Documentation/devicetree/bindings/iio/adc/ti,ads131e08.yaml
@@ -30,7 +30,10 @@ properties:
 
   spi-max-frequency: true
 
-  spi-cpha: true
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
 
   clocks:
     description: |
diff --git a/Documentation/devicetree/bindings/iio/addac/adi,ad74413r.yaml b/Documentation/devicetree/bindings/iio/addac/adi,ad74413r.yaml
index baa65a521bad..5f5354601a0f 100644
--- a/Documentation/devicetree/bindings/iio/addac/adi,ad74413r.yaml
+++ b/Documentation/devicetree/bindings/iio/addac/adi,ad74413r.yaml
@@ -39,7 +39,10 @@ properties:
   spi-max-frequency:
     maximum: 1000000
 
-  spi-cpol: true
+  spi-cpol:
+    type: boolean
+    description:
+      The device requires inverse clock polarity (CPOL) mode.
 
   interrupts:
     maxItems: 1
diff --git a/Documentation/devicetree/bindings/iio/dac/adi,ad5592r.yaml b/Documentation/devicetree/bindings/iio/dac/adi,ad5592r.yaml
index 30194880f457..7f094e31bddc 100644
--- a/Documentation/devicetree/bindings/iio/dac/adi,ad5592r.yaml
+++ b/Documentation/devicetree/bindings/iio/dac/adi,ad5592r.yaml
@@ -21,7 +21,10 @@ properties:
   spi-max-frequency:
     maximum: 30000000
 
-  spi-cpol: true
+  spi-cpol:
+    type: boolean
+    description:
+      The device requires inverse clock polarity (CPOL) mode.
 
   "#address-cells":
     const: 1
diff --git a/Documentation/devicetree/bindings/iio/dac/adi,ad5755.yaml b/Documentation/devicetree/bindings/iio/dac/adi,ad5755.yaml
index f866b88e1440..11cec9c991c0 100644
--- a/Documentation/devicetree/bindings/iio/dac/adi,ad5755.yaml
+++ b/Documentation/devicetree/bindings/iio/dac/adi,ad5755.yaml
@@ -22,8 +22,14 @@ properties:
     maxItems: 1
 
   spi-cpha:
-    description: Either this or spi-cpol but not both.
-  spi-cpol: true
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
+
+  spi-cpol:
+    type: boolean
+    description:
+      The device requires inverse clock polarity (CPOL) mode.
 
   spi-max-frequency: true
 
diff --git a/Documentation/devicetree/bindings/iio/dac/adi,ad5758.yaml b/Documentation/devicetree/bindings/iio/dac/adi,ad5758.yaml
index fd4edca34a28..4efcc2c7eaf8 100644
--- a/Documentation/devicetree/bindings/iio/dac/adi,ad5758.yaml
+++ b/Documentation/devicetree/bindings/iio/dac/adi,ad5758.yaml
@@ -17,7 +17,11 @@ properties:
     maxItems: 1
 
   spi-max-frequency: true
-  spi-cpha: true
+
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
 
   adi,dc-dc-mode:
     $ref: /schemas/types.yaml#/definitions/uint32
diff --git a/Documentation/devicetree/bindings/iio/dac/adi,ad5766.yaml b/Documentation/devicetree/bindings/iio/dac/adi,ad5766.yaml
index a8f7720d1e3e..ceea30f3af55 100644
--- a/Documentation/devicetree/bindings/iio/dac/adi,ad5766.yaml
+++ b/Documentation/devicetree/bindings/iio/dac/adi,ad5766.yaml
@@ -30,7 +30,10 @@ properties:
   spi-max-frequency:
     maximum: 1000000
 
-  spi-cpol: true
+  spi-cpol:
+    type: boolean
+    description:
+      The device requires inverse clock polarity (CPOL) mode.
 
   reset-gpios:
     description: GPIO spec for the RESET pin. As the line is active low, it
diff --git a/Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml b/Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml
index b0157050f1ee..31e909eca988 100644
--- a/Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml
+++ b/Documentation/devicetree/bindings/iio/dac/ti,dac082s085.yaml
@@ -25,10 +25,15 @@ properties:
   reg:
     maxItems: 1
 
-  spi-cpha: true
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
+
   spi-cpol:
+    type: boolean
     description:
-      Must be either spi-cpha, or spi-cpol but not both.
+      The device requires inverse clock polarity (CPOL) mode.
 
   vref-supply:
     description: Needed to provide output scaling.
diff --git a/Documentation/devicetree/bindings/iio/gyroscope/adi,adxrs290.yaml b/Documentation/devicetree/bindings/iio/gyroscope/adi,adxrs290.yaml
index 662ec59ca0af..5462efc1b87f 100644
--- a/Documentation/devicetree/bindings/iio/gyroscope/adi,adxrs290.yaml
+++ b/Documentation/devicetree/bindings/iio/gyroscope/adi,adxrs290.yaml
@@ -24,9 +24,15 @@ properties:
   spi-max-frequency:
     maximum: 5000000
 
-  spi-cpol: true
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
 
-  spi-cpha: true
+  spi-cpol:
+    type: boolean
+    description:
+      The device requires inverse clock polarity (CPOL) mode.
 
   interrupts:
     maxItems: 1
diff --git a/Documentation/devicetree/bindings/iio/imu/adi,adis16460.yaml b/Documentation/devicetree/bindings/iio/imu/adi,adis16460.yaml
index 340be256f283..f28833915f2b 100644
--- a/Documentation/devicetree/bindings/iio/imu/adi,adis16460.yaml
+++ b/Documentation/devicetree/bindings/iio/imu/adi,adis16460.yaml
@@ -21,9 +21,15 @@ properties:
   reg:
     maxItems: 1
 
-  spi-cpha: true
-
-  spi-cpol: true
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
+
+  spi-cpol:
+    type: boolean
+    description:
+      The device requires inverse clock polarity (CPOL) mode.
 
   spi-max-frequency: true
 
diff --git a/Documentation/devicetree/bindings/iio/imu/adi,adis16475.yaml b/Documentation/devicetree/bindings/iio/imu/adi,adis16475.yaml
index a7574210175a..5ae163819a24 100644
--- a/Documentation/devicetree/bindings/iio/imu/adi,adis16475.yaml
+++ b/Documentation/devicetree/bindings/iio/imu/adi,adis16475.yaml
@@ -40,9 +40,15 @@ properties:
   reg:
     maxItems: 1
 
-  spi-cpha: true
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
 
-  spi-cpol: true
+  spi-cpol:
+    type: boolean
+    description:
+      The device requires inverse clock polarity (CPOL) mode.
 
   spi-max-frequency:
     maximum: 2000000
diff --git a/Documentation/devicetree/bindings/iio/imu/adi,adis16480.yaml b/Documentation/devicetree/bindings/iio/imu/adi,adis16480.yaml
index dd29dc6c4c19..dab503b54ad0 100644
--- a/Documentation/devicetree/bindings/iio/imu/adi,adis16480.yaml
+++ b/Documentation/devicetree/bindings/iio/imu/adi,adis16480.yaml
@@ -49,8 +49,15 @@ properties:
 
   spi-max-frequency: true
 
-  spi-cpha: true
-  spi-cpol: true
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
+
+  spi-cpol:
+    type: boolean
+    description:
+      The device requires inverse clock polarity (CPOL) mode.
 
   reset-gpios:
     maxItems: 1
diff --git a/Documentation/devicetree/bindings/iio/imu/invensense,icm42600.yaml b/Documentation/devicetree/bindings/iio/imu/invensense,icm42600.yaml
index 4c1c083d0e92..9fe3c5993601 100644
--- a/Documentation/devicetree/bindings/iio/imu/invensense,icm42600.yaml
+++ b/Documentation/devicetree/bindings/iio/imu/invensense,icm42600.yaml
@@ -48,8 +48,16 @@ properties:
     description: Regulator that provides power to the bus
 
   spi-max-frequency: true
-  spi-cpha: true
-  spi-cpol: true
+
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
+
+  spi-cpol:
+    type: boolean
+    description:
+      The device requires inverse clock polarity (CPOL) mode.
 
 required:
   - compatible
diff --git a/Documentation/devicetree/bindings/iio/proximity/ams,as3935.yaml b/Documentation/devicetree/bindings/iio/proximity/ams,as3935.yaml
index 7fcba5d6d508..1245a4134256 100644
--- a/Documentation/devicetree/bindings/iio/proximity/ams,as3935.yaml
+++ b/Documentation/devicetree/bindings/iio/proximity/ams,as3935.yaml
@@ -23,7 +23,10 @@ properties:
   spi-max-frequency:
     maximum: 2000000
 
-  spi-cpha: true
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
 
   interrupts:
     maxItems: 1
diff --git a/Documentation/devicetree/bindings/iio/resolver/adi,ad2s90.yaml b/Documentation/devicetree/bindings/iio/resolver/adi,ad2s90.yaml
index 81e4bdfc17c4..38c0acb96dd6 100644
--- a/Documentation/devicetree/bindings/iio/resolver/adi,ad2s90.yaml
+++ b/Documentation/devicetree/bindings/iio/resolver/adi,ad2s90.yaml
@@ -29,9 +29,15 @@ properties:
       most 2 * 600ns, so the max frequency should be 1 / (2 * 6e-7), which gives
       roughly 830000Hz.
 
-  spi-cpol: true
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
 
-  spi-cpha: true
+  spi-cpol:
+    type: boolean
+    description:
+      The device requires inverse clock polarity (CPOL) mode.
 
 additionalProperties: false
 
diff --git a/Documentation/devicetree/bindings/iio/temperature/maxim,max31855k.yaml b/Documentation/devicetree/bindings/iio/temperature/maxim,max31855k.yaml
index 9969bac66aa1..9bbff1a5c0a7 100644
--- a/Documentation/devicetree/bindings/iio/temperature/maxim,max31855k.yaml
+++ b/Documentation/devicetree/bindings/iio/temperature/maxim,max31855k.yaml
@@ -33,7 +33,11 @@ properties:
     maxItems: 1
 
   spi-max-frequency: true
-  spi-cpha: true
+
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
 
 required:
   - compatible
diff --git a/Documentation/devicetree/bindings/iio/temperature/maxim,max31856.yaml b/Documentation/devicetree/bindings/iio/temperature/maxim,max31856.yaml
index 873b34766676..44e53f0c84ba 100644
--- a/Documentation/devicetree/bindings/iio/temperature/maxim,max31856.yaml
+++ b/Documentation/devicetree/bindings/iio/temperature/maxim,max31856.yaml
@@ -20,7 +20,11 @@ properties:
     maxItems: 1
 
   spi-max-frequency: true
-  spi-cpha: true
+
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
 
   thermocouple-type:
     $ref: /schemas/types.yaml#/definitions/uint32
diff --git a/Documentation/devicetree/bindings/iio/temperature/maxim,max31865.yaml b/Documentation/devicetree/bindings/iio/temperature/maxim,max31865.yaml
index aafb33b16549..f1b6b151ebc9 100644
--- a/Documentation/devicetree/bindings/iio/temperature/maxim,max31865.yaml
+++ b/Documentation/devicetree/bindings/iio/temperature/maxim,max31865.yaml
@@ -26,7 +26,11 @@ properties:
     type: boolean
 
   spi-max-frequency: true
-  spi-cpha: true
+
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
 
 required:
   - compatible
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH 4/6] dt-bindings: misc: explicitly list SPI CPHA and CPOL
  2022-07-21 15:31 [PATCH 0/6] dt-bindings: iio/panel/eeprom/misc/net/spi: drop SPI CPHA and CPOL Krzysztof Kozlowski
                   ` (2 preceding siblings ...)
  2022-07-21 15:31 ` [PATCH 3/6] dt-bindings: iio: " Krzysztof Kozlowski
@ 2022-07-21 15:31 ` Krzysztof Kozlowski
  2022-07-21 15:31 ` [PATCH 5/6] dt-bindings: net: " Krzysztof Kozlowski
  2022-07-21 15:31 ` [PATCH 6/6] spi: dt-bindings: drop CPHA and CPOL from common properties Krzysztof Kozlowski
  5 siblings, 0 replies; 11+ messages in thread
From: Krzysztof Kozlowski @ 2022-07-21 15:31 UTC (permalink / raw)
  To: Thierry Reding, Sam Ravnborg, David Airlie, Daniel Vetter,
	Rob Herring, Krzysztof Kozlowski, Linus Walleij, Markuss Broks,
	Lars-Peter Clausen, Michael Hennerich, Jonathan Cameron,
	Alexandru Tachici, Marcelo Schmitt, Tomislav Denis,
	Cosmin Tanislav, Nishant Malpani, Dragos Bogdan, Nuno Sa,
	Jean-Baptiste Maneyrol, David S. Miller, Eric Dumazet,
	Jakub Kicinski, Paolo Abeni, Mark Brown, Tomi Valkeinen,
	Andrzej Hajda, Maxime Ripard, Marek Belisko,
	H. Nikolaus Schaller, Christian Eggers, Beniamin Bia,
	Stefan Popa, Oskar Andero, Mårten Lindahl, Dan Murphy,
	Sean Nyekjaer, Cristian Pop, Lukas Wunner, Matt Ranostay,
	Matheus Tavares, Sankar Velliangiri, Lubomir Rintel,
	Stefan Wahren, Pratyush Yadav, dri-devel, devicetree,
	linux-kernel, linux-iio, linux-fbdev, netdev, linux-spi
  Cc: Krzysztof Kozlowski

The spi-cpha and spi-cpol properties are device specific and should be
accepted only if device really needs them.  Explicitly list them in
device bindings in preparation of their removal from generic
spi-peripheral-props.yaml schema.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 Documentation/devicetree/bindings/misc/olpc,xo1.75-ec.yaml | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/Documentation/devicetree/bindings/misc/olpc,xo1.75-ec.yaml b/Documentation/devicetree/bindings/misc/olpc,xo1.75-ec.yaml
index b3c45c046ba5..a198848283d2 100644
--- a/Documentation/devicetree/bindings/misc/olpc,xo1.75-ec.yaml
+++ b/Documentation/devicetree/bindings/misc/olpc,xo1.75-ec.yaml
@@ -28,7 +28,10 @@ properties:
     description: GPIO uspecifier of the CMD pin
     maxItems: 1
 
-  spi-cpha: true
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
 
 required:
   - compatible
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH 5/6] dt-bindings: net: explicitly list SPI CPHA and CPOL
  2022-07-21 15:31 [PATCH 0/6] dt-bindings: iio/panel/eeprom/misc/net/spi: drop SPI CPHA and CPOL Krzysztof Kozlowski
                   ` (3 preceding siblings ...)
  2022-07-21 15:31 ` [PATCH 4/6] dt-bindings: misc: " Krzysztof Kozlowski
@ 2022-07-21 15:31 ` Krzysztof Kozlowski
  2022-07-21 19:35   ` Rob Herring
  2022-07-21 15:31 ` [PATCH 6/6] spi: dt-bindings: drop CPHA and CPOL from common properties Krzysztof Kozlowski
  5 siblings, 1 reply; 11+ messages in thread
From: Krzysztof Kozlowski @ 2022-07-21 15:31 UTC (permalink / raw)
  To: Thierry Reding, Sam Ravnborg, David Airlie, Daniel Vetter,
	Rob Herring, Krzysztof Kozlowski, Linus Walleij, Markuss Broks,
	Lars-Peter Clausen, Michael Hennerich, Jonathan Cameron,
	Alexandru Tachici, Marcelo Schmitt, Tomislav Denis,
	Cosmin Tanislav, Nishant Malpani, Dragos Bogdan, Nuno Sa,
	Jean-Baptiste Maneyrol, David S. Miller, Eric Dumazet,
	Jakub Kicinski, Paolo Abeni, Mark Brown, Tomi Valkeinen,
	Andrzej Hajda, Maxime Ripard, Marek Belisko,
	H. Nikolaus Schaller, Christian Eggers, Beniamin Bia,
	Stefan Popa, Oskar Andero, Mårten Lindahl, Dan Murphy,
	Sean Nyekjaer, Cristian Pop, Lukas Wunner, Matt Ranostay,
	Matheus Tavares, Sankar Velliangiri, Lubomir Rintel,
	Stefan Wahren, Pratyush Yadav, dri-devel, devicetree,
	linux-kernel, linux-iio, linux-fbdev, netdev, linux-spi
  Cc: Krzysztof Kozlowski

The spi-cpha and spi-cpol properties are device specific and should be
accepted only if device really needs them.  Explicitly list them in
device bindings in preparation of their removal from generic
spi-peripheral-props.yaml schema.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 .../devicetree/bindings/net/nfc/marvell,nci.yaml     | 12 ++++++++++--
 .../devicetree/bindings/net/vertexcom-mse102x.yaml   | 12 +++++++++---
 2 files changed, 19 insertions(+), 5 deletions(-)

diff --git a/Documentation/devicetree/bindings/net/nfc/marvell,nci.yaml b/Documentation/devicetree/bindings/net/nfc/marvell,nci.yaml
index 1bcaf6ba822c..00b3918a9bf2 100644
--- a/Documentation/devicetree/bindings/net/nfc/marvell,nci.yaml
+++ b/Documentation/devicetree/bindings/net/nfc/marvell,nci.yaml
@@ -56,8 +56,16 @@ properties:
     description: |
       For UART type of connection. Specifies that the chip is using RTS/CTS.
 
-  spi-cpha: true
-  spi-cpol: true
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
+
+  spi-cpol:
+    type: boolean
+    description:
+      The device requires inverse clock polarity (CPOL) mode.
+
   spi-max-frequency: true
 
 required:
diff --git a/Documentation/devicetree/bindings/net/vertexcom-mse102x.yaml b/Documentation/devicetree/bindings/net/vertexcom-mse102x.yaml
index 8156a9aeb589..9dc1609f6d06 100644
--- a/Documentation/devicetree/bindings/net/vertexcom-mse102x.yaml
+++ b/Documentation/devicetree/bindings/net/vertexcom-mse102x.yaml
@@ -34,9 +34,15 @@ properties:
   interrupts:
     maxItems: 1
 
-  spi-cpha: true
-
-  spi-cpol: true
+  spi-cpha:
+    type: boolean
+    description:
+      The device requires shifted clock phase (CPHA) mode.
+
+  spi-cpol:
+    type: boolean
+    description:
+      The device requires inverse clock polarity (CPOL) mode.
 
   spi-max-frequency:
     minimum: 6000000
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH 6/6] spi: dt-bindings: drop CPHA and CPOL from common properties
  2022-07-21 15:31 [PATCH 0/6] dt-bindings: iio/panel/eeprom/misc/net/spi: drop SPI CPHA and CPOL Krzysztof Kozlowski
                   ` (4 preceding siblings ...)
  2022-07-21 15:31 ` [PATCH 5/6] dt-bindings: net: " Krzysztof Kozlowski
@ 2022-07-21 15:31 ` Krzysztof Kozlowski
  5 siblings, 0 replies; 11+ messages in thread
From: Krzysztof Kozlowski @ 2022-07-21 15:31 UTC (permalink / raw)
  To: Thierry Reding, Sam Ravnborg, David Airlie, Daniel Vetter,
	Rob Herring, Krzysztof Kozlowski, Linus Walleij, Markuss Broks,
	Lars-Peter Clausen, Michael Hennerich, Jonathan Cameron,
	Alexandru Tachici, Marcelo Schmitt, Tomislav Denis,
	Cosmin Tanislav, Nishant Malpani, Dragos Bogdan, Nuno Sa,
	Jean-Baptiste Maneyrol, David S. Miller, Eric Dumazet,
	Jakub Kicinski, Paolo Abeni, Mark Brown, Tomi Valkeinen,
	Andrzej Hajda, Maxime Ripard, Marek Belisko,
	H. Nikolaus Schaller, Christian Eggers, Beniamin Bia,
	Stefan Popa, Oskar Andero, Mårten Lindahl, Dan Murphy,
	Sean Nyekjaer, Cristian Pop, Lukas Wunner, Matt Ranostay,
	Matheus Tavares, Sankar Velliangiri, Lubomir Rintel,
	Stefan Wahren, Pratyush Yadav, dri-devel, devicetree,
	linux-kernel, linux-iio, linux-fbdev, netdev, linux-spi
  Cc: Krzysztof Kozlowski, Rob Herring

The spi-cpha and spi-cpol properties are device specific and should be
accepted only if device really needs them.  Drop them from common
spi-peripheral-props.yaml schema (each device schema will list them
instead).

Suggested-by: Jonathan Cameron <jic23@kernel.org>
Suggested-by: Rob Herring <robh@kernel.org>
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 .../devicetree/bindings/spi/spi-peripheral-props.yaml  | 10 ----------
 1 file changed, 10 deletions(-)

diff --git a/Documentation/devicetree/bindings/spi/spi-peripheral-props.yaml b/Documentation/devicetree/bindings/spi/spi-peripheral-props.yaml
index 9d63a58b46a0..ce048e782e80 100644
--- a/Documentation/devicetree/bindings/spi/spi-peripheral-props.yaml
+++ b/Documentation/devicetree/bindings/spi/spi-peripheral-props.yaml
@@ -34,16 +34,6 @@ properties:
     description:
       The device requires 3-wire mode.
 
-  spi-cpha:
-    $ref: /schemas/types.yaml#/definitions/flag
-    description:
-      The device requires shifted clock phase (CPHA) mode.
-
-  spi-cpol:
-    $ref: /schemas/types.yaml#/definitions/flag
-    description:
-      The device requires inverse clock polarity (CPOL) mode.
-
   spi-cs-high:
     $ref: /schemas/types.yaml#/definitions/flag
     description:
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* Re: [PATCH 1/6] dt-bindings: panel: explicitly list SPI CPHA and CPOL
  2022-07-21 15:31 ` [PATCH 1/6] dt-bindings: panel: explicitly list " Krzysztof Kozlowski
@ 2022-07-21 19:30   ` Rob Herring
  2022-07-22 18:37     ` Krzysztof Kozlowski
  0 siblings, 1 reply; 11+ messages in thread
From: Rob Herring @ 2022-07-21 19:30 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Thierry Reding, Sam Ravnborg, David Airlie, Daniel Vetter,
	Krzysztof Kozlowski, Linus Walleij, Markuss Broks,
	Lars-Peter Clausen, Michael Hennerich, Jonathan Cameron,
	Alexandru Tachici, Marcelo Schmitt, Tomislav Denis,
	Cosmin Tanislav, Nishant Malpani, Dragos Bogdan, Nuno Sa,
	Jean-Baptiste Maneyrol, David S. Miller, Eric Dumazet,
	Jakub Kicinski, Paolo Abeni, Mark Brown, Tomi Valkeinen,
	Andrzej Hajda, Maxime Ripard, Marek Belisko,
	H. Nikolaus Schaller, Christian Eggers, Beniamin Bia,
	Stefan Popa, Oskar Andero, Mårten Lindahl, Dan Murphy,
	Sean Nyekjaer, Cristian Pop, Lukas Wunner, Matt Ranostay,
	Matheus Tavares, Sankar Velliangiri, Lubomir Rintel,
	Stefan Wahren, Pratyush Yadav, dri-devel, devicetree,
	linux-kernel, linux-iio, linux-fbdev, netdev, linux-spi

On Thu, Jul 21, 2022 at 05:31:50PM +0200, Krzysztof Kozlowski wrote:
> The spi-cpha and spi-cpol properties are device specific and should be
> accepted only if device really needs them.  Explicitly list them in
> device bindings in preparation of their removal from generic
> spi-peripheral-props.yaml schema.
> 
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
> ---
>  .../bindings/display/panel/lgphilips,lb035q02.yaml   | 10 ++++++++++
>  .../bindings/display/panel/samsung,ld9040.yaml       | 10 ++++++++++
>  .../bindings/display/panel/samsung,lms380kf01.yaml   | 12 +++++++++---
>  .../bindings/display/panel/samsung,lms397kf04.yaml   | 12 +++++++++---
>  .../bindings/display/panel/samsung,s6d27a1.yaml      | 12 +++++++++---
>  .../bindings/display/panel/sitronix,st7789v.yaml     | 10 ++++++++++
>  .../devicetree/bindings/display/panel/tpo,td.yaml    | 10 ++++++++++
>  7 files changed, 67 insertions(+), 9 deletions(-)
> 
> diff --git a/Documentation/devicetree/bindings/display/panel/lgphilips,lb035q02.yaml b/Documentation/devicetree/bindings/display/panel/lgphilips,lb035q02.yaml
> index 5e4e0e552c2f..0bd7bbad5b94 100644
> --- a/Documentation/devicetree/bindings/display/panel/lgphilips,lb035q02.yaml
> +++ b/Documentation/devicetree/bindings/display/panel/lgphilips,lb035q02.yaml
> @@ -21,6 +21,16 @@ properties:
>    enable-gpios: true
>    port: true
>  
> +  spi-cpha:
> +    type: boolean
> +    description:
> +      The device requires shifted clock phase (CPHA) mode.
> +
> +  spi-cpol:
> +    type: boolean
> +    description:
> +      The device requires inverse clock polarity (CPOL) mode.

Not great duplicating the type and description everywhere.

We can move the definition back to spi-controller.yaml, so then that 
does type checking of the property, but not presence/absence checks.

Rob

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 3/6] dt-bindings: iio: explicitly list SPI CPHA and CPOL
  2022-07-21 15:31 ` [PATCH 3/6] dt-bindings: iio: " Krzysztof Kozlowski
@ 2022-07-21 19:32   ` Rob Herring
  0 siblings, 0 replies; 11+ messages in thread
From: Rob Herring @ 2022-07-21 19:32 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Thierry Reding, Sam Ravnborg, David Airlie, Daniel Vetter,
	Krzysztof Kozlowski, Linus Walleij, Markuss Broks,
	Lars-Peter Clausen, Michael Hennerich, Jonathan Cameron,
	Alexandru Tachici, Marcelo Schmitt, Tomislav Denis,
	Cosmin Tanislav, Nishant Malpani, Dragos Bogdan, Nuno Sa,
	Jean-Baptiste Maneyrol, David S. Miller, Eric Dumazet,
	Jakub Kicinski, Paolo Abeni, Mark Brown, Tomi Valkeinen,
	Andrzej Hajda, Maxime Ripard, Marek Belisko,
	H. Nikolaus Schaller, Christian Eggers, Beniamin Bia,
	Stefan Popa, Oskar Andero, Mårten Lindahl, Dan Murphy,
	Sean Nyekjaer, Cristian Pop, Lukas Wunner, Matt Ranostay,
	Matheus Tavares, Sankar Velliangiri, Lubomir Rintel,
	Stefan Wahren, Pratyush Yadav, dri-devel, devicetree,
	linux-kernel, linux-iio, linux-fbdev, netdev, linux-spi

On Thu, Jul 21, 2022 at 05:31:52PM +0200, Krzysztof Kozlowski wrote:
> The spi-cpha and spi-cpol properties are device specific and should be
> accepted only if device really needs them.  Explicitly list them in
> device bindings in preparation of their removal from generic
> spi-peripheral-props.yaml schema.
> 
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
> ---
>  .../devicetree/bindings/iio/accel/adi,adxl345.yaml   | 10 ++++++++--
>  .../devicetree/bindings/iio/adc/adi,ad7192.yaml      | 10 ++++++++--
>  .../devicetree/bindings/iio/adc/adi,ad7292.yaml      |  5 ++++-
>  .../devicetree/bindings/iio/adc/adi,ad7606.yaml      | 10 ++++++++--
>  .../devicetree/bindings/iio/adc/adi,ad7768-1.yaml    | 10 ++++++++--
>  .../bindings/iio/adc/microchip,mcp3201.yaml          | 12 ++++++++++--
>  .../devicetree/bindings/iio/adc/ti,adc084s021.yaml   | 11 +++++++++--
>  .../devicetree/bindings/iio/adc/ti,ads124s08.yaml    |  5 ++++-
>  .../devicetree/bindings/iio/adc/ti,ads131e08.yaml    |  5 ++++-
>  .../devicetree/bindings/iio/addac/adi,ad74413r.yaml  |  5 ++++-
>  .../devicetree/bindings/iio/dac/adi,ad5592r.yaml     |  5 ++++-
>  .../devicetree/bindings/iio/dac/adi,ad5755.yaml      | 10 ++++++++--
>  .../devicetree/bindings/iio/dac/adi,ad5758.yaml      |  6 +++++-
>  .../devicetree/bindings/iio/dac/adi,ad5766.yaml      |  5 ++++-
>  .../devicetree/bindings/iio/dac/ti,dac082s085.yaml   |  9 +++++++--
>  .../bindings/iio/gyroscope/adi,adxrs290.yaml         | 10 ++++++++--
>  .../devicetree/bindings/iio/imu/adi,adis16460.yaml   | 12 +++++++++---
>  .../devicetree/bindings/iio/imu/adi,adis16475.yaml   | 10 ++++++++--
>  .../devicetree/bindings/iio/imu/adi,adis16480.yaml   | 11 +++++++++--
>  .../bindings/iio/imu/invensense,icm42600.yaml        | 12 ++++++++++--
>  .../bindings/iio/proximity/ams,as3935.yaml           |  5 ++++-
>  .../devicetree/bindings/iio/resolver/adi,ad2s90.yaml | 10 ++++++++--
>  .../bindings/iio/temperature/maxim,max31855k.yaml    |  6 +++++-
>  .../bindings/iio/temperature/maxim,max31856.yaml     |  6 +++++-
>  .../bindings/iio/temperature/maxim,max31865.yaml     |  6 +++++-
>  25 files changed, 166 insertions(+), 40 deletions(-)

This whole patch can be dropped which will make merging easier.

Rob

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 5/6] dt-bindings: net: explicitly list SPI CPHA and CPOL
  2022-07-21 15:31 ` [PATCH 5/6] dt-bindings: net: " Krzysztof Kozlowski
@ 2022-07-21 19:35   ` Rob Herring
  0 siblings, 0 replies; 11+ messages in thread
From: Rob Herring @ 2022-07-21 19:35 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Thierry Reding, Sam Ravnborg, David Airlie, Daniel Vetter,
	Krzysztof Kozlowski, Linus Walleij, Markuss Broks,
	Lars-Peter Clausen, Michael Hennerich, Jonathan Cameron,
	Alexandru Tachici, Marcelo Schmitt, Tomislav Denis,
	Cosmin Tanislav, Nishant Malpani, Dragos Bogdan, Nuno Sa,
	Jean-Baptiste Maneyrol, David S. Miller, Eric Dumazet,
	Jakub Kicinski, Paolo Abeni, Mark Brown, Tomi Valkeinen,
	Andrzej Hajda, Maxime Ripard, Marek Belisko,
	H. Nikolaus Schaller, Christian Eggers, Beniamin Bia,
	Stefan Popa, Oskar Andero, Mårten Lindahl, Dan Murphy,
	Sean Nyekjaer, Cristian Pop, Lukas Wunner, Matt Ranostay,
	Matheus Tavares, Sankar Velliangiri, Lubomir Rintel,
	Stefan Wahren, Pratyush Yadav, dri-devel, devicetree,
	linux-kernel, linux-iio, linux-fbdev, netdev, linux-spi

On Thu, Jul 21, 2022 at 05:31:54PM +0200, Krzysztof Kozlowski wrote:
> The spi-cpha and spi-cpol properties are device specific and should be
> accepted only if device really needs them.  Explicitly list them in
> device bindings in preparation of their removal from generic
> spi-peripheral-props.yaml schema.
> 
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
> ---
>  .../devicetree/bindings/net/nfc/marvell,nci.yaml     | 12 ++++++++++--
>  .../devicetree/bindings/net/vertexcom-mse102x.yaml   | 12 +++++++++---
>  2 files changed, 19 insertions(+), 5 deletions(-)

This too should not be needed.

Rob

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 1/6] dt-bindings: panel: explicitly list SPI CPHA and CPOL
  2022-07-21 19:30   ` Rob Herring
@ 2022-07-22 18:37     ` Krzysztof Kozlowski
  0 siblings, 0 replies; 11+ messages in thread
From: Krzysztof Kozlowski @ 2022-07-22 18:37 UTC (permalink / raw)
  To: Rob Herring
  Cc: Thierry Reding, Sam Ravnborg, David Airlie, Daniel Vetter,
	Krzysztof Kozlowski, Linus Walleij, Markuss Broks,
	Lars-Peter Clausen, Michael Hennerich, Jonathan Cameron,
	Alexandru Tachici, Marcelo Schmitt, Tomislav Denis,
	Cosmin Tanislav, Nishant Malpani, Dragos Bogdan, Nuno Sa,
	Jean-Baptiste Maneyrol, David S. Miller, Eric Dumazet,
	Jakub Kicinski, Paolo Abeni, Mark Brown, Tomi Valkeinen,
	Andrzej Hajda, Maxime Ripard, Marek Belisko,
	H. Nikolaus Schaller, Christian Eggers, Beniamin Bia,
	Stefan Popa, Oskar Andero, Mårten Lindahl, Dan Murphy,
	Sean Nyekjaer, Cristian Pop, Lukas Wunner, Matt Ranostay,
	Matheus Tavares, Sankar Velliangiri, Lubomir Rintel,
	Stefan Wahren, Pratyush Yadav, dri-devel, devicetree,
	linux-kernel, linux-iio, linux-fbdev, netdev, linux-spi

On 21/07/2022 21:30, Rob Herring wrote:
> On Thu, Jul 21, 2022 at 05:31:50PM +0200, Krzysztof Kozlowski wrote:
>> The spi-cpha and spi-cpol properties are device specific and should be
>> accepted only if device really needs them.  Explicitly list them in
>> device bindings in preparation of their removal from generic
>> spi-peripheral-props.yaml schema.
>>
>> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
>> ---
>>  .../bindings/display/panel/lgphilips,lb035q02.yaml   | 10 ++++++++++
>>  .../bindings/display/panel/samsung,ld9040.yaml       | 10 ++++++++++
>>  .../bindings/display/panel/samsung,lms380kf01.yaml   | 12 +++++++++---
>>  .../bindings/display/panel/samsung,lms397kf04.yaml   | 12 +++++++++---
>>  .../bindings/display/panel/samsung,s6d27a1.yaml      | 12 +++++++++---
>>  .../bindings/display/panel/sitronix,st7789v.yaml     | 10 ++++++++++
>>  .../devicetree/bindings/display/panel/tpo,td.yaml    | 10 ++++++++++
>>  7 files changed, 67 insertions(+), 9 deletions(-)
>>
>> diff --git a/Documentation/devicetree/bindings/display/panel/lgphilips,lb035q02.yaml b/Documentation/devicetree/bindings/display/panel/lgphilips,lb035q02.yaml
>> index 5e4e0e552c2f..0bd7bbad5b94 100644
>> --- a/Documentation/devicetree/bindings/display/panel/lgphilips,lb035q02.yaml
>> +++ b/Documentation/devicetree/bindings/display/panel/lgphilips,lb035q02.yaml
>> @@ -21,6 +21,16 @@ properties:
>>    enable-gpios: true
>>    port: true
>>  
>> +  spi-cpha:
>> +    type: boolean
>> +    description:
>> +      The device requires shifted clock phase (CPHA) mode.
>> +
>> +  spi-cpol:
>> +    type: boolean
>> +    description:
>> +      The device requires inverse clock polarity (CPOL) mode.
> 
> Not great duplicating the type and description everywhere.
> 
> We can move the definition back to spi-controller.yaml, so then that 
> does type checking of the property, but not presence/absence checks.

If I understand correctly, all client devices (which do no reference
spi-controller) will need to explicitly mention CPHA/CPOL. Good idea.

Best regards,
Krzysztof

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2022-07-22 18:38 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-07-21 15:31 [PATCH 0/6] dt-bindings: iio/panel/eeprom/misc/net/spi: drop SPI CPHA and CPOL Krzysztof Kozlowski
2022-07-21 15:31 ` [PATCH 1/6] dt-bindings: panel: explicitly list " Krzysztof Kozlowski
2022-07-21 19:30   ` Rob Herring
2022-07-22 18:37     ` Krzysztof Kozlowski
2022-07-21 15:31 ` [PATCH 2/6] dt-bindings: eeprom: at25: " Krzysztof Kozlowski
2022-07-21 15:31 ` [PATCH 3/6] dt-bindings: iio: " Krzysztof Kozlowski
2022-07-21 19:32   ` Rob Herring
2022-07-21 15:31 ` [PATCH 4/6] dt-bindings: misc: " Krzysztof Kozlowski
2022-07-21 15:31 ` [PATCH 5/6] dt-bindings: net: " Krzysztof Kozlowski
2022-07-21 19:35   ` Rob Herring
2022-07-21 15:31 ` [PATCH 6/6] spi: dt-bindings: drop CPHA and CPOL from common properties Krzysztof Kozlowski

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).