linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/3] iWave G21D-Q7 enable flash, CAN and SD2 LED
@ 2020-09-07 15:55 Lad Prabhakar
  2020-09-07 15:55 ` [PATCH v2 1/3] ARM: dts: r8a7742-iwg21d-q7: Add SPI NOR support Lad Prabhakar
                   ` (2 more replies)
  0 siblings, 3 replies; 10+ messages in thread
From: Lad Prabhakar @ 2020-09-07 15:55 UTC (permalink / raw)
  To: Geert Uytterhoeven, Magnus Damm, Rob Herring, linux-renesas-soc,
	devicetree
  Cc: linux-kernel, Lad Prabhakar, Biju Das, Prabhakar

Hi All,

This patch series enables PCIe, SPI NOR flash, CAN0 and SD2 LED indication
on iWave G21D-Q7 board.

Patches apply on top of [1] and also dependent on patch [2]
[1] https://git.kernel.org/pub/scm/linux/kernel/git/geert/
    renesas-devel.git/log/?h=renesas-arm-dt-for-v5.10
[2] https://patchwork.kernel.org/patch/11712541/

Cheers,
Prabhakar

v1->v2
* Set SD2 LED trigger GPIO as GPIO_ACTIVE_HIGH
* Added missing "msiof0_sync" in msiof0 pins
* Corrected to can1 interface on carrier board

Lad Prabhakar (3):
  ARM: dts: r8a7742-iwg21d-q7: Add SPI NOR support
  ARM: dts: r8a7742-iwg21d-q7: Add can1 support to carrier board
  ARM: dts: r8a7742-iwg21d-q7: Enable SD2 LED indication

 arch/arm/boot/dts/r8a7742-iwg21d-q7.dts | 62 +++++++++++++++++++++++++
 1 file changed, 62 insertions(+)

-- 
2.17.1


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

* [PATCH v2 1/3] ARM: dts: r8a7742-iwg21d-q7: Add SPI NOR support
  2020-09-07 15:55 [PATCH v2 0/3] iWave G21D-Q7 enable flash, CAN and SD2 LED Lad Prabhakar
@ 2020-09-07 15:55 ` Lad Prabhakar
  2020-09-10  9:03   ` Geert Uytterhoeven
  2020-09-07 15:55 ` [PATCH v2 2/3] ARM: dts: r8a7742-iwg21d-q7: Add can1 support to carrier board Lad Prabhakar
  2020-09-07 15:55 ` [PATCH v2 3/3] ARM: dts: r8a7742-iwg21d-q7: Enable SD2 LED indication Lad Prabhakar
  2 siblings, 1 reply; 10+ messages in thread
From: Lad Prabhakar @ 2020-09-07 15:55 UTC (permalink / raw)
  To: Geert Uytterhoeven, Magnus Damm, Rob Herring, linux-renesas-soc,
	devicetree
  Cc: linux-kernel, Lad Prabhakar, Biju Das, Prabhakar

Add support for the SPI NOR device which is connected to MSIOF0 interface
on the iWave RainboW-G21d-q7 board.

Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
Reviewed-by: Chris Paterson <Chris.Paterson2@renesas.com>
Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
---
 arch/arm/boot/dts/r8a7742-iwg21d-q7.dts | 31 +++++++++++++++++++++++++
 1 file changed, 31 insertions(+)

diff --git a/arch/arm/boot/dts/r8a7742-iwg21d-q7.dts b/arch/arm/boot/dts/r8a7742-iwg21d-q7.dts
index 73300ab46ea6..818f1a850c62 100644
--- a/arch/arm/boot/dts/r8a7742-iwg21d-q7.dts
+++ b/arch/arm/boot/dts/r8a7742-iwg21d-q7.dts
@@ -220,6 +220,32 @@
 	status = "okay";
 };
 
+&msiof0 {
+	pinctrl-0 = <&msiof0_pins>;
+	pinctrl-names = "default";
+	cs-gpios = <&gpio5 13 GPIO_ACTIVE_LOW>;
+
+	status = "okay";
+
+	flash1: flash@0 {
+		compatible = "sst,sst25vf016b", "jedec,spi-nor";
+		reg = <0>;
+		spi-max-frequency = <50000000>;
+		m25p,fast-read;
+
+		partitions {
+			compatible = "fixed-partitions";
+			#address-cells = <1>;
+			#size-cells = <1>;
+
+			partition@0 {
+				label = "user";
+				reg = <0x00000000 0x00200000>;
+			};
+		};
+	};
+};
+
 &pci0 {
 	pinctrl-0 = <&usb0_pins>;
 	pinctrl-names = "default";
@@ -266,6 +292,11 @@
 		function = "i2c2";
 	};
 
+	msiof0_pins: msiof0 {
+		groups = "msiof0_clk", "msiof0_sync", "msiof0_tx", "msiof0_rx";
+		function = "msiof0";
+	};
+
 	scifa2_pins: scifa2 {
 		groups = "scifa2_data_c";
 		function = "scifa2";
-- 
2.17.1


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

* [PATCH v2 2/3] ARM: dts: r8a7742-iwg21d-q7: Add can1 support to carrier board
  2020-09-07 15:55 [PATCH v2 0/3] iWave G21D-Q7 enable flash, CAN and SD2 LED Lad Prabhakar
  2020-09-07 15:55 ` [PATCH v2 1/3] ARM: dts: r8a7742-iwg21d-q7: Add SPI NOR support Lad Prabhakar
@ 2020-09-07 15:55 ` Lad Prabhakar
  2020-09-10  9:04   ` Geert Uytterhoeven
  2020-09-07 15:55 ` [PATCH v2 3/3] ARM: dts: r8a7742-iwg21d-q7: Enable SD2 LED indication Lad Prabhakar
  2 siblings, 1 reply; 10+ messages in thread
From: Lad Prabhakar @ 2020-09-07 15:55 UTC (permalink / raw)
  To: Geert Uytterhoeven, Magnus Damm, Rob Herring, linux-renesas-soc,
	devicetree
  Cc: linux-kernel, Lad Prabhakar, Biju Das, Prabhakar

This patch enables CAN1 interface exposed through connector J20 on the
carrier board.

Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
Reviewed-by: Chris Paterson <Chris.Paterson2@renesas.com>
---
 arch/arm/boot/dts/r8a7742-iwg21d-q7.dts | 21 +++++++++++++++++++++
 1 file changed, 21 insertions(+)

diff --git a/arch/arm/boot/dts/r8a7742-iwg21d-q7.dts b/arch/arm/boot/dts/r8a7742-iwg21d-q7.dts
index 818f1a850c62..66881a473d6c 100644
--- a/arch/arm/boot/dts/r8a7742-iwg21d-q7.dts
+++ b/arch/arm/boot/dts/r8a7742-iwg21d-q7.dts
@@ -198,6 +198,13 @@
 	};
 };
 
+&can1 {
+	pinctrl-0 = <&can1_pins>;
+	pinctrl-names = "default";
+
+	status = "okay";
+};
+
 &cmt0 {
 	status = "okay";
 };
@@ -214,6 +221,15 @@
 	};
 };
 
+&gpio1 {
+	can-trx-en-gpio{
+		gpio-hog;
+		gpios = <28 GPIO_ACTIVE_HIGH>;
+		output-low;
+		line-name = "can-trx-en-gpio";
+	};
+};
+
 &hsusb {
 	pinctrl-0 = <&usb0_pins>;
 	pinctrl-names = "default";
@@ -287,6 +303,11 @@
 		function = "tpu0";
 	};
 
+	can1_pins: can1 {
+		groups = "can1_data_b";
+		function = "can1";
+	};
+
 	i2c2_pins: i2c2 {
 		groups = "i2c2_b";
 		function = "i2c2";
-- 
2.17.1


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

* [PATCH v2 3/3] ARM: dts: r8a7742-iwg21d-q7: Enable SD2 LED indication
  2020-09-07 15:55 [PATCH v2 0/3] iWave G21D-Q7 enable flash, CAN and SD2 LED Lad Prabhakar
  2020-09-07 15:55 ` [PATCH v2 1/3] ARM: dts: r8a7742-iwg21d-q7: Add SPI NOR support Lad Prabhakar
  2020-09-07 15:55 ` [PATCH v2 2/3] ARM: dts: r8a7742-iwg21d-q7: Add can1 support to carrier board Lad Prabhakar
@ 2020-09-07 15:55 ` Lad Prabhakar
  2020-09-10  9:05   ` Geert Uytterhoeven
  2020-10-09  7:33   ` Pavel Machek
  2 siblings, 2 replies; 10+ messages in thread
From: Lad Prabhakar @ 2020-09-07 15:55 UTC (permalink / raw)
  To: Geert Uytterhoeven, Magnus Damm, Rob Herring, linux-renesas-soc,
	devicetree
  Cc: linux-kernel, Lad Prabhakar, Biju Das, Prabhakar

Add support for LED trigger on SD2 interface.

Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
Reviewed-by: Chris Paterson <Chris.Paterson2@renesas.com>
Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
---
 arch/arm/boot/dts/r8a7742-iwg21d-q7.dts | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/arch/arm/boot/dts/r8a7742-iwg21d-q7.dts b/arch/arm/boot/dts/r8a7742-iwg21d-q7.dts
index 66881a473d6c..e45b502d61cb 100644
--- a/arch/arm/boot/dts/r8a7742-iwg21d-q7.dts
+++ b/arch/arm/boot/dts/r8a7742-iwg21d-q7.dts
@@ -63,6 +63,16 @@
 		enable-gpios = <&gpio3 11 GPIO_ACTIVE_HIGH>;
 	};
 
+	leds {
+		compatible = "gpio-leds";
+
+		sdhi2_led {
+			label = "sdio-led";
+			gpios = <&gpio5 22 GPIO_ACTIVE_HIGH>;
+			linux,default-trigger = "mmc1";
+		};
+	};
+
 	lvds-receiver {
 		compatible = "ti,ds90cf384a", "lvds-decoder";
 		vcc-supply = <&vcc_3v3_tft1>;
-- 
2.17.1


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

* Re: [PATCH v2 1/3] ARM: dts: r8a7742-iwg21d-q7: Add SPI NOR support
  2020-09-07 15:55 ` [PATCH v2 1/3] ARM: dts: r8a7742-iwg21d-q7: Add SPI NOR support Lad Prabhakar
@ 2020-09-10  9:03   ` Geert Uytterhoeven
  0 siblings, 0 replies; 10+ messages in thread
From: Geert Uytterhoeven @ 2020-09-10  9:03 UTC (permalink / raw)
  To: Lad Prabhakar
  Cc: Magnus Damm, Rob Herring, Linux-Renesas,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	Linux Kernel Mailing List, Biju Das, Prabhakar

On Mon, Sep 7, 2020 at 5:56 PM Lad Prabhakar
<prabhakar.mahadev-lad.rj@bp.renesas.com> wrote:
> Add support for the SPI NOR device which is connected to MSIOF0 interface
> on the iWave RainboW-G21d-q7 board.
>
> Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
> Reviewed-by: Chris Paterson <Chris.Paterson2@renesas.com>
> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>

Thanks for the update, will queue in renesas-devel for v5.10.

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

* Re: [PATCH v2 2/3] ARM: dts: r8a7742-iwg21d-q7: Add can1 support to carrier board
  2020-09-07 15:55 ` [PATCH v2 2/3] ARM: dts: r8a7742-iwg21d-q7: Add can1 support to carrier board Lad Prabhakar
@ 2020-09-10  9:04   ` Geert Uytterhoeven
  0 siblings, 0 replies; 10+ messages in thread
From: Geert Uytterhoeven @ 2020-09-10  9:04 UTC (permalink / raw)
  To: Lad Prabhakar
  Cc: Magnus Damm, Rob Herring, Linux-Renesas,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	Linux Kernel Mailing List, Biju Das, Prabhakar

On Mon, Sep 7, 2020 at 5:56 PM Lad Prabhakar
<prabhakar.mahadev-lad.rj@bp.renesas.com> wrote:
> This patch enables CAN1 interface exposed through connector J20 on the
> carrier board.
>
> Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
> Reviewed-by: Chris Paterson <Chris.Paterson2@renesas.com>

Thanks for the update, will queue in renesas-devel for v5.10.

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

* Re: [PATCH v2 3/3] ARM: dts: r8a7742-iwg21d-q7: Enable SD2 LED indication
  2020-09-07 15:55 ` [PATCH v2 3/3] ARM: dts: r8a7742-iwg21d-q7: Enable SD2 LED indication Lad Prabhakar
@ 2020-09-10  9:05   ` Geert Uytterhoeven
  2020-10-09  7:33   ` Pavel Machek
  1 sibling, 0 replies; 10+ messages in thread
From: Geert Uytterhoeven @ 2020-09-10  9:05 UTC (permalink / raw)
  To: Lad Prabhakar
  Cc: Magnus Damm, Rob Herring, Linux-Renesas,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	Linux Kernel Mailing List, Biju Das, Prabhakar

On Mon, Sep 7, 2020 at 5:56 PM Lad Prabhakar
<prabhakar.mahadev-lad.rj@bp.renesas.com> wrote:
> Add support for LED trigger on SD2 interface.
>
> Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
> Reviewed-by: Chris Paterson <Chris.Paterson2@renesas.com>
> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>

Thanks for the update, will queue in renesas-devel for v5.10.

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

* Re: [PATCH v2 3/3] ARM: dts: r8a7742-iwg21d-q7: Enable SD2 LED indication
  2020-09-07 15:55 ` [PATCH v2 3/3] ARM: dts: r8a7742-iwg21d-q7: Enable SD2 LED indication Lad Prabhakar
  2020-09-10  9:05   ` Geert Uytterhoeven
@ 2020-10-09  7:33   ` Pavel Machek
  2020-10-09  8:41     ` Lad, Prabhakar
  1 sibling, 1 reply; 10+ messages in thread
From: Pavel Machek @ 2020-10-09  7:33 UTC (permalink / raw)
  To: Lad Prabhakar
  Cc: Geert Uytterhoeven, Magnus Damm, Rob Herring, linux-renesas-soc,
	devicetree, linux-kernel, Biju Das, Prabhakar

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

Hi!

> +++ b/arch/arm/boot/dts/r8a7742-iwg21d-q7.dts
> @@ -63,6 +63,16 @@
>  		enable-gpios = <&gpio3 11 GPIO_ACTIVE_HIGH>;
>  	};
>  
> +	leds {
> +		compatible = "gpio-leds";
> +
> +		sdhi2_led {
> +			label = "sdio-led";

This should use appropriate label... probably mmc1:green:activity.

Best regards,
									Pavel
-- 
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 181 bytes --]

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

* Re: [PATCH v2 3/3] ARM: dts: r8a7742-iwg21d-q7: Enable SD2 LED indication
  2020-10-09  7:33   ` Pavel Machek
@ 2020-10-09  8:41     ` Lad, Prabhakar
  2020-10-09 17:36       ` Pavel Machek
  0 siblings, 1 reply; 10+ messages in thread
From: Lad, Prabhakar @ 2020-10-09  8:41 UTC (permalink / raw)
  To: Pavel Machek
  Cc: Lad Prabhakar, Geert Uytterhoeven, Magnus Damm, Rob Herring,
	Linux-Renesas,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS, LKML,
	Biju Das

Hi Pavel,

Thank you for the review.

On Fri, Oct 9, 2020 at 8:33 AM Pavel Machek <pavel@denx.de> wrote:
>
> Hi!
>
> > +++ b/arch/arm/boot/dts/r8a7742-iwg21d-q7.dts
> > @@ -63,6 +63,16 @@
> >               enable-gpios = <&gpio3 11 GPIO_ACTIVE_HIGH>;
> >       };
> >
> > +     leds {
> > +             compatible = "gpio-leds";
> > +
> > +             sdhi2_led {
> > +                     label = "sdio-led";
>
> This should use appropriate label... probably mmc1:green:activity.
>
$ grep -nr mmc | grep -i activity
$ grep -nr  sd | grep -i activity

Results in 0 outputs in dts folder.

Cheers,
Prabhakar

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

* Re: [PATCH v2 3/3] ARM: dts: r8a7742-iwg21d-q7: Enable SD2 LED indication
  2020-10-09  8:41     ` Lad, Prabhakar
@ 2020-10-09 17:36       ` Pavel Machek
  0 siblings, 0 replies; 10+ messages in thread
From: Pavel Machek @ 2020-10-09 17:36 UTC (permalink / raw)
  To: Lad, Prabhakar, linux-leds, dmurphy
  Cc: Lad Prabhakar, Geert Uytterhoeven, Magnus Damm, Rob Herring,
	Linux-Renesas,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS, LKML,
	Biju Das

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

Hi!

> Thank you for the review.

Note I'm LED maintainer.

> > > +     leds {
> > > +             compatible = "gpio-leds";
> > > +
> > > +             sdhi2_led {
> > > +                     label = "sdio-led";
> >
> > This should use appropriate label... probably mmc1:green:activity.
> >
> $ grep -nr mmc | grep -i activity
> $ grep -nr  sd | grep -i activity
> 
> Results in 0 outputs in dts folder.

Well, so does

grep -ri label.*sdio-led arch/arm*

:-). Feel free to suggest other name following documentation in
Documentation/leds/leds-class.rst .

(And yes, we have lot of work to get this to some kind of consistent
state).

								Pavel
-- 
DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany

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

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

end of thread, other threads:[~2020-10-09 17:37 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-07 15:55 [PATCH v2 0/3] iWave G21D-Q7 enable flash, CAN and SD2 LED Lad Prabhakar
2020-09-07 15:55 ` [PATCH v2 1/3] ARM: dts: r8a7742-iwg21d-q7: Add SPI NOR support Lad Prabhakar
2020-09-10  9:03   ` Geert Uytterhoeven
2020-09-07 15:55 ` [PATCH v2 2/3] ARM: dts: r8a7742-iwg21d-q7: Add can1 support to carrier board Lad Prabhakar
2020-09-10  9:04   ` Geert Uytterhoeven
2020-09-07 15:55 ` [PATCH v2 3/3] ARM: dts: r8a7742-iwg21d-q7: Enable SD2 LED indication Lad Prabhakar
2020-09-10  9:05   ` Geert Uytterhoeven
2020-10-09  7:33   ` Pavel Machek
2020-10-09  8:41     ` Lad, Prabhakar
2020-10-09 17:36       ` Pavel Machek

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