linux-gpio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/2] dt-bindings: gpio: aspeed,sgpio: Miscellaneous cleanups
@ 2024-05-30  1:39 Andrew Jeffery
  2024-05-30  1:39 ` [PATCH v2 1/2] dt-bindings: gpio: aspeed,sgpio: Specify gpio-line-names Andrew Jeffery
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Andrew Jeffery @ 2024-05-30  1:39 UTC (permalink / raw)
  To: Linus Walleij, Bartosz Golaszewski, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Joel Stanley, Andrew Jeffery
  Cc: linux-gpio, devicetree, linux-arm-kernel, linux-aspeed,
	linux-kernel, Krzysztof Kozlowski

Hello,

This short series fixes some SGPIO-related devicetree warnings currently
emitted by `make dtbs_check` for Aspeed devicetrees.

Please review!

Andrew

---
Changes in v2:
- Dropped 1/4 from v1 as it was considered noise (Krzysztof)
- Squashed 4/4 into 3/4 from v1 (Krzysztof)
- Addressed remaining comments and applied tags (Krzysztof)
- Link to v1: https://lore.kernel.org/r/20240529-dt-warnings-gpio-sgpio-interrupt-cells-v1-0-91c42976833b@codeconstruct.com.au

---
Andrew Jeffery (2):
      dt-bindings: gpio: aspeed,sgpio: Specify gpio-line-names
      dt-bindings: gpio: aspeed,sgpio: Specify #interrupt-cells

 Documentation/devicetree/bindings/gpio/aspeed,sgpio.yaml | 10 ++++++++++
 1 file changed, 10 insertions(+)
---
base-commit: 1613e604df0cd359cf2a7fbd9be7a0bcfacfabd0
change-id: 20240528-dt-warnings-gpio-sgpio-interrupt-cells-685a0efd2c0b

Best regards,
-- 
Andrew Jeffery <andrew@codeconstruct.com.au>


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

* [PATCH v2 1/2] dt-bindings: gpio: aspeed,sgpio: Specify gpio-line-names
  2024-05-30  1:39 [PATCH v2 0/2] dt-bindings: gpio: aspeed,sgpio: Miscellaneous cleanups Andrew Jeffery
@ 2024-05-30  1:39 ` Andrew Jeffery
  2024-05-30  1:39 ` [PATCH v2 2/2] dt-bindings: gpio: aspeed,sgpio: Specify #interrupt-cells Andrew Jeffery
  2024-06-03  8:35 ` [PATCH v2 0/2] dt-bindings: gpio: aspeed,sgpio: Miscellaneous cleanups Bartosz Golaszewski
  2 siblings, 0 replies; 5+ messages in thread
From: Andrew Jeffery @ 2024-05-30  1:39 UTC (permalink / raw)
  To: Linus Walleij, Bartosz Golaszewski, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Joel Stanley, Andrew Jeffery
  Cc: linux-gpio, devicetree, linux-arm-kernel, linux-aspeed,
	linux-kernel, Krzysztof Kozlowski

Some devicetrees specify gpio-line-names in the sgpio node despite it
not being defined by the binding. It's a reasonable thing to do, so
define the property to squash warnings such as:

    arch/arm/boot/dts/aspeed/aspeed-bmc-vegman-rx20.dtb: sgpio@1e780200: 'gpio-line-names' does not match any of the regexes: 'pinctrl-[0-9]+'

Acked-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: Andrew Jeffery <andrew@codeconstruct.com.au>
---
 Documentation/devicetree/bindings/gpio/aspeed,sgpio.yaml | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/Documentation/devicetree/bindings/gpio/aspeed,sgpio.yaml b/Documentation/devicetree/bindings/gpio/aspeed,sgpio.yaml
index 46bb121360dc..34cdf1ad9c73 100644
--- a/Documentation/devicetree/bindings/gpio/aspeed,sgpio.yaml
+++ b/Documentation/devicetree/bindings/gpio/aspeed,sgpio.yaml
@@ -33,6 +33,11 @@ properties:
 
   gpio-controller: true
 
+  # Each SGPIO is represented as a pair of input and output GPIOs
+  gpio-line-names:
+    minItems: 160
+    maxItems: 256
+
   '#gpio-cells':
     const: 2
 

-- 
2.39.2


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

* [PATCH v2 2/2] dt-bindings: gpio: aspeed,sgpio: Specify #interrupt-cells
  2024-05-30  1:39 [PATCH v2 0/2] dt-bindings: gpio: aspeed,sgpio: Miscellaneous cleanups Andrew Jeffery
  2024-05-30  1:39 ` [PATCH v2 1/2] dt-bindings: gpio: aspeed,sgpio: Specify gpio-line-names Andrew Jeffery
@ 2024-05-30  1:39 ` Andrew Jeffery
  2024-05-30 16:32   ` Conor Dooley
  2024-06-03  8:35 ` [PATCH v2 0/2] dt-bindings: gpio: aspeed,sgpio: Miscellaneous cleanups Bartosz Golaszewski
  2 siblings, 1 reply; 5+ messages in thread
From: Andrew Jeffery @ 2024-05-30  1:39 UTC (permalink / raw)
  To: Linus Walleij, Bartosz Golaszewski, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Joel Stanley, Andrew Jeffery
  Cc: linux-gpio, devicetree, linux-arm-kernel, linux-aspeed,
	linux-kernel

Squash warnings such as:

    arch/arm/boot/dts/aspeed/aspeed-ast2500-evb.dtb: sgpio@1e780200: '#interrupt-cells' does not match any of the regexes: 'pinctrl-[0-9]+'

Also, mark #interrupt-cells as required. The kernel devicetrees already
specified it where compatible nodes were defined, and u-boot pulls in
the kernel devicetrees, so this should have minimal practical impact.

Signed-off-by: Andrew Jeffery <andrew@codeconstruct.com.au>
---
 Documentation/devicetree/bindings/gpio/aspeed,sgpio.yaml | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/Documentation/devicetree/bindings/gpio/aspeed,sgpio.yaml b/Documentation/devicetree/bindings/gpio/aspeed,sgpio.yaml
index 34cdf1ad9c73..1046f0331c09 100644
--- a/Documentation/devicetree/bindings/gpio/aspeed,sgpio.yaml
+++ b/Documentation/devicetree/bindings/gpio/aspeed,sgpio.yaml
@@ -46,6 +46,9 @@ properties:
 
   interrupt-controller: true
 
+  '#interrupt-cells':
+    const: 2
+
   clocks:
     maxItems: 1
 
@@ -60,6 +63,7 @@ required:
   - '#gpio-cells'
   - interrupts
   - interrupt-controller
+  - '#interrupt-cells'
   - ngpios
   - clocks
   - bus-frequency
@@ -77,6 +81,7 @@ examples:
         reg = <0x1e780200 0x0100>;
         clocks = <&syscon ASPEED_CLK_APB>;
         interrupt-controller;
+        #interrupt-cells = <2>;
         ngpios = <80>;
         bus-frequency = <12000000>;
     };

-- 
2.39.2


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

* Re: [PATCH v2 2/2] dt-bindings: gpio: aspeed,sgpio: Specify #interrupt-cells
  2024-05-30  1:39 ` [PATCH v2 2/2] dt-bindings: gpio: aspeed,sgpio: Specify #interrupt-cells Andrew Jeffery
@ 2024-05-30 16:32   ` Conor Dooley
  0 siblings, 0 replies; 5+ messages in thread
From: Conor Dooley @ 2024-05-30 16:32 UTC (permalink / raw)
  To: Andrew Jeffery
  Cc: Linus Walleij, Bartosz Golaszewski, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Joel Stanley, linux-gpio,
	devicetree, linux-arm-kernel, linux-aspeed, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 606 bytes --]

On Thu, May 30, 2024 at 11:09:49AM +0930, Andrew Jeffery wrote:
> Squash warnings such as:
> 
>     arch/arm/boot/dts/aspeed/aspeed-ast2500-evb.dtb: sgpio@1e780200: '#interrupt-cells' does not match any of the regexes: 'pinctrl-[0-9]+'
> 
> Also, mark #interrupt-cells as required. The kernel devicetrees already
> specified it where compatible nodes were defined, and u-boot pulls in
> the kernel devicetrees, so this should have minimal practical impact.
> 
> Signed-off-by: Andrew Jeffery <andrew@codeconstruct.com.au>

Acked-by: Conor Dooley <conor.dooley@microchip.com>

Thanks,
Conor.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]

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

* Re: [PATCH v2 0/2] dt-bindings: gpio: aspeed,sgpio: Miscellaneous cleanups
  2024-05-30  1:39 [PATCH v2 0/2] dt-bindings: gpio: aspeed,sgpio: Miscellaneous cleanups Andrew Jeffery
  2024-05-30  1:39 ` [PATCH v2 1/2] dt-bindings: gpio: aspeed,sgpio: Specify gpio-line-names Andrew Jeffery
  2024-05-30  1:39 ` [PATCH v2 2/2] dt-bindings: gpio: aspeed,sgpio: Specify #interrupt-cells Andrew Jeffery
@ 2024-06-03  8:35 ` Bartosz Golaszewski
  2 siblings, 0 replies; 5+ messages in thread
From: Bartosz Golaszewski @ 2024-06-03  8:35 UTC (permalink / raw)
  To: Linus Walleij, Bartosz Golaszewski, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Joel Stanley, Andrew Jeffery
  Cc: Bartosz Golaszewski, linux-gpio, devicetree, linux-arm-kernel,
	linux-aspeed, linux-kernel, Krzysztof Kozlowski

From: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>


On Thu, 30 May 2024 11:09:47 +0930, Andrew Jeffery wrote:
> This short series fixes some SGPIO-related devicetree warnings currently
> emitted by `make dtbs_check` for Aspeed devicetrees.
> 
> Please review!
> 
> Andrew
> 
> [...]

Applied, thanks!

[1/2] dt-bindings: gpio: aspeed,sgpio: Specify gpio-line-names
      commit: a31517b11bd188527b2f8a4b8fd3e91a10f44d04
[2/2] dt-bindings: gpio: aspeed,sgpio: Specify #interrupt-cells
      commit: 3a40985960bcab918da23f8945ab0cd3be12d716

Best regards,
-- 
Bartosz Golaszewski <bartosz.golaszewski@linaro.org>

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

end of thread, other threads:[~2024-06-03  8:35 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-05-30  1:39 [PATCH v2 0/2] dt-bindings: gpio: aspeed,sgpio: Miscellaneous cleanups Andrew Jeffery
2024-05-30  1:39 ` [PATCH v2 1/2] dt-bindings: gpio: aspeed,sgpio: Specify gpio-line-names Andrew Jeffery
2024-05-30  1:39 ` [PATCH v2 2/2] dt-bindings: gpio: aspeed,sgpio: Specify #interrupt-cells Andrew Jeffery
2024-05-30 16:32   ` Conor Dooley
2024-06-03  8:35 ` [PATCH v2 0/2] dt-bindings: gpio: aspeed,sgpio: Miscellaneous cleanups Bartosz Golaszewski

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).