* [PATCH 1/3 v3] dt-bindings: backlight: Add some common backlight properties
@ 2020-08-19 20:51 Linus Walleij
2020-08-19 20:51 ` [PATCH 2/3 v3] dt-bindings: backlight: Add Kinetic KTD253 bindings Linus Walleij
` (3 more replies)
0 siblings, 4 replies; 8+ messages in thread
From: Linus Walleij @ 2020-08-19 20:51 UTC (permalink / raw)
To: Lee Jones, Daniel Thompson, Jingoo Han, dri-devel
Cc: Linus Walleij, devicetree, Sam Ravnborg
Let's use a common.yaml include for the backlight like we do with
the LEDs. The LEDs are inherently incompatible so their bindings
cannot be reused for backlight.
Cc: devicetree@vger.kernel.org
Suggested-by: Sam Ravnborg <sam@ravnborg.org>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
---
ChangeLog v2->v3:
- Drop the | for the description
- Drop the "default-on" property, we're not using it.
- Drop the minimum 0 for unsigned u32:s
ChangeLog v1->v2:
- New patch as suggested by Sam.
---
.../bindings/leds/backlight/common.yaml | 34 +++++++++++++++++++
1 file changed, 34 insertions(+)
create mode 100644 Documentation/devicetree/bindings/leds/backlight/common.yaml
diff --git a/Documentation/devicetree/bindings/leds/backlight/common.yaml b/Documentation/devicetree/bindings/leds/backlight/common.yaml
new file mode 100644
index 000000000000..4e7e95e331a5
--- /dev/null
+++ b/Documentation/devicetree/bindings/leds/backlight/common.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/backlight/common.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Common backlight properties
+
+maintainers:
+ - Lee Jones <lee.jones@linaro.org>
+ - Daniel Thompson <daniel.thompson@linaro.org>
+ - Jingoo Han <jingoohan1@gmail.com>
+
+description:
+ Backlight devices provide backlight for different types of graphical
+ displays. They are typically but not necessarily implemented using a white
+ LED powered by a boost converter.
+
+properties:
+ default-brightness:
+ description:
+ The default brightness that should be applied to the LED by the operating
+ system on start-up. The brightness should not exceed the brightness the
+ LED can provide.
+ $ref: /schemas/types.yaml#definitions/uint32
+
+ max-brightness:
+ description:
+ Normally the maximum brightness is determined by the hardware and this
+ property is not required. This property is used to put a software limit
+ on the brightness apart from what the driver says, as it could happen
+ that a LED can be made so bright that it gets damaged or causes damage
+ due to restrictions in a specific system, such as mounting conditions.
+ $ref: /schemas/types.yaml#definitions/uint32
--
2.26.2
^ permalink raw reply related [flat|nested] 8+ messages in thread
* [PATCH 2/3 v3] dt-bindings: backlight: Add Kinetic KTD253 bindings
2020-08-19 20:51 [PATCH 1/3 v3] dt-bindings: backlight: Add some common backlight properties Linus Walleij
@ 2020-08-19 20:51 ` Linus Walleij
2020-08-20 16:38 ` Daniel Thompson
` (2 more replies)
2020-08-20 16:37 ` [PATCH 1/3 v3] dt-bindings: backlight: Add some common backlight properties Daniel Thompson
` (2 subsequent siblings)
3 siblings, 3 replies; 8+ messages in thread
From: Linus Walleij @ 2020-08-19 20:51 UTC (permalink / raw)
To: Lee Jones, Daniel Thompson, Jingoo Han, dri-devel
Cc: Linus Walleij, devicetree, Sam Ravnborg
This adds device tree bindings for the Kinetic KTD253
white LED backlight driver.
Cc: devicetree@vger.kernel.org
Cc: Sam Ravnborg <sam@ravnborg.org>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
---
ChangeLog v2->v3:
- Drop the pointless cargo-culted "default-on" property that
we were not using
- Correct the brightness in the example to something legal (13)
ChangeLog v1->v2:
- Create common.yaml for backlight as suggested by Sam and
use that.
- Rename the GPIO line "enable-gpios"
---
.../leds/backlight/kinetic,ktd253.yaml | 46 +++++++++++++++++++
1 file changed, 46 insertions(+)
create mode 100644 Documentation/devicetree/bindings/leds/backlight/kinetic,ktd253.yaml
diff --git a/Documentation/devicetree/bindings/leds/backlight/kinetic,ktd253.yaml b/Documentation/devicetree/bindings/leds/backlight/kinetic,ktd253.yaml
new file mode 100644
index 000000000000..7a6ec1f8c0f3
--- /dev/null
+++ b/Documentation/devicetree/bindings/leds/backlight/kinetic,ktd253.yaml
@@ -0,0 +1,46 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/leds/backlight/kinetic,ktd253.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Kinetic Technologies KTD253 one-wire backlight
+
+maintainers:
+ - Linus Walleij <linus.walleij@linaro.org>
+
+description: |
+ The Kinetic Technologies KTD253 is a white LED backlight that is
+ controlled by a single GPIO line. If you just turn on the backlight
+ it goes to maximum backlight then you can set the level of backlight
+ using pulses on the enable wire. This is sometimes referred to as
+ "expresswire".
+
+allOf:
+ - $ref: common.yaml#
+
+properties:
+ compatible:
+ const: kinetic,ktd253
+
+ enable-gpios:
+ description: GPIO to use to enable/disable and dim the backlight.
+ maxItems: 1
+
+ default-brightness: true
+ max-brightness: true
+
+required:
+ - compatible
+ - enable-gpios
+
+additionalProperties: false
+
+examples:
+ - |
+ #include <dt-bindings/gpio/gpio.h>
+ backlight {
+ compatible = "kinetic,ktd253";
+ enable-gpios = <&gpio2 5 GPIO_ACTIVE_HIGH>;
+ default-brightness = <13>;
+ };
--
2.26.2
^ permalink raw reply related [flat|nested] 8+ messages in thread
* Re: [PATCH 1/3 v3] dt-bindings: backlight: Add some common backlight properties
2020-08-19 20:51 [PATCH 1/3 v3] dt-bindings: backlight: Add some common backlight properties Linus Walleij
2020-08-19 20:51 ` [PATCH 2/3 v3] dt-bindings: backlight: Add Kinetic KTD253 bindings Linus Walleij
@ 2020-08-20 16:37 ` Daniel Thompson
2020-08-24 17:24 ` Rob Herring
2020-08-28 10:46 ` Lee Jones
3 siblings, 0 replies; 8+ messages in thread
From: Daniel Thompson @ 2020-08-20 16:37 UTC (permalink / raw)
To: Linus Walleij; +Cc: Lee Jones, Jingoo Han, dri-devel, devicetree, Sam Ravnborg
On Wed, Aug 19, 2020 at 10:51:48PM +0200, Linus Walleij wrote:
> Let's use a common.yaml include for the backlight like we do with
> the LEDs. The LEDs are inherently incompatible so their bindings
> cannot be reused for backlight.
>
> Cc: devicetree@vger.kernel.org
> Suggested-by: Sam Ravnborg <sam@ravnborg.org>
> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Reviewed-by: Daniel Thompson <daniel.thompson@linaro.org>
> ---
> ChangeLog v2->v3:
> - Drop the | for the description
> - Drop the "default-on" property, we're not using it.
> - Drop the minimum 0 for unsigned u32:s
> ChangeLog v1->v2:
> - New patch as suggested by Sam.
> ---
> .../bindings/leds/backlight/common.yaml | 34 +++++++++++++++++++
> 1 file changed, 34 insertions(+)
> create mode 100644 Documentation/devicetree/bindings/leds/backlight/common.yaml
>
> diff --git a/Documentation/devicetree/bindings/leds/backlight/common.yaml b/Documentation/devicetree/bindings/leds/backlight/common.yaml
> new file mode 100644
> index 000000000000..4e7e95e331a5
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/leds/backlight/common.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/backlight/common.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Common backlight properties
> +
> +maintainers:
> + - Lee Jones <lee.jones@linaro.org>
> + - Daniel Thompson <daniel.thompson@linaro.org>
> + - Jingoo Han <jingoohan1@gmail.com>
> +
> +description:
> + Backlight devices provide backlight for different types of graphical
> + displays. They are typically but not necessarily implemented using a white
> + LED powered by a boost converter.
> +
> +properties:
> + default-brightness:
> + description:
> + The default brightness that should be applied to the LED by the operating
> + system on start-up. The brightness should not exceed the brightness the
> + LED can provide.
> + $ref: /schemas/types.yaml#definitions/uint32
> +
> + max-brightness:
> + description:
> + Normally the maximum brightness is determined by the hardware and this
> + property is not required. This property is used to put a software limit
> + on the brightness apart from what the driver says, as it could happen
> + that a LED can be made so bright that it gets damaged or causes damage
> + due to restrictions in a specific system, such as mounting conditions.
> + $ref: /schemas/types.yaml#definitions/uint32
> --
> 2.26.2
>
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH 2/3 v3] dt-bindings: backlight: Add Kinetic KTD253 bindings
2020-08-19 20:51 ` [PATCH 2/3 v3] dt-bindings: backlight: Add Kinetic KTD253 bindings Linus Walleij
@ 2020-08-20 16:38 ` Daniel Thompson
2020-08-24 17:25 ` Rob Herring
2020-08-28 10:46 ` Lee Jones
2 siblings, 0 replies; 8+ messages in thread
From: Daniel Thompson @ 2020-08-20 16:38 UTC (permalink / raw)
To: Linus Walleij; +Cc: Lee Jones, Jingoo Han, dri-devel, devicetree, Sam Ravnborg
On Wed, Aug 19, 2020 at 10:51:49PM +0200, Linus Walleij wrote:
> This adds device tree bindings for the Kinetic KTD253
> white LED backlight driver.
>
> Cc: devicetree@vger.kernel.org
> Cc: Sam Ravnborg <sam@ravnborg.org>
> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Reviewed-by: Daniel Thompson <daniel.thompson@linaro.org>
> ---
> ChangeLog v2->v3:
> - Drop the pointless cargo-culted "default-on" property that
> we were not using
> - Correct the brightness in the example to something legal (13)
> ChangeLog v1->v2:
> - Create common.yaml for backlight as suggested by Sam and
> use that.
> - Rename the GPIO line "enable-gpios"
> ---
> .../leds/backlight/kinetic,ktd253.yaml | 46 +++++++++++++++++++
> 1 file changed, 46 insertions(+)
> create mode 100644 Documentation/devicetree/bindings/leds/backlight/kinetic,ktd253.yaml
>
> diff --git a/Documentation/devicetree/bindings/leds/backlight/kinetic,ktd253.yaml b/Documentation/devicetree/bindings/leds/backlight/kinetic,ktd253.yaml
> new file mode 100644
> index 000000000000..7a6ec1f8c0f3
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/leds/backlight/kinetic,ktd253.yaml
> @@ -0,0 +1,46 @@
> +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/leds/backlight/kinetic,ktd253.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Kinetic Technologies KTD253 one-wire backlight
> +
> +maintainers:
> + - Linus Walleij <linus.walleij@linaro.org>
> +
> +description: |
> + The Kinetic Technologies KTD253 is a white LED backlight that is
> + controlled by a single GPIO line. If you just turn on the backlight
> + it goes to maximum backlight then you can set the level of backlight
> + using pulses on the enable wire. This is sometimes referred to as
> + "expresswire".
> +
> +allOf:
> + - $ref: common.yaml#
> +
> +properties:
> + compatible:
> + const: kinetic,ktd253
> +
> + enable-gpios:
> + description: GPIO to use to enable/disable and dim the backlight.
> + maxItems: 1
> +
> + default-brightness: true
> + max-brightness: true
> +
> +required:
> + - compatible
> + - enable-gpios
> +
> +additionalProperties: false
> +
> +examples:
> + - |
> + #include <dt-bindings/gpio/gpio.h>
> + backlight {
> + compatible = "kinetic,ktd253";
> + enable-gpios = <&gpio2 5 GPIO_ACTIVE_HIGH>;
> + default-brightness = <13>;
> + };
> --
> 2.26.2
>
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH 1/3 v3] dt-bindings: backlight: Add some common backlight properties
2020-08-19 20:51 [PATCH 1/3 v3] dt-bindings: backlight: Add some common backlight properties Linus Walleij
2020-08-19 20:51 ` [PATCH 2/3 v3] dt-bindings: backlight: Add Kinetic KTD253 bindings Linus Walleij
2020-08-20 16:37 ` [PATCH 1/3 v3] dt-bindings: backlight: Add some common backlight properties Daniel Thompson
@ 2020-08-24 17:24 ` Rob Herring
2020-08-28 10:46 ` Lee Jones
3 siblings, 0 replies; 8+ messages in thread
From: Rob Herring @ 2020-08-24 17:24 UTC (permalink / raw)
To: Linus Walleij
Cc: Lee Jones, Daniel Thompson, Jingoo Han, dri-devel, devicetree,
Sam Ravnborg
On Wed, Aug 19, 2020 at 10:51:48PM +0200, Linus Walleij wrote:
> Let's use a common.yaml include for the backlight like we do with
> the LEDs. The LEDs are inherently incompatible so their bindings
> cannot be reused for backlight.
>
> Cc: devicetree@vger.kernel.org
> Suggested-by: Sam Ravnborg <sam@ravnborg.org>
> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
> ---
> ChangeLog v2->v3:
> - Drop the | for the description
> - Drop the "default-on" property, we're not using it.
> - Drop the minimum 0 for unsigned u32:s
> ChangeLog v1->v2:
> - New patch as suggested by Sam.
> ---
> .../bindings/leds/backlight/common.yaml | 34 +++++++++++++++++++
> 1 file changed, 34 insertions(+)
> create mode 100644 Documentation/devicetree/bindings/leds/backlight/common.yaml
Reviewed-by: Rob Herring <robh@kernel.org>
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH 2/3 v3] dt-bindings: backlight: Add Kinetic KTD253 bindings
2020-08-19 20:51 ` [PATCH 2/3 v3] dt-bindings: backlight: Add Kinetic KTD253 bindings Linus Walleij
2020-08-20 16:38 ` Daniel Thompson
@ 2020-08-24 17:25 ` Rob Herring
2020-08-28 10:46 ` Lee Jones
2 siblings, 0 replies; 8+ messages in thread
From: Rob Herring @ 2020-08-24 17:25 UTC (permalink / raw)
To: Linus Walleij
Cc: Sam Ravnborg, Daniel Thompson, Lee Jones, Jingoo Han, dri-devel,
devicetree
On Wed, 19 Aug 2020 22:51:49 +0200, Linus Walleij wrote:
> This adds device tree bindings for the Kinetic KTD253
> white LED backlight driver.
>
> Cc: devicetree@vger.kernel.org
> Cc: Sam Ravnborg <sam@ravnborg.org>
> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
> ---
> ChangeLog v2->v3:
> - Drop the pointless cargo-culted "default-on" property that
> we were not using
> - Correct the brightness in the example to something legal (13)
> ChangeLog v1->v2:
> - Create common.yaml for backlight as suggested by Sam and
> use that.
> - Rename the GPIO line "enable-gpios"
> ---
> .../leds/backlight/kinetic,ktd253.yaml | 46 +++++++++++++++++++
> 1 file changed, 46 insertions(+)
> create mode 100644 Documentation/devicetree/bindings/leds/backlight/kinetic,ktd253.yaml
>
Reviewed-by: Rob Herring <robh@kernel.org>
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH 1/3 v3] dt-bindings: backlight: Add some common backlight properties
2020-08-19 20:51 [PATCH 1/3 v3] dt-bindings: backlight: Add some common backlight properties Linus Walleij
` (2 preceding siblings ...)
2020-08-24 17:24 ` Rob Herring
@ 2020-08-28 10:46 ` Lee Jones
3 siblings, 0 replies; 8+ messages in thread
From: Lee Jones @ 2020-08-28 10:46 UTC (permalink / raw)
To: Linus Walleij
Cc: Daniel Thompson, Jingoo Han, dri-devel, devicetree, Sam Ravnborg
On Wed, 19 Aug 2020, Linus Walleij wrote:
> Let's use a common.yaml include for the backlight like we do with
> the LEDs. The LEDs are inherently incompatible so their bindings
> cannot be reused for backlight.
>
> Cc: devicetree@vger.kernel.org
> Suggested-by: Sam Ravnborg <sam@ravnborg.org>
> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
> ---
> ChangeLog v2->v3:
> - Drop the | for the description
> - Drop the "default-on" property, we're not using it.
> - Drop the minimum 0 for unsigned u32:s
> ChangeLog v1->v2:
> - New patch as suggested by Sam.
> ---
> .../bindings/leds/backlight/common.yaml | 34 +++++++++++++++++++
> 1 file changed, 34 insertions(+)
> create mode 100644 Documentation/devicetree/bindings/leds/backlight/common.yaml
Applied, thanks.
--
Lee Jones [李琼斯]
Senior Technical Lead - Developer Services
Linaro.org │ Open source software for Arm SoCs
Follow Linaro: Facebook | Twitter | Blog
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH 2/3 v3] dt-bindings: backlight: Add Kinetic KTD253 bindings
2020-08-19 20:51 ` [PATCH 2/3 v3] dt-bindings: backlight: Add Kinetic KTD253 bindings Linus Walleij
2020-08-20 16:38 ` Daniel Thompson
2020-08-24 17:25 ` Rob Herring
@ 2020-08-28 10:46 ` Lee Jones
2 siblings, 0 replies; 8+ messages in thread
From: Lee Jones @ 2020-08-28 10:46 UTC (permalink / raw)
To: Linus Walleij
Cc: Daniel Thompson, Jingoo Han, dri-devel, devicetree, Sam Ravnborg
On Wed, 19 Aug 2020, Linus Walleij wrote:
> This adds device tree bindings for the Kinetic KTD253
> white LED backlight driver.
>
> Cc: devicetree@vger.kernel.org
> Cc: Sam Ravnborg <sam@ravnborg.org>
> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
> ---
> ChangeLog v2->v3:
> - Drop the pointless cargo-culted "default-on" property that
> we were not using
> - Correct the brightness in the example to something legal (13)
> ChangeLog v1->v2:
> - Create common.yaml for backlight as suggested by Sam and
> use that.
> - Rename the GPIO line "enable-gpios"
> ---
> .../leds/backlight/kinetic,ktd253.yaml | 46 +++++++++++++++++++
> 1 file changed, 46 insertions(+)
> create mode 100644 Documentation/devicetree/bindings/leds/backlight/kinetic,ktd253.yaml
Applied, thanks.
--
Lee Jones [李琼斯]
Senior Technical Lead - Developer Services
Linaro.org │ Open source software for Arm SoCs
Follow Linaro: Facebook | Twitter | Blog
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2020-08-28 10:47 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-08-19 20:51 [PATCH 1/3 v3] dt-bindings: backlight: Add some common backlight properties Linus Walleij
2020-08-19 20:51 ` [PATCH 2/3 v3] dt-bindings: backlight: Add Kinetic KTD253 bindings Linus Walleij
2020-08-20 16:38 ` Daniel Thompson
2020-08-24 17:25 ` Rob Herring
2020-08-28 10:46 ` Lee Jones
2020-08-20 16:37 ` [PATCH 1/3 v3] dt-bindings: backlight: Add some common backlight properties Daniel Thompson
2020-08-24 17:24 ` Rob Herring
2020-08-28 10:46 ` Lee Jones
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).