linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] dt-bindings: leds: Drop redundant cpus enum match
@ 2023-04-24 15:14 Nishanth Menon
  2023-04-25 13:34 ` Manivannan Sadhasivam
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Nishanth Menon @ 2023-04-24 15:14 UTC (permalink / raw)
  To: Manivannan Sadhasivam, Jacek Anaszewski, Krzysztof Kozlowski,
	Rob Herring, Lee Jones, Pavel Machek
  Cc: linux-kernel, devicetree, linux-leds, linux-arm-kernel,
	Vignesh Raghavendra, Nishanth Menon, Manivannan Sadhasivam

Commit e91a4d5deb96 ("dt-bindings: leds: Document commonly used
LED triggers") introduced a enum match for cpu, while a pattern
'^cpu[0-9]*$' already exists.

This causes linux,default-trigger = "cpu" to have more than one match
and generates the following dtbs_check warning:

arch/arm64/boot/dts/ti/k3-j721e-beagleboneai64.dtb: leds: led-2:linux,default-trigger: More than one condition true in oneOf schema:
	{'$ref': '/schemas/types.yaml#/definitions/string',
	 'oneOf': [{'items': [{'enum': ['backlight',
	                                'default-on',
	                                'heartbeat',
	                                'disk-activity',
	                                'disk-read',
	                                'disk-write',
	                                'timer',
	                                'pattern',
	                                'audio-micmute',
	                                'audio-mute',
	                                'bluetooth-power',
	                                'cpu',
	                                'flash',
	                                'kbd-capslock',
	                                'mtd',
	                                'nand-disk',
	                                'none',
	                                'torch',
	                                'usb-gadget',
	                                'usb-host',
	                                'usbport']}],
	            'maxItems': 1,
	            'minItems': 1,
	            'type': 'array'},
	           {'items': [{'pattern': '^cpu[0-9]*$'}],
	            'maxItems': 1,
	            'minItems': 1,
	            'type': 'array'},
	           {'items': [{'pattern': '^hci[0-9]+-power$'}],
	            'maxItems': 1,
	            'minItems': 1,
	            'type': 'array'},
	           {'items': [{'pattern': '^mmc[0-9]+$'}],
	            'maxItems': 1,
	            'minItems': 1,
	            'type': 'array'},
	           {'items': [{'pattern': '^phy[0-9]+tx$'}],
	            'maxItems': 1,
	            'minItems': 1,
	            'type': 'array'}]}

Drop the explicit match against cpu since the pattern match already
covers the same.

Fixes: e91a4d5deb96 ("dt-bindings: leds: Document commonly used LED triggers")
Cc: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Signed-off-by: Nishanth Menon <nm@ti.com>
---
 Documentation/devicetree/bindings/leds/common.yaml | 2 --
 1 file changed, 2 deletions(-)

diff --git a/Documentation/devicetree/bindings/leds/common.yaml b/Documentation/devicetree/bindings/leds/common.yaml
index 11aedf1650a1..58b492d00246 100644
--- a/Documentation/devicetree/bindings/leds/common.yaml
+++ b/Documentation/devicetree/bindings/leds/common.yaml
@@ -105,8 +105,6 @@ properties:
           - audio-mute
             # LED indicates bluetooth power state
           - bluetooth-power
-            # LED indicates activity of all CPUs
-          - cpu
             # LED indicates camera flash state
           - flash
             # LED indicated keyboard capslock
-- 
2.40.0


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

* Re: [PATCH] dt-bindings: leds: Drop redundant cpus enum match
  2023-04-24 15:14 [PATCH] dt-bindings: leds: Drop redundant cpus enum match Nishanth Menon
@ 2023-04-25 13:34 ` Manivannan Sadhasivam
  2023-04-25 18:55 ` Rob Herring
  2023-04-27 17:17 ` Lee Jones
  2 siblings, 0 replies; 4+ messages in thread
From: Manivannan Sadhasivam @ 2023-04-25 13:34 UTC (permalink / raw)
  To: Nishanth Menon
  Cc: Manivannan Sadhasivam, Jacek Anaszewski, Krzysztof Kozlowski,
	Rob Herring, Lee Jones, Pavel Machek, linux-kernel, devicetree,
	linux-leds, linux-arm-kernel, Vignesh Raghavendra

On Mon, Apr 24, 2023 at 10:14:37AM -0500, Nishanth Menon wrote:
> Commit e91a4d5deb96 ("dt-bindings: leds: Document commonly used
> LED triggers") introduced a enum match for cpu, while a pattern
> '^cpu[0-9]*$' already exists.
> 
> This causes linux,default-trigger = "cpu" to have more than one match
> and generates the following dtbs_check warning:
> 
> arch/arm64/boot/dts/ti/k3-j721e-beagleboneai64.dtb: leds: led-2:linux,default-trigger: More than one condition true in oneOf schema:
> 	{'$ref': '/schemas/types.yaml#/definitions/string',
> 	 'oneOf': [{'items': [{'enum': ['backlight',
> 	                                'default-on',
> 	                                'heartbeat',
> 	                                'disk-activity',
> 	                                'disk-read',
> 	                                'disk-write',
> 	                                'timer',
> 	                                'pattern',
> 	                                'audio-micmute',
> 	                                'audio-mute',
> 	                                'bluetooth-power',
> 	                                'cpu',
> 	                                'flash',
> 	                                'kbd-capslock',
> 	                                'mtd',
> 	                                'nand-disk',
> 	                                'none',
> 	                                'torch',
> 	                                'usb-gadget',
> 	                                'usb-host',
> 	                                'usbport']}],
> 	            'maxItems': 1,
> 	            'minItems': 1,
> 	            'type': 'array'},
> 	           {'items': [{'pattern': '^cpu[0-9]*$'}],
> 	            'maxItems': 1,
> 	            'minItems': 1,
> 	            'type': 'array'},
> 	           {'items': [{'pattern': '^hci[0-9]+-power$'}],
> 	            'maxItems': 1,
> 	            'minItems': 1,
> 	            'type': 'array'},
> 	           {'items': [{'pattern': '^mmc[0-9]+$'}],
> 	            'maxItems': 1,
> 	            'minItems': 1,
> 	            'type': 'array'},
> 	           {'items': [{'pattern': '^phy[0-9]+tx$'}],
> 	            'maxItems': 1,
> 	            'minItems': 1,
> 	            'type': 'array'}]}
> 
> Drop the explicit match against cpu since the pattern match already
> covers the same.
> 
> Fixes: e91a4d5deb96 ("dt-bindings: leds: Document commonly used LED triggers")
> Cc: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
> Signed-off-by: Nishanth Menon <nm@ti.com>

Acked-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>

- Mani

> ---
>  Documentation/devicetree/bindings/leds/common.yaml | 2 --
>  1 file changed, 2 deletions(-)
> 
> diff --git a/Documentation/devicetree/bindings/leds/common.yaml b/Documentation/devicetree/bindings/leds/common.yaml
> index 11aedf1650a1..58b492d00246 100644
> --- a/Documentation/devicetree/bindings/leds/common.yaml
> +++ b/Documentation/devicetree/bindings/leds/common.yaml
> @@ -105,8 +105,6 @@ properties:
>            - audio-mute
>              # LED indicates bluetooth power state
>            - bluetooth-power
> -            # LED indicates activity of all CPUs
> -          - cpu
>              # LED indicates camera flash state
>            - flash
>              # LED indicated keyboard capslock
> -- 
> 2.40.0
> 

-- 
மணிவண்ணன் சதாசிவம்

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

* Re: [PATCH] dt-bindings: leds: Drop redundant cpus enum match
  2023-04-24 15:14 [PATCH] dt-bindings: leds: Drop redundant cpus enum match Nishanth Menon
  2023-04-25 13:34 ` Manivannan Sadhasivam
@ 2023-04-25 18:55 ` Rob Herring
  2023-04-27 17:17 ` Lee Jones
  2 siblings, 0 replies; 4+ messages in thread
From: Rob Herring @ 2023-04-25 18:55 UTC (permalink / raw)
  To: Nishanth Menon
  Cc: Krzysztof Kozlowski, linux-leds, Jacek Anaszewski, Pavel Machek,
	Vignesh Raghavendra, linux-arm-kernel, devicetree,
	Manivannan Sadhasivam, Manivannan Sadhasivam, linux-kernel,
	Lee Jones, Rob Herring


On Mon, 24 Apr 2023 10:14:37 -0500, Nishanth Menon wrote:
> Commit e91a4d5deb96 ("dt-bindings: leds: Document commonly used
> LED triggers") introduced a enum match for cpu, while a pattern
> '^cpu[0-9]*$' already exists.
> 
> This causes linux,default-trigger = "cpu" to have more than one match
> and generates the following dtbs_check warning:
> 
> arch/arm64/boot/dts/ti/k3-j721e-beagleboneai64.dtb: leds: led-2:linux,default-trigger: More than one condition true in oneOf schema:
> 	{'$ref': '/schemas/types.yaml#/definitions/string',
> 	 'oneOf': [{'items': [{'enum': ['backlight',
> 	                                'default-on',
> 	                                'heartbeat',
> 	                                'disk-activity',
> 	                                'disk-read',
> 	                                'disk-write',
> 	                                'timer',
> 	                                'pattern',
> 	                                'audio-micmute',
> 	                                'audio-mute',
> 	                                'bluetooth-power',
> 	                                'cpu',
> 	                                'flash',
> 	                                'kbd-capslock',
> 	                                'mtd',
> 	                                'nand-disk',
> 	                                'none',
> 	                                'torch',
> 	                                'usb-gadget',
> 	                                'usb-host',
> 	                                'usbport']}],
> 	            'maxItems': 1,
> 	            'minItems': 1,
> 	            'type': 'array'},
> 	           {'items': [{'pattern': '^cpu[0-9]*$'}],
> 	            'maxItems': 1,
> 	            'minItems': 1,
> 	            'type': 'array'},
> 	           {'items': [{'pattern': '^hci[0-9]+-power$'}],
> 	            'maxItems': 1,
> 	            'minItems': 1,
> 	            'type': 'array'},
> 	           {'items': [{'pattern': '^mmc[0-9]+$'}],
> 	            'maxItems': 1,
> 	            'minItems': 1,
> 	            'type': 'array'},
> 	           {'items': [{'pattern': '^phy[0-9]+tx$'}],
> 	            'maxItems': 1,
> 	            'minItems': 1,
> 	            'type': 'array'}]}
> 
> Drop the explicit match against cpu since the pattern match already
> covers the same.
> 
> Fixes: e91a4d5deb96 ("dt-bindings: leds: Document commonly used LED triggers")
> Cc: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
> Signed-off-by: Nishanth Menon <nm@ti.com>
> ---
>  Documentation/devicetree/bindings/leds/common.yaml | 2 --
>  1 file changed, 2 deletions(-)
> 

Acked-by: Rob Herring <robh@kernel.org>


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

* Re: [PATCH] dt-bindings: leds: Drop redundant cpus enum match
  2023-04-24 15:14 [PATCH] dt-bindings: leds: Drop redundant cpus enum match Nishanth Menon
  2023-04-25 13:34 ` Manivannan Sadhasivam
  2023-04-25 18:55 ` Rob Herring
@ 2023-04-27 17:17 ` Lee Jones
  2 siblings, 0 replies; 4+ messages in thread
From: Lee Jones @ 2023-04-27 17:17 UTC (permalink / raw)
  To: Nishanth Menon
  Cc: Manivannan Sadhasivam, Jacek Anaszewski, Krzysztof Kozlowski,
	Rob Herring, Pavel Machek, linux-kernel, devicetree, linux-leds,
	linux-arm-kernel, Vignesh Raghavendra, Manivannan Sadhasivam

On Mon, 24 Apr 2023, Nishanth Menon wrote:

> Commit e91a4d5deb96 ("dt-bindings: leds: Document commonly used
> LED triggers") introduced a enum match for cpu, while a pattern
> '^cpu[0-9]*$' already exists.
> 
> This causes linux,default-trigger = "cpu" to have more than one match
> and generates the following dtbs_check warning:
> 
> arch/arm64/boot/dts/ti/k3-j721e-beagleboneai64.dtb: leds: led-2:linux,default-trigger: More than one condition true in oneOf schema:
> 	{'$ref': '/schemas/types.yaml#/definitions/string',
> 	 'oneOf': [{'items': [{'enum': ['backlight',
> 	                                'default-on',
> 	                                'heartbeat',
> 	                                'disk-activity',
> 	                                'disk-read',
> 	                                'disk-write',
> 	                                'timer',
> 	                                'pattern',
> 	                                'audio-micmute',
> 	                                'audio-mute',
> 	                                'bluetooth-power',
> 	                                'cpu',
> 	                                'flash',
> 	                                'kbd-capslock',
> 	                                'mtd',
> 	                                'nand-disk',
> 	                                'none',
> 	                                'torch',
> 	                                'usb-gadget',
> 	                                'usb-host',
> 	                                'usbport']}],
> 	            'maxItems': 1,
> 	            'minItems': 1,
> 	            'type': 'array'},
> 	           {'items': [{'pattern': '^cpu[0-9]*$'}],
> 	            'maxItems': 1,
> 	            'minItems': 1,
> 	            'type': 'array'},
> 	           {'items': [{'pattern': '^hci[0-9]+-power$'}],
> 	            'maxItems': 1,
> 	            'minItems': 1,
> 	            'type': 'array'},
> 	           {'items': [{'pattern': '^mmc[0-9]+$'}],
> 	            'maxItems': 1,
> 	            'minItems': 1,
> 	            'type': 'array'},
> 	           {'items': [{'pattern': '^phy[0-9]+tx$'}],
> 	            'maxItems': 1,
> 	            'minItems': 1,
> 	            'type': 'array'}]}
> 
> Drop the explicit match against cpu since the pattern match already
> covers the same.
> 
> Fixes: e91a4d5deb96 ("dt-bindings: leds: Document commonly used LED triggers")
> Cc: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
> Signed-off-by: Nishanth Menon <nm@ti.com>
> ---
>  Documentation/devicetree/bindings/leds/common.yaml | 2 --
>  1 file changed, 2 deletions(-)

Applied, thanks

-- 
Lee Jones [李琼斯]

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

end of thread, other threads:[~2023-04-27 17:17 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-04-24 15:14 [PATCH] dt-bindings: leds: Drop redundant cpus enum match Nishanth Menon
2023-04-25 13:34 ` Manivannan Sadhasivam
2023-04-25 18:55 ` Rob Herring
2023-04-27 17:17 ` 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).