* [PATCH v2] dt-bindings: gpio: fsl,qoriq-gpio: allow gpio-hog child nodes
@ 2026-08-24 21:54 Vincent Jardin via B4 Relay
2026-08-25 6:56 ` Alexander Stein
2026-08-25 7:09 ` Krzysztof Kozlowski
0 siblings, 2 replies; 4+ messages in thread
From: Vincent Jardin via B4 Relay @ 2026-08-24 21:54 UTC (permalink / raw)
To: Linus Walleij, Bartosz Golaszewski, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Frank Li
Cc: linux-gpio, devicetree, linux-kernel, Vincent Jardin
From: Vincent Jardin <vjardin@free.fr>
The binding sets additionalProperties: false and describes no child nodes,
so a gpio-hog on a QorIQ/Layerscape GPIO controller is rejected by
dtbs_check as an unmatched node name, even though the hardware and the
kernel both support it.
Hogs are not a controller feature and need nothing from the driver:
gpio-mpc8xxx.c does not mention them at all. A hog on this controller
works today, only the schema rejects it.
QorIQ and Layerscape boards do need them. These SoCs bring board-level
reset, enable and mux-select lines out on the SoC GPIOs, and those lines
have to be driven to a safe level at boot before any consumer claims them,
which is exactly what a hog is for.
Some boards in the tree already express this need where they can:
fsl-ls1088a-ten64.dts and the tqmls1012a/ls1028a boards all carry hogs, but
on I2C GPIO expanders, because that is the only place the schema currently
supports them. No board uses one on this controller yet, so this fixes no
current failure.
Other GPIO bindings already carry the same block. gpio-mvebu.yaml and
gpio-davinci.yaml use the identical "^(.+-hog(-[0-9]+)?)$" object requiring
gpio-hog.
Signed-off-by: Vincent Jardin <vjardin@free.fr>
---
Changes in v2:
- Change the commit message. Drop the dmesg excerpt: those hog names come
from my out-of-tree dev git repo and are not in the tree (Frank Li)
- Note: the hog call path is: gpiochip_hog_lines(), called from gpiochip_add_data_with_key()
- Explain why these QorIQ SoCs need it
- No change to the diff
- Link to v1: https://lore.kernel.org/r/20260824-for-upstream-dt-qoriq-gpio-hog-v1-1-d75923bcecad@free.fr
---
Documentation/devicetree/bindings/gpio/fsl,qoriq-gpio.yaml | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/Documentation/devicetree/bindings/gpio/fsl,qoriq-gpio.yaml b/Documentation/devicetree/bindings/gpio/fsl,qoriq-gpio.yaml
index 4cb2a6b9fabfb..a6252440e099b 100644
--- a/Documentation/devicetree/bindings/gpio/fsl,qoriq-gpio.yaml
+++ b/Documentation/devicetree/bindings/gpio/fsl,qoriq-gpio.yaml
@@ -63,6 +63,13 @@ properties:
GPIO registers are used as little endian. If not
present registers are used as big endian by default.
+patternProperties:
+ "^(.+-hog(-[0-9]+)?)$":
+ type: object
+
+ required:
+ - gpio-hog
+
required:
- compatible
- reg
---
base-commit: 0a0d1d55dad570724bf8c7ea83409639cfb4be9b
change-id: 20260824-for-upstream-dt-qoriq-gpio-hog-5092a0f4d089
Best regards,
--
Vincent Jardin <vjardin@free.fr>
^ permalink raw reply related [flat|nested] 4+ messages in thread* Re: [PATCH v2] dt-bindings: gpio: fsl,qoriq-gpio: allow gpio-hog child nodes
2026-08-24 21:54 [PATCH v2] dt-bindings: gpio: fsl,qoriq-gpio: allow gpio-hog child nodes Vincent Jardin via B4 Relay
@ 2026-08-25 6:56 ` Alexander Stein
2026-08-25 9:36 ` Vincent Jardin
2026-08-25 7:09 ` Krzysztof Kozlowski
1 sibling, 1 reply; 4+ messages in thread
From: Alexander Stein @ 2026-08-25 6:56 UTC (permalink / raw)
To: Linus Walleij, Bartosz Golaszewski, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Frank Li, vjardin
Cc: linux-gpio, devicetree, linux-kernel, Vincent Jardin
Am Montag, 24. August 2026, 23:54:40 CEST schrieb Vincent Jardin via B4 Relay:
> From: Vincent Jardin <vjardin@free.fr>
>
> The binding sets additionalProperties: false and describes no child nodes,
> so a gpio-hog on a QorIQ/Layerscape GPIO controller is rejected by
> dtbs_check as an unmatched node name, even though the hardware and the
> kernel both support it.
>
> Hogs are not a controller feature and need nothing from the driver:
> gpio-mpc8xxx.c does not mention them at all. A hog on this controller
> works today, only the schema rejects it.
>
> QorIQ and Layerscape boards do need them. These SoCs bring board-level
> reset, enable and mux-select lines out on the SoC GPIOs, and those lines
> have to be driven to a safe level at boot before any consumer claims them,
> which is exactly what a hog is for.
>
> Some boards in the tree already express this need where they can:
> fsl-ls1088a-ten64.dts and the tqmls1012a/ls1028a boards all carry hogs, but
> on I2C GPIO expanders, because that is the only place the schema currently
> supports them. No board uses one on this controller yet, so this fixes no
> current failure.
>
> Other GPIO bindings already carry the same block. gpio-mvebu.yaml and
> gpio-davinci.yaml use the identical "^(.+-hog(-[0-9]+)?)$" object requiring
> gpio-hog.
>
> Signed-off-by: Vincent Jardin <vjardin@free.fr>
> ---
> Changes in v2:
> - Change the commit message. Drop the dmesg excerpt: those hog names come
> from my out-of-tree dev git repo and are not in the tree (Frank Li)
> - Note: the hog call path is: gpiochip_hog_lines(), called from gpiochip_add_data_with_key()
> - Explain why these QorIQ SoCs need it
> - No change to the diff
> - Link to v1: https://lore.kernel.org/r/20260824-for-upstream-dt-qoriq-gpio-hog-v1-1-d75923bcecad@free.fr
> ---
> Documentation/devicetree/bindings/gpio/fsl,qoriq-gpio.yaml | 7 +++++++
> 1 file changed, 7 insertions(+)
>
> diff --git a/Documentation/devicetree/bindings/gpio/fsl,qoriq-gpio.yaml b/Documentation/devicetree/bindings/gpio/fsl,qoriq-gpio.yaml
> index 4cb2a6b9fabfb..a6252440e099b 100644
> --- a/Documentation/devicetree/bindings/gpio/fsl,qoriq-gpio.yaml
> +++ b/Documentation/devicetree/bindings/gpio/fsl,qoriq-gpio.yaml
> @@ -63,6 +63,13 @@ properties:
> GPIO registers are used as little endian. If not
> present registers are used as big endian by default.
>
> +patternProperties:
> + "^(.+-hog(-[0-9]+)?)$":
> + type: object
> +
> + required:
> + - gpio-hog
> +
Shouldn't you reference gpio-hog.yaml schema instead? This already has (among
others) patter and required properties. But I'm no expert on bindings.
Best regards
Alexander
> required:
> - compatible
> - reg
>
> ---
> base-commit: 0a0d1d55dad570724bf8c7ea83409639cfb4be9b
> change-id: 20260824-for-upstream-dt-qoriq-gpio-hog-5092a0f4d089
>
> Best regards,
>
--
TQ-Systems GmbH | Mühlstraße 2, Gut Delling | 82229 Seefeld, Germany
Amtsgericht München, HRB 105018
Geschäftsführer: Detlef Schneider, Rüdiger Stahl, Stefan Schneider
http://www.tq-group.com/
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH v2] dt-bindings: gpio: fsl,qoriq-gpio: allow gpio-hog child nodes
2026-08-25 6:56 ` Alexander Stein
@ 2026-08-25 9:36 ` Vincent Jardin
0 siblings, 0 replies; 4+ messages in thread
From: Vincent Jardin @ 2026-08-25 9:36 UTC (permalink / raw)
To: Alexander Stein
Cc: Linus Walleij, Bartosz Golaszewski, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Frank Li, linux-gpio,
devicetree, linux-kernel
Hi Alexander,
> Shouldn't you reference gpio-hog.yaml schema instead? This already has (among
> others) patter and required properties. But I'm no expert on bindings.
I just tried but I did not succeed: it seems it needs more rework or a different
clean up for all the users. I guess, that's why none of the in-tree bindings
does it.
Maybe it can be revisited for all the cases later on.
Best regards,
Vincent
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH v2] dt-bindings: gpio: fsl,qoriq-gpio: allow gpio-hog child nodes
2026-08-24 21:54 [PATCH v2] dt-bindings: gpio: fsl,qoriq-gpio: allow gpio-hog child nodes Vincent Jardin via B4 Relay
2026-08-25 6:56 ` Alexander Stein
@ 2026-08-25 7:09 ` Krzysztof Kozlowski
1 sibling, 0 replies; 4+ messages in thread
From: Krzysztof Kozlowski @ 2026-08-25 7:09 UTC (permalink / raw)
To: vjardin, Linus Walleij, Bartosz Golaszewski, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Frank Li
Cc: linux-gpio, devicetree, linux-kernel
On 24/08/2026 23:54, Vincent Jardin via B4 Relay wrote:
> From: Vincent Jardin <vjardin@free.fr>
>
> The binding sets additionalProperties: false and describes no child nodes,
> so a gpio-hog on a QorIQ/Layerscape GPIO controller is rejected by
> dtbs_check as an unmatched node name, even though the hardware and the
> kernel both support it.
>
> Hogs are not a controller feature and need nothing from the driver:
> gpio-mpc8xxx.c does not mention them at all. A hog on this controller
> works today, only the schema rejects it.
>
> QorIQ and Layerscape boards do need them. These SoCs bring board-level
> reset, enable and mux-select lines out on the SoC GPIOs, and those lines
> have to be driven to a safe level at boot before any consumer claims them,
> which is exactly what a hog is for.
>
> Some boards in the tree already express this need where they can:
> fsl-ls1088a-ten64.dts and the tqmls1012a/ls1028a boards all carry hogs, but
> on I2C GPIO expanders, because that is the only place the schema currently
> supports them. No board uses one on this controller yet, so this fixes no
> current failure.
>
> Other GPIO bindings already carry the same block. gpio-mvebu.yaml and
> gpio-davinci.yaml use the identical "^(.+-hog(-[0-9]+)?)$" object requiring
> gpio-hog.
This paragraph is redundant. Frankly speaking, half of the entire commit
msg is redundant, because it states the obvious - GPIO controller may
have hogs in device nodes and this is a GPIO controller. Efficient
commit msgs are preferred over long ones.
>
> Signed-off-by: Vincent Jardin <vjardin@free.fr>
> ---
> Changes in v2:
> - Change the commit message. Drop the dmesg excerpt: those hog names come
> from my out-of-tree dev git repo and are not in the tree (Frank Li)
> - Note: the hog call path is: gpiochip_hog_lines(), called from gpiochip_add_data_with_key()
> - Explain why these QorIQ SoCs need it
> - No change to the diff
> - Link to v1: https://lore.kernel.org/r/20260824-for-upstream-dt-qoriq-gpio-hog-v1-1-d75923bcecad@free.fr
> ---
> Documentation/devicetree/bindings/gpio/fsl,qoriq-gpio.yaml | 7 +++++++
> 1 file changed, 7 insertions(+)
>
> diff --git a/Documentation/devicetree/bindings/gpio/fsl,qoriq-gpio.yaml b/Documentation/devicetree/bindings/gpio/fsl,qoriq-gpio.yaml
> index 4cb2a6b9fabfb..a6252440e099b 100644
> --- a/Documentation/devicetree/bindings/gpio/fsl,qoriq-gpio.yaml
> +++ b/Documentation/devicetree/bindings/gpio/fsl,qoriq-gpio.yaml
> @@ -63,6 +63,13 @@ properties:
> GPIO registers are used as little endian. If not
> present registers are used as big endian by default.
>
> +patternProperties:
> + "^(.+-hog(-[0-9]+)?)$":
Pattern is: "^.+-hog(-[0-9]+)?$":
(outer brackets are redundant)
With these two fixed:
Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com>
Best regards,
Krzysztof
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2026-08-25 9:37 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-08-24 21:54 [PATCH v2] dt-bindings: gpio: fsl,qoriq-gpio: allow gpio-hog child nodes Vincent Jardin via B4 Relay
2026-08-25 6:56 ` Alexander Stein
2026-08-25 9:36 ` Vincent Jardin
2026-08-25 7:09 ` Krzysztof Kozlowski
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox