linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] gpio: rcar: Remove redundant compatible values
@ 2020-12-31 15:31 Lad Prabhakar
  2021-01-04 10:36 ` Geert Uytterhoeven
  0 siblings, 1 reply; 3+ messages in thread
From: Lad Prabhakar @ 2020-12-31 15:31 UTC (permalink / raw)
  To: Linus Walleij, Bartosz Golaszewski, Geert Uytterhoeven
  Cc: linux-gpio, linux-kernel, linux-renesas-soc, Prabhakar, Lad Prabhakar

The mandatory compatible values 'renesas,rcar-gen{1,2,3}-gpio' have been
already added to all the respective R-Car Gen{1,2,3} SoC DTSI files,
remove the redundant device specific values from the driver.

Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
---
 drivers/gpio/gpio-rcar.c | 27 ---------------------------
 1 file changed, 27 deletions(-)

diff --git a/drivers/gpio/gpio-rcar.c b/drivers/gpio/gpio-rcar.c
index 0b572dbc4a36..f3b8c4b44cab 100644
--- a/drivers/gpio/gpio-rcar.c
+++ b/drivers/gpio/gpio-rcar.c
@@ -392,33 +392,6 @@ static const struct gpio_rcar_info gpio_rcar_info_gen2 = {
 
 static const struct of_device_id gpio_rcar_of_table[] = {
 	{
-		.compatible = "renesas,gpio-r8a7743",
-		/* RZ/G1 GPIO is identical to R-Car Gen2. */
-		.data = &gpio_rcar_info_gen2,
-	}, {
-		.compatible = "renesas,gpio-r8a7790",
-		.data = &gpio_rcar_info_gen2,
-	}, {
-		.compatible = "renesas,gpio-r8a7791",
-		.data = &gpio_rcar_info_gen2,
-	}, {
-		.compatible = "renesas,gpio-r8a7792",
-		.data = &gpio_rcar_info_gen2,
-	}, {
-		.compatible = "renesas,gpio-r8a7793",
-		.data = &gpio_rcar_info_gen2,
-	}, {
-		.compatible = "renesas,gpio-r8a7794",
-		.data = &gpio_rcar_info_gen2,
-	}, {
-		.compatible = "renesas,gpio-r8a7795",
-		/* Gen3 GPIO is identical to Gen2. */
-		.data = &gpio_rcar_info_gen2,
-	}, {
-		.compatible = "renesas,gpio-r8a7796",
-		/* Gen3 GPIO is identical to Gen2. */
-		.data = &gpio_rcar_info_gen2,
-	}, {
 		.compatible = "renesas,rcar-gen1-gpio",
 		.data = &gpio_rcar_info_gen1,
 	}, {
-- 
2.17.1


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

* Re: [PATCH] gpio: rcar: Remove redundant compatible values
  2020-12-31 15:31 [PATCH] gpio: rcar: Remove redundant compatible values Lad Prabhakar
@ 2021-01-04 10:36 ` Geert Uytterhoeven
  2021-01-04 11:20   ` Bartosz Golaszewski
  0 siblings, 1 reply; 3+ messages in thread
From: Geert Uytterhoeven @ 2021-01-04 10:36 UTC (permalink / raw)
  To: Lad Prabhakar
  Cc: Linus Walleij, Bartosz Golaszewski, open list:GPIO SUBSYSTEM,
	Linux Kernel Mailing List, Linux-Renesas, Prabhakar

Hi Prabhakar,

On Thu, Dec 31, 2020 at 4:31 PM Lad Prabhakar
<prabhakar.mahadev-lad.rj@bp.renesas.com> wrote:
> The mandatory compatible values 'renesas,rcar-gen{1,2,3}-gpio' have been
> already added to all the respective R-Car Gen{1,2,3} SoC DTSI files,
> remove the redundant device specific values from the driver.
>
> Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>

Thanks for your patch!

> --- a/drivers/gpio/gpio-rcar.c
> +++ b/drivers/gpio/gpio-rcar.c
> @@ -392,33 +392,6 @@ static const struct gpio_rcar_info gpio_rcar_info_gen2 = {
>
>  static const struct of_device_id gpio_rcar_of_table[] = {
>         {
> -               .compatible = "renesas,gpio-r8a7743",
> -               /* RZ/G1 GPIO is identical to R-Car Gen2. */
> -               .data = &gpio_rcar_info_gen2,
> -       }, {
> -               .compatible = "renesas,gpio-r8a7790",
> -               .data = &gpio_rcar_info_gen2,
> -       }, {
> -               .compatible = "renesas,gpio-r8a7791",
> -               .data = &gpio_rcar_info_gen2,
> -       }, {
> -               .compatible = "renesas,gpio-r8a7792",
> -               .data = &gpio_rcar_info_gen2,
> -       }, {
> -               .compatible = "renesas,gpio-r8a7793",
> -               .data = &gpio_rcar_info_gen2,
> -       }, {
> -               .compatible = "renesas,gpio-r8a7794",
> -               .data = &gpio_rcar_info_gen2,
> -       }, {
> -               .compatible = "renesas,gpio-r8a7795",
> -               /* Gen3 GPIO is identical to Gen2. */
> -               .data = &gpio_rcar_info_gen2,
> -       }, {
> -               .compatible = "renesas,gpio-r8a7796",
> -               /* Gen3 GPIO is identical to Gen2. */
> -               .data = &gpio_rcar_info_gen2,
> -       }, {
>                 .compatible = "renesas,rcar-gen1-gpio",
>                 .data = &gpio_rcar_info_gen1,
>         }, {

The reason the driver matches on these SoC-specific compatible values is
that originally the family-specific compatible values did not exist, and
the device nodes in the initial DTS files thus did not use them.  The
family-specific compatible values were added to the DTS files in v4.15.
However, as this was backported to all v4.14-based R-Car BSP releases
(3.6.0 and later), I think it is safe to apply this.

Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>

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] 3+ messages in thread

* Re: [PATCH] gpio: rcar: Remove redundant compatible values
  2021-01-04 10:36 ` Geert Uytterhoeven
@ 2021-01-04 11:20   ` Bartosz Golaszewski
  0 siblings, 0 replies; 3+ messages in thread
From: Bartosz Golaszewski @ 2021-01-04 11:20 UTC (permalink / raw)
  To: Geert Uytterhoeven
  Cc: Lad Prabhakar, Linus Walleij, open list:GPIO SUBSYSTEM,
	Linux Kernel Mailing List, Linux-Renesas, Prabhakar

On Mon, Jan 4, 2021 at 11:36 AM Geert Uytterhoeven <geert@linux-m68k.org> wrote:
>
> Hi Prabhakar,
>
> On Thu, Dec 31, 2020 at 4:31 PM Lad Prabhakar
> <prabhakar.mahadev-lad.rj@bp.renesas.com> wrote:
> > The mandatory compatible values 'renesas,rcar-gen{1,2,3}-gpio' have been
> > already added to all the respective R-Car Gen{1,2,3} SoC DTSI files,
> > remove the redundant device specific values from the driver.
> >
> > Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
>
> Thanks for your patch!
>
> > --- a/drivers/gpio/gpio-rcar.c
> > +++ b/drivers/gpio/gpio-rcar.c
> > @@ -392,33 +392,6 @@ static const struct gpio_rcar_info gpio_rcar_info_gen2 = {
> >
> >  static const struct of_device_id gpio_rcar_of_table[] = {
> >         {
> > -               .compatible = "renesas,gpio-r8a7743",
> > -               /* RZ/G1 GPIO is identical to R-Car Gen2. */
> > -               .data = &gpio_rcar_info_gen2,
> > -       }, {
> > -               .compatible = "renesas,gpio-r8a7790",
> > -               .data = &gpio_rcar_info_gen2,
> > -       }, {
> > -               .compatible = "renesas,gpio-r8a7791",
> > -               .data = &gpio_rcar_info_gen2,
> > -       }, {
> > -               .compatible = "renesas,gpio-r8a7792",
> > -               .data = &gpio_rcar_info_gen2,
> > -       }, {
> > -               .compatible = "renesas,gpio-r8a7793",
> > -               .data = &gpio_rcar_info_gen2,
> > -       }, {
> > -               .compatible = "renesas,gpio-r8a7794",
> > -               .data = &gpio_rcar_info_gen2,
> > -       }, {
> > -               .compatible = "renesas,gpio-r8a7795",
> > -               /* Gen3 GPIO is identical to Gen2. */
> > -               .data = &gpio_rcar_info_gen2,
> > -       }, {
> > -               .compatible = "renesas,gpio-r8a7796",
> > -               /* Gen3 GPIO is identical to Gen2. */
> > -               .data = &gpio_rcar_info_gen2,
> > -       }, {
> >                 .compatible = "renesas,rcar-gen1-gpio",
> >                 .data = &gpio_rcar_info_gen1,
> >         }, {
>
> The reason the driver matches on these SoC-specific compatible values is
> that originally the family-specific compatible values did not exist, and
> the device nodes in the initial DTS files thus did not use them.  The
> family-specific compatible values were added to the DTS files in v4.15.
> However, as this was backported to all v4.14-based R-Car BSP releases
> (3.6.0 and later), I think it is safe to apply this.
>
> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
>
> 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

Patch applied, thanks!

Bartosz

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

end of thread, other threads:[~2021-01-04 11:20 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-12-31 15:31 [PATCH] gpio: rcar: Remove redundant compatible values Lad Prabhakar
2021-01-04 10:36 ` Geert Uytterhoeven
2021-01-04 11:20   ` 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).