All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/3] dt-bindings: leds: irled: gpio-ir-tx: convert to DT schema
@ 2022-12-04 10:43 Krzysztof Kozlowski
  2022-12-04 10:43 ` [PATCH 2/3] dt-bindings: leds: irled: pwm-ir-tx: " Krzysztof Kozlowski
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Krzysztof Kozlowski @ 2022-12-04 10:43 UTC (permalink / raw)
  To: Pavel Machek, Rob Herring, Krzysztof Kozlowski, Sean Young,
	linux-leds, devicetree, linux-kernel, linux-media
  Cc: Krzysztof Kozlowski

Convert the GPIO IR LED bindings to DT schema.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 .../bindings/leds/irled/gpio-ir-tx.txt        | 14 --------
 .../bindings/leds/irled/gpio-ir-tx.yaml       | 36 +++++++++++++++++++
 MAINTAINERS                                   |  1 +
 3 files changed, 37 insertions(+), 14 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/leds/irled/gpio-ir-tx.txt
 create mode 100644 Documentation/devicetree/bindings/leds/irled/gpio-ir-tx.yaml

diff --git a/Documentation/devicetree/bindings/leds/irled/gpio-ir-tx.txt b/Documentation/devicetree/bindings/leds/irled/gpio-ir-tx.txt
deleted file mode 100644
index cbe8dfd29715..000000000000
--- a/Documentation/devicetree/bindings/leds/irled/gpio-ir-tx.txt
+++ /dev/null
@@ -1,14 +0,0 @@
-Device tree bindings for IR LED connected through gpio pin which is used as
-remote controller transmitter.
-
-Required properties:
-	- compatible: should be "gpio-ir-tx".
-	- gpios :  Should specify the IR LED GPIO, see "gpios property" in
-	  Documentation/devicetree/bindings/gpio/gpio.txt.  Active low LEDs
-	  should be indicated using flags in the GPIO specifier.
-
-Example:
-	irled@0 {
-		compatible = "gpio-ir-tx";
-		gpios = <&gpio1 2 GPIO_ACTIVE_HIGH>;
-	};
diff --git a/Documentation/devicetree/bindings/leds/irled/gpio-ir-tx.yaml b/Documentation/devicetree/bindings/leds/irled/gpio-ir-tx.yaml
new file mode 100644
index 000000000000..5839d00c7089
--- /dev/null
+++ b/Documentation/devicetree/bindings/leds/irled/gpio-ir-tx.yaml
@@ -0,0 +1,36 @@
+# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/leds/irled/gpio-ir-tx.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: IR LED connected through GPIO pin
+
+maintainers:
+  - Sean Young <sean@mess.org>
+
+description:
+  IR LED connected through GPIO pin which is used as remote controller
+  transmitter.
+
+properties:
+  compatible:
+    const: gpio-ir-tx
+
+  gpios:
+    maxItems: 1
+
+required:
+  - compatible
+  - gpios
+
+additionalProperties: false
+
+examples:
+  - |
+    #include <dt-bindings/gpio/gpio.h>
+
+    irled {
+        compatible = "gpio-ir-tx";
+        gpios = <&gpio1 2 GPIO_ACTIVE_HIGH>;
+    };
diff --git a/MAINTAINERS b/MAINTAINERS
index be71999cea73..25b7fbf09e7b 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -8839,6 +8839,7 @@ GPIO IR Transmitter
 M:	Sean Young <sean@mess.org>
 L:	linux-media@vger.kernel.org
 S:	Maintained
+F:	Documentation/devicetree/bindings/leds/irled/gpio-ir-tx.yaml
 F:	drivers/media/rc/gpio-ir-tx.c
 
 GPIO MOCKUP DRIVER
-- 
2.34.1


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

* [PATCH 2/3] dt-bindings: leds: irled: pwm-ir-tx: convert to DT schema
  2022-12-04 10:43 [PATCH 1/3] dt-bindings: leds: irled: gpio-ir-tx: convert to DT schema Krzysztof Kozlowski
@ 2022-12-04 10:43 ` Krzysztof Kozlowski
  2022-12-05 22:18   ` Rob Herring
  2022-12-04 10:43 ` [PATCH 3/3] dt-bindings: leds: irled: ir-spi-led: " Krzysztof Kozlowski
  2022-12-05 22:18 ` [PATCH 1/3] dt-bindings: leds: irled: gpio-ir-tx: " Rob Herring
  2 siblings, 1 reply; 6+ messages in thread
From: Krzysztof Kozlowski @ 2022-12-04 10:43 UTC (permalink / raw)
  To: Pavel Machek, Rob Herring, Krzysztof Kozlowski, Sean Young,
	linux-leds, devicetree, linux-kernel, linux-media
  Cc: Krzysztof Kozlowski

Convert the PWM IR LED bindings to DT schema.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 .../bindings/leds/irled/pwm-ir-tx.txt         | 13 -------
 .../bindings/leds/irled/pwm-ir-tx.yaml        | 34 +++++++++++++++++++
 MAINTAINERS                                   |  1 +
 3 files changed, 35 insertions(+), 13 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/leds/irled/pwm-ir-tx.txt
 create mode 100644 Documentation/devicetree/bindings/leds/irled/pwm-ir-tx.yaml

diff --git a/Documentation/devicetree/bindings/leds/irled/pwm-ir-tx.txt b/Documentation/devicetree/bindings/leds/irled/pwm-ir-tx.txt
deleted file mode 100644
index 66e5672c2e3d..000000000000
--- a/Documentation/devicetree/bindings/leds/irled/pwm-ir-tx.txt
+++ /dev/null
@@ -1,13 +0,0 @@
-Device tree bindings for IR LED connected through pwm pin which is used as
-remote controller transmitter.
-
-Required properties:
-	- compatible: should be "pwm-ir-tx".
-	- pwms : PWM property to point to the PWM device (phandle)/port (id)
-	  and to specify the period time to be used: <&phandle id period_ns>;
-
-Example:
-	irled {
-		compatible = "pwm-ir-tx";
-		pwms = <&pwm0 0 10000000>;
-	};
diff --git a/Documentation/devicetree/bindings/leds/irled/pwm-ir-tx.yaml b/Documentation/devicetree/bindings/leds/irled/pwm-ir-tx.yaml
new file mode 100644
index 000000000000..f2a6fa140f38
--- /dev/null
+++ b/Documentation/devicetree/bindings/leds/irled/pwm-ir-tx.yaml
@@ -0,0 +1,34 @@
+# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/leds/irled/pwm-ir-tx.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: IR LED connected through PWM pin
+
+maintainers:
+  - Sean Young <sean@mess.org>
+
+description:
+  IR LED connected through PWM pin which is used as remote controller
+  transmitter.
+
+properties:
+  compatible:
+    const: pwm-ir-tx
+
+  pwms:
+    maxItems: 1
+
+required:
+  - compatible
+  - pwms
+
+additionalProperties: false
+
+examples:
+  - |
+    irled {
+        compatible = "pwm-ir-tx";
+        pwms = <&pwm0 0 10000000>;
+    };
diff --git a/MAINTAINERS b/MAINTAINERS
index 25b7fbf09e7b..e3f3c3e53f77 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -16960,6 +16960,7 @@ PWM IR Transmitter
 M:	Sean Young <sean@mess.org>
 L:	linux-media@vger.kernel.org
 S:	Maintained
+F:	Documentation/devicetree/bindings/leds/irled/pwm-ir-tx.yaml
 F:	drivers/media/rc/pwm-ir-tx.c
 
 PWM SUBSYSTEM
-- 
2.34.1


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

* [PATCH 3/3] dt-bindings: leds: irled: ir-spi-led: convert to DT schema
  2022-12-04 10:43 [PATCH 1/3] dt-bindings: leds: irled: gpio-ir-tx: convert to DT schema Krzysztof Kozlowski
  2022-12-04 10:43 ` [PATCH 2/3] dt-bindings: leds: irled: pwm-ir-tx: " Krzysztof Kozlowski
@ 2022-12-04 10:43 ` Krzysztof Kozlowski
  2022-12-05 22:19   ` Rob Herring
  2022-12-05 22:18 ` [PATCH 1/3] dt-bindings: leds: irled: gpio-ir-tx: " Rob Herring
  2 siblings, 1 reply; 6+ messages in thread
From: Krzysztof Kozlowski @ 2022-12-04 10:43 UTC (permalink / raw)
  To: Pavel Machek, Rob Herring, Krzysztof Kozlowski, Sean Young,
	linux-leds, devicetree, linux-kernel, linux-media
  Cc: Krzysztof Kozlowski

Convert the SPI IR LED bindings to DT schema.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 .../bindings/leds/irled/ir-spi-led.yaml       | 61 +++++++++++++++++++
 .../bindings/leds/irled/spi-ir-led.txt        | 29 ---------
 2 files changed, 61 insertions(+), 29 deletions(-)
 create mode 100644 Documentation/devicetree/bindings/leds/irled/ir-spi-led.yaml
 delete mode 100644 Documentation/devicetree/bindings/leds/irled/spi-ir-led.txt

diff --git a/Documentation/devicetree/bindings/leds/irled/ir-spi-led.yaml b/Documentation/devicetree/bindings/leds/irled/ir-spi-led.yaml
new file mode 100644
index 000000000000..72cadebf6e3e
--- /dev/null
+++ b/Documentation/devicetree/bindings/leds/irled/ir-spi-led.yaml
@@ -0,0 +1,61 @@
+# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/leds/irled/ir-spi-led.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: IR LED connected through SPI bus
+
+maintainers:
+  - Sean Young <sean@mess.org>
+
+description:
+  IR LED switch is connected to the MOSI line of the SPI device and the data
+  is delivered through that.
+
+allOf:
+  - $ref: /schemas/spi/spi-peripheral-props.yaml#
+
+properties:
+  compatible:
+    const: ir-spi-led
+
+  reg:
+    maxItems: 1
+
+  duty-cycle:
+    $ref: /schemas/types.yaml#/definitions/uint8
+    enum: [50, 60, 70, 75, 80, 90]
+    description:
+      Percentage of one period in which the signal is active.
+
+  led-active-low:
+    type: boolean
+    description:
+      Output is negated with a NOT gate.
+
+  power-supply: true
+
+required:
+  - compatible
+  - reg
+
+unevaluatedProperties: false
+
+examples:
+  - |
+    spi {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        irled@0 {
+            compatible = "ir-spi-led";
+            reg = <0x0>;
+
+            duty-cycle = /bits/ 8 <60>;
+            led-active-low;
+            power-supply = <&irda_regulator>;
+            spi-max-frequency = <5000000>;
+        };
+    };
+
diff --git a/Documentation/devicetree/bindings/leds/irled/spi-ir-led.txt b/Documentation/devicetree/bindings/leds/irled/spi-ir-led.txt
deleted file mode 100644
index 83ff1b4d70a6..000000000000
--- a/Documentation/devicetree/bindings/leds/irled/spi-ir-led.txt
+++ /dev/null
@@ -1,29 +0,0 @@
-Device tree bindings for IR LED connected through SPI bus which is used as
-remote controller.
-
-The IR LED switch is connected to the MOSI line of the SPI device and the data
-are delivered thourgh that.
-
-Required properties:
-	- compatible: should be "ir-spi-led".
-
-Optional properties:
-	- duty-cycle: 8 bit value that represents the percentage of one period
-	  in which the signal is active.  It can be 50, 60, 70, 75, 80 or 90.
-	- led-active-low: boolean value that specifies whether the output is
-	  negated with a NOT gate.
-	- power-supply: specifies the power source. It can either be a regulator
-	  or a gpio which enables a regulator, i.e. a regulator-fixed as
-	  described in
-	  Documentation/devicetree/bindings/regulator/fixed-regulator.yaml
-
-Example:
-
-	irled@0 {
-		compatible = "ir-spi-led";
-		reg = <0x0>;
-		spi-max-frequency = <5000000>;
-		power-supply = <&vdd_led>;
-		led-active-low;
-		duty-cycle = /bits/ 8 <60>;
-	};
-- 
2.34.1


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

* Re: [PATCH 1/3] dt-bindings: leds: irled: gpio-ir-tx: convert to DT schema
  2022-12-04 10:43 [PATCH 1/3] dt-bindings: leds: irled: gpio-ir-tx: convert to DT schema Krzysztof Kozlowski
  2022-12-04 10:43 ` [PATCH 2/3] dt-bindings: leds: irled: pwm-ir-tx: " Krzysztof Kozlowski
  2022-12-04 10:43 ` [PATCH 3/3] dt-bindings: leds: irled: ir-spi-led: " Krzysztof Kozlowski
@ 2022-12-05 22:18 ` Rob Herring
  2 siblings, 0 replies; 6+ messages in thread
From: Rob Herring @ 2022-12-05 22:18 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: devicetree, linux-leds, Sean Young, linux-kernel,
	Krzysztof Kozlowski, Rob Herring, linux-media, Pavel Machek


On Sun, 04 Dec 2022 11:43:21 +0100, Krzysztof Kozlowski wrote:
> Convert the GPIO IR LED bindings to DT schema.
> 
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
> ---
>  .../bindings/leds/irled/gpio-ir-tx.txt        | 14 --------
>  .../bindings/leds/irled/gpio-ir-tx.yaml       | 36 +++++++++++++++++++
>  MAINTAINERS                                   |  1 +
>  3 files changed, 37 insertions(+), 14 deletions(-)
>  delete mode 100644 Documentation/devicetree/bindings/leds/irled/gpio-ir-tx.txt
>  create mode 100644 Documentation/devicetree/bindings/leds/irled/gpio-ir-tx.yaml
> 

Applied, thanks!

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

* Re: [PATCH 2/3] dt-bindings: leds: irled: pwm-ir-tx: convert to DT schema
  2022-12-04 10:43 ` [PATCH 2/3] dt-bindings: leds: irled: pwm-ir-tx: " Krzysztof Kozlowski
@ 2022-12-05 22:18   ` Rob Herring
  0 siblings, 0 replies; 6+ messages in thread
From: Rob Herring @ 2022-12-05 22:18 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: linux-leds, linux-media, Pavel Machek, devicetree,
	Krzysztof Kozlowski, Sean Young, Rob Herring, linux-kernel


On Sun, 04 Dec 2022 11:43:22 +0100, Krzysztof Kozlowski wrote:
> Convert the PWM IR LED bindings to DT schema.
> 
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
> ---
>  .../bindings/leds/irled/pwm-ir-tx.txt         | 13 -------
>  .../bindings/leds/irled/pwm-ir-tx.yaml        | 34 +++++++++++++++++++
>  MAINTAINERS                                   |  1 +
>  3 files changed, 35 insertions(+), 13 deletions(-)
>  delete mode 100644 Documentation/devicetree/bindings/leds/irled/pwm-ir-tx.txt
>  create mode 100644 Documentation/devicetree/bindings/leds/irled/pwm-ir-tx.yaml
> 

Applied, thanks!

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

* Re: [PATCH 3/3] dt-bindings: leds: irled: ir-spi-led: convert to DT schema
  2022-12-04 10:43 ` [PATCH 3/3] dt-bindings: leds: irled: ir-spi-led: " Krzysztof Kozlowski
@ 2022-12-05 22:19   ` Rob Herring
  0 siblings, 0 replies; 6+ messages in thread
From: Rob Herring @ 2022-12-05 22:19 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: linux-media, linux-leds, linux-kernel, Pavel Machek,
	Krzysztof Kozlowski, devicetree, Sean Young, Rob Herring


On Sun, 04 Dec 2022 11:43:23 +0100, Krzysztof Kozlowski wrote:
> Convert the SPI IR LED bindings to DT schema.
> 
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
> ---
>  .../bindings/leds/irled/ir-spi-led.yaml       | 61 +++++++++++++++++++
>  .../bindings/leds/irled/spi-ir-led.txt        | 29 ---------
>  2 files changed, 61 insertions(+), 29 deletions(-)
>  create mode 100644 Documentation/devicetree/bindings/leds/irled/ir-spi-led.yaml
>  delete mode 100644 Documentation/devicetree/bindings/leds/irled/spi-ir-led.txt
> 

Applied, thanks!

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

end of thread, other threads:[~2022-12-05 22:19 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-12-04 10:43 [PATCH 1/3] dt-bindings: leds: irled: gpio-ir-tx: convert to DT schema Krzysztof Kozlowski
2022-12-04 10:43 ` [PATCH 2/3] dt-bindings: leds: irled: pwm-ir-tx: " Krzysztof Kozlowski
2022-12-05 22:18   ` Rob Herring
2022-12-04 10:43 ` [PATCH 3/3] dt-bindings: leds: irled: ir-spi-led: " Krzysztof Kozlowski
2022-12-05 22:19   ` Rob Herring
2022-12-05 22:18 ` [PATCH 1/3] dt-bindings: leds: irled: gpio-ir-tx: " Rob Herring

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.