* [PATCH] gpio: rcar: reinstate generic compat string
@ 2017-08-09 8:21 Simon Horman
2017-08-10 8:06 ` Simon Horman
2017-08-14 11:44 ` Geert Uytterhoeven
0 siblings, 2 replies; 4+ messages in thread
From: Simon Horman @ 2017-08-09 8:21 UTC (permalink / raw)
To: Geert Uytterhoeven
Cc: Linus Walleij, Magnus Damm, linux-gpio, linux-renesas-soc, Simon Horman
commit d10bbd156926 ("gpio: rcar: add gen[123] fallback compatibility
strings") deprecated the generic compat string, renesas,gpio-rcar. After
further discussion this appears not to have been desirable as that compat
string is compatible with all R-Car SoCs supported in upstream.
This commit partially reverts that commit, and updates related
documentation and examples.
Fixes: d10bbd156926 ("gpio: rcar: add gen[123] fallback compatibility strings")
Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
---
.../devicetree/bindings/gpio/renesas,gpio-rcar.txt | 18 ++++++++++++------
1 file changed, 12 insertions(+), 6 deletions(-)
diff --git a/Documentation/devicetree/bindings/gpio/renesas,gpio-rcar.txt b/Documentation/devicetree/bindings/gpio/renesas,gpio-rcar.txt
index 48634b01f1bf..347d8ede2982 100644
--- a/Documentation/devicetree/bindings/gpio/renesas,gpio-rcar.txt
+++ b/Documentation/devicetree/bindings/gpio/renesas,gpio-rcar.txt
@@ -16,11 +16,13 @@ Required Properties:
- "renesas,rcar-gen1-gpio": for a generic R-Car Gen1 GPIO controller.
- "renesas,rcar-gen2-gpio": for a generic R-Car Gen2 or RZ/G1 GPIO controller.
- "renesas,rcar-gen3-gpio": for a generic R-Car Gen3 GPIO controller.
- - "renesas,gpio-rcar": deprecated.
+ - "renesas,gpio-rcar": for generic R-Car GPIO controller.
- When compatible with the generic version nodes must list the
- SoC-specific version corresponding to the platform first followed by
- the generic version.
+ Nodes should list all of the following that are compatible
+ in this order:
+ - A SoC-specific version
+ - A generic R-Car generation version
+ - The generic R-Car version
- reg: Base address and length of each memory resource used by the GPIO
controller hardware module.
@@ -50,7 +52,9 @@ interrupt-controller/interrupts.txt.
Example: R8A7779 (R-Car H1) GPIO controller nodes
gpio0: gpio@ffc40000 {
- compatible = "renesas,gpio-r8a7779", "renesas,rcar-gen1-gpio";
+ compatible = "renesas,gpio-r8a7779",
+ "renesas,rcar-gen1-gpio",
+ "renesas,gpio-rcar";
reg = <0xffc40000 0x2c>;
interrupt-parent = <&gic>;
interrupts = <0 141 0x4>;
@@ -62,7 +66,9 @@ Example: R8A7779 (R-Car H1) GPIO controller nodes
};
...
gpio6: gpio@ffc46000 {
- compatible = "renesas,gpio-r8a7779", "renesas,rcar-gen1-gpio";
+ compatible = "renesas,gpio-r8a7779",
+ "renesas,rcar-gen1-gpio",
+ "renesas,gpio-rcar";
reg = <0xffc46000 0x2c>;
interrupt-parent = <&gic>;
interrupts = <0 147 0x4>;
--
2.1.4
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] gpio: rcar: reinstate generic compat string
2017-08-09 8:21 [PATCH] gpio: rcar: reinstate generic compat string Simon Horman
@ 2017-08-10 8:06 ` Simon Horman
2017-08-14 12:59 ` Linus Walleij
2017-08-14 11:44 ` Geert Uytterhoeven
1 sibling, 1 reply; 4+ messages in thread
From: Simon Horman @ 2017-08-10 8:06 UTC (permalink / raw)
To: Geert Uytterhoeven
Cc: Linus Walleij, Magnus Damm, linux-gpio, linux-renesas-soc
On Wed, Aug 09, 2017 at 10:21:06AM +0200, Simon Horman wrote:
> commit d10bbd156926 ("gpio: rcar: add gen[123] fallback compatibility
> strings") deprecated the generic compat string, renesas,gpio-rcar. After
> further discussion this appears not to have been desirable as that compat
> string is compatible with all R-Car SoCs supported in upstream.
>
> This commit partially reverts that commit, and updates related
> documentation and examples.
>
> Fixes: d10bbd156926 ("gpio: rcar: add gen[123] fallback compatibility strings")
> Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
Hi Linus,
I believe Geert is on holidays at the moment (maybe you are to‽).
I'd like to wait for feedback from him on this as I feel that
its not at all urgent and it would be best to try to avoid further
churn in this area.
> ---
> .../devicetree/bindings/gpio/renesas,gpio-rcar.txt | 18 ++++++++++++------
> 1 file changed, 12 insertions(+), 6 deletions(-)
>
> diff --git a/Documentation/devicetree/bindings/gpio/renesas,gpio-rcar.txt b/Documentation/devicetree/bindings/gpio/renesas,gpio-rcar.txt
> index 48634b01f1bf..347d8ede2982 100644
> --- a/Documentation/devicetree/bindings/gpio/renesas,gpio-rcar.txt
> +++ b/Documentation/devicetree/bindings/gpio/renesas,gpio-rcar.txt
> @@ -16,11 +16,13 @@ Required Properties:
> - "renesas,rcar-gen1-gpio": for a generic R-Car Gen1 GPIO controller.
> - "renesas,rcar-gen2-gpio": for a generic R-Car Gen2 or RZ/G1 GPIO controller.
> - "renesas,rcar-gen3-gpio": for a generic R-Car Gen3 GPIO controller.
> - - "renesas,gpio-rcar": deprecated.
> + - "renesas,gpio-rcar": for generic R-Car GPIO controller.
>
> - When compatible with the generic version nodes must list the
> - SoC-specific version corresponding to the platform first followed by
> - the generic version.
> + Nodes should list all of the following that are compatible
> + in this order:
> + - A SoC-specific version
> + - A generic R-Car generation version
> + - The generic R-Car version
>
> - reg: Base address and length of each memory resource used by the GPIO
> controller hardware module.
> @@ -50,7 +52,9 @@ interrupt-controller/interrupts.txt.
> Example: R8A7779 (R-Car H1) GPIO controller nodes
>
> gpio0: gpio@ffc40000 {
> - compatible = "renesas,gpio-r8a7779", "renesas,rcar-gen1-gpio";
> + compatible = "renesas,gpio-r8a7779",
> + "renesas,rcar-gen1-gpio",
> + "renesas,gpio-rcar";
> reg = <0xffc40000 0x2c>;
> interrupt-parent = <&gic>;
> interrupts = <0 141 0x4>;
> @@ -62,7 +66,9 @@ Example: R8A7779 (R-Car H1) GPIO controller nodes
> };
> ...
> gpio6: gpio@ffc46000 {
> - compatible = "renesas,gpio-r8a7779", "renesas,rcar-gen1-gpio";
> + compatible = "renesas,gpio-r8a7779",
> + "renesas,rcar-gen1-gpio",
> + "renesas,gpio-rcar";
> reg = <0xffc46000 0x2c>;
> interrupt-parent = <&gic>;
> interrupts = <0 147 0x4>;
> --
> 2.1.4
>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] gpio: rcar: reinstate generic compat string
2017-08-09 8:21 [PATCH] gpio: rcar: reinstate generic compat string Simon Horman
2017-08-10 8:06 ` Simon Horman
@ 2017-08-14 11:44 ` Geert Uytterhoeven
1 sibling, 0 replies; 4+ messages in thread
From: Geert Uytterhoeven @ 2017-08-14 11:44 UTC (permalink / raw)
To: Simon Horman
Cc: Geert Uytterhoeven, Linus Walleij, Magnus Damm, linux-gpio,
Linux-Renesas
Hi Simon,
On Wed, Aug 9, 2017 at 10:21 AM, Simon Horman
<horms+renesas@verge.net.au> wrote:
> commit d10bbd156926 ("gpio: rcar: add gen[123] fallback compatibility
> strings") deprecated the generic compat string, renesas,gpio-rcar. After
> further discussion this appears not to have been desirable as that compat
> string is compatible with all R-Car SoCs supported in upstream.
While "renesas,gpio-rcar" is treated as a GPIO controller on R-Car Gen1 SoCs,
it can indeed be used on R-Car Gen2 and Gen3, with reduced functionality.
In se this is compatible with the spirit of multiple compatible values.
> This commit partially reverts that commit, and updates related
> documentation and examples.
>
> Fixes: d10bbd156926 ("gpio: rcar: add gen[123] fallback compatibility strings")
> Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
> ---
> .../devicetree/bindings/gpio/renesas,gpio-rcar.txt | 18 ++++++++++++------
> 1 file changed, 12 insertions(+), 6 deletions(-)
>
> diff --git a/Documentation/devicetree/bindings/gpio/renesas,gpio-rcar.txt b/Documentation/devicetree/bindings/gpio/renesas,gpio-rcar.txt
> index 48634b01f1bf..347d8ede2982 100644
> --- a/Documentation/devicetree/bindings/gpio/renesas,gpio-rcar.txt
> +++ b/Documentation/devicetree/bindings/gpio/renesas,gpio-rcar.txt
> @@ -16,11 +16,13 @@ Required Properties:
> - "renesas,rcar-gen1-gpio": for a generic R-Car Gen1 GPIO controller.
> - "renesas,rcar-gen2-gpio": for a generic R-Car Gen2 or RZ/G1 GPIO controller.
> - "renesas,rcar-gen3-gpio": for a generic R-Car Gen3 GPIO controller.
> - - "renesas,gpio-rcar": deprecated.
> + - "renesas,gpio-rcar": for generic R-Car GPIO controller.
>
> - When compatible with the generic version nodes must list the
> - SoC-specific version corresponding to the platform first followed by
> - the generic version.
> + Nodes should list all of the following that are compatible
> + in this order:
> + - A SoC-specific version
> + - A generic R-Car generation version
> + - The generic R-Car version
The main objective of commit d10bbd156926 ("gpio: rcar: add gen[123] fallback
compatibility strings") was avoiding the need to add more SoC-specific
compatible values to the match table in the driver, when adding driver
support for more R-Car and RZ/G SoCs.
With this amendment, this objective is met at the expense of adding a third
compatible value to each and every GPIO device node in R-Car .dtsi files :-(
IMHO keeping "renesas,gpio-rcar" everywhere adds little value. The only
exception might be running an old kernel on a new SoC, but that is ruled out
for a few core components like clocks and PFC anyway.
Of course the driver has to keep matching on the deprecated value, which is
already the case without this amendment.
> - reg: Base address and length of each memory resource used by the GPIO
> controller hardware module.
> @@ -50,7 +52,9 @@ interrupt-controller/interrupts.txt.
> Example: R8A7779 (R-Car H1) GPIO controller nodes
>
> gpio0: gpio@ffc40000 {
> - compatible = "renesas,gpio-r8a7779", "renesas,rcar-gen1-gpio";
> + compatible = "renesas,gpio-r8a7779",
> + "renesas,rcar-gen1-gpio",
> + "renesas,gpio-rcar";
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] gpio: rcar: reinstate generic compat string
2017-08-10 8:06 ` Simon Horman
@ 2017-08-14 12:59 ` Linus Walleij
0 siblings, 0 replies; 4+ messages in thread
From: Linus Walleij @ 2017-08-14 12:59 UTC (permalink / raw)
To: Simon Horman; +Cc: Geert Uytterhoeven, Magnus Damm, linux-gpio, Linux-Renesas
On Thu, Aug 10, 2017 at 10:06 AM, Simon Horman <horms@verge.net.au> wrote:
> On Wed, Aug 09, 2017 at 10:21:06AM +0200, Simon Horman wrote:
>> commit d10bbd156926 ("gpio: rcar: add gen[123] fallback compatibility
>> strings") deprecated the generic compat string, renesas,gpio-rcar. After
>> further discussion this appears not to have been desirable as that compat
>> string is compatible with all R-Car SoCs supported in upstream.
>>
>> This commit partially reverts that commit, and updates related
>> documentation and examples.
>>
>> Fixes: d10bbd156926 ("gpio: rcar: add gen[123] fallback compatibility strings")
>> Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
>
> Hi Linus,
>
> I believe Geert is on holidays at the moment (maybe you are to‽).
Nah neither of us are as it seems :)
I wait for the two of you to figure this out before applying anything.
Yours,
Linus Walleij
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2017-08-14 12:59 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-08-09 8:21 [PATCH] gpio: rcar: reinstate generic compat string Simon Horman
2017-08-10 8:06 ` Simon Horman
2017-08-14 12:59 ` Linus Walleij
2017-08-14 11:44 ` Geert Uytterhoeven
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.