devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/2] ARM: dts: renesas: r9a06g032-rzn1d400: enable USB host
@ 2025-05-08  7:43 Wolfram Sang
  2025-05-08  7:43 ` [PATCH v2 1/2] ARM: dts: renesas: r9a06g032-rzn1d400-db: add pinmux for the CPLD Wolfram Sang
  2025-05-08  7:43 ` [PATCH v2 2/2] ARM: dts: renesas: r9a06g032-rzn1d400-eb: enable USB host port Wolfram Sang
  0 siblings, 2 replies; 5+ messages in thread
From: Wolfram Sang @ 2025-05-08  7:43 UTC (permalink / raw)
  To: linux-renesas-soc
  Cc: Wolfram Sang, Conor Dooley, devicetree, Geert Uytterhoeven,
	Krzysztof Kozlowski, Magnus Damm, Rob Herring

After the previous discussion, here is my second take how to enable the
USB host port on the above board. Please let me know what you think.

Still works with the Rockbox player.

Changes since v1:
 * rebased to linux-next (USB device patch already accepted)
 * moved pinmux to a separate node for CPLD on the demo board

Wolfram Sang (2):
  ARM: dts: renesas: r9a06g032-rzn1d400-db: add pinmux for the CPLD
  ARM: dts: renesas: r9a06g032-rzn1d400-eb: enable USB host port

 arch/arm/boot/dts/renesas/r9a06g032-rzn1d400-db.dts | 10 ++++++++++
 arch/arm/boot/dts/renesas/r9a06g032-rzn1d400-eb.dts |  4 ++++
 2 files changed, 14 insertions(+)

-- 
2.47.2


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

* [PATCH v2 1/2] ARM: dts: renesas: r9a06g032-rzn1d400-db: add pinmux for the CPLD
  2025-05-08  7:43 [PATCH v2 0/2] ARM: dts: renesas: r9a06g032-rzn1d400: enable USB host Wolfram Sang
@ 2025-05-08  7:43 ` Wolfram Sang
  2025-05-08 17:49   ` Geert Uytterhoeven
  2025-05-08  7:43 ` [PATCH v2 2/2] ARM: dts: renesas: r9a06g032-rzn1d400-eb: enable USB host port Wolfram Sang
  1 sibling, 1 reply; 5+ messages in thread
From: Wolfram Sang @ 2025-05-08  7:43 UTC (permalink / raw)
  To: linux-renesas-soc
  Cc: Wolfram Sang, Geert Uytterhoeven, Magnus Damm, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, devicetree

The CPLD has no dedicated driver, so apply the pinmux settings with the
pinmux driver instead.

Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
---
 arch/arm/boot/dts/renesas/r9a06g032-rzn1d400-db.dts | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/arch/arm/boot/dts/renesas/r9a06g032-rzn1d400-db.dts b/arch/arm/boot/dts/renesas/r9a06g032-rzn1d400-db.dts
index 328cb35547d7..92b390f7f0e7 100644
--- a/arch/arm/boot/dts/renesas/r9a06g032-rzn1d400-db.dts
+++ b/arch/arm/boot/dts/renesas/r9a06g032-rzn1d400-db.dts
@@ -170,6 +170,9 @@ &mii_conv5 {
 };
 
 &pinctrl {
+	pinctrl-names = "default";
+	pinctrl-0 = <&pins_cpld>;
+
 	pins_can0: pins_can0 {
 		pinmux = <RZN1_PINMUX(162, RZN1_FUNC_CAN)>,	/* CAN0_TXD */
 			 <RZN1_PINMUX(163, RZN1_FUNC_CAN)>;	/* CAN0_RXD */
@@ -226,6 +229,13 @@ pins_mdio1: pins_mdio1 {
 		pinmux = <RZN1_PINMUX(152, RZN1_FUNC_MDIO1_SWITCH)>,
 			 <RZN1_PINMUX(153, RZN1_FUNC_MDIO1_SWITCH)>;
 	};
+
+	pins_cpld: pins-cpld {
+		pinmux = <RZN1_PINMUX(119, RZN1_FUNC_USB)>,
+			 <RZN1_PINMUX(120, RZN1_FUNC_USB)>,
+			 <RZN1_PINMUX(121, RZN1_FUNC_USB)>,
+			 <RZN1_PINMUX(122, RZN1_FUNC_USB)>;
+	};
 };
 
 &rtc0 {
-- 
2.47.2


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

* [PATCH v2 2/2] ARM: dts: renesas: r9a06g032-rzn1d400-eb: enable USB host port
  2025-05-08  7:43 [PATCH v2 0/2] ARM: dts: renesas: r9a06g032-rzn1d400: enable USB host Wolfram Sang
  2025-05-08  7:43 ` [PATCH v2 1/2] ARM: dts: renesas: r9a06g032-rzn1d400-db: add pinmux for the CPLD Wolfram Sang
@ 2025-05-08  7:43 ` Wolfram Sang
  2025-05-08 17:50   ` Geert Uytterhoeven
  1 sibling, 1 reply; 5+ messages in thread
From: Wolfram Sang @ 2025-05-08  7:43 UTC (permalink / raw)
  To: linux-renesas-soc
  Cc: Wolfram Sang, Geert Uytterhoeven, Magnus Damm, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, devicetree

Can be used via the USB connector J20.

Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
---
 arch/arm/boot/dts/renesas/r9a06g032-rzn1d400-eb.dts | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/arch/arm/boot/dts/renesas/r9a06g032-rzn1d400-eb.dts b/arch/arm/boot/dts/renesas/r9a06g032-rzn1d400-eb.dts
index b3de325fb47f..fb74dc45bd25 100644
--- a/arch/arm/boot/dts/renesas/r9a06g032-rzn1d400-eb.dts
+++ b/arch/arm/boot/dts/renesas/r9a06g032-rzn1d400-eb.dts
@@ -238,3 +238,7 @@ &uart2 {
 	status = "okay";
 	uart-has-rtscts;
 };
+
+&pci_usb {
+	status = "okay";
+};
-- 
2.47.2


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

* Re: [PATCH v2 1/2] ARM: dts: renesas: r9a06g032-rzn1d400-db: add pinmux for the CPLD
  2025-05-08  7:43 ` [PATCH v2 1/2] ARM: dts: renesas: r9a06g032-rzn1d400-db: add pinmux for the CPLD Wolfram Sang
@ 2025-05-08 17:49   ` Geert Uytterhoeven
  0 siblings, 0 replies; 5+ messages in thread
From: Geert Uytterhoeven @ 2025-05-08 17:49 UTC (permalink / raw)
  To: Wolfram Sang
  Cc: linux-renesas-soc, Magnus Damm, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, devicetree

On Thu, 8 May 2025 at 09:43, Wolfram Sang
<wsa+renesas@sang-engineering.com> wrote:
> The CPLD has no dedicated driver, so apply the pinmux settings with the
> pinmux driver instead.
>
> Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>

Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
i.e. will queue in renesas-devel for v6.16...

> --- a/arch/arm/boot/dts/renesas/r9a06g032-rzn1d400-db.dts
> +++ b/arch/arm/boot/dts/renesas/r9a06g032-rzn1d400-db.dts
> @@ -170,6 +170,9 @@ &mii_conv5 {
>  };
>
>  &pinctrl {
> +       pinctrl-names = "default";
> +       pinctrl-0 = <&pins_cpld>;
> +
>         pins_can0: pins_can0 {
>                 pinmux = <RZN1_PINMUX(162, RZN1_FUNC_CAN)>,     /* CAN0_TXD */
>                          <RZN1_PINMUX(163, RZN1_FUNC_CAN)>;     /* CAN0_RXD */
> @@ -226,6 +229,13 @@ pins_mdio1: pins_mdio1 {
>                 pinmux = <RZN1_PINMUX(152, RZN1_FUNC_MDIO1_SWITCH)>,
>                          <RZN1_PINMUX(153, RZN1_FUNC_MDIO1_SWITCH)>;
>         };
> +
> +       pins_cpld: pins-cpld {

... with this node moved up, to preserve sort order.

> +               pinmux = <RZN1_PINMUX(119, RZN1_FUNC_USB)>,
> +                        <RZN1_PINMUX(120, RZN1_FUNC_USB)>,
> +                        <RZN1_PINMUX(121, RZN1_FUNC_USB)>,
> +                        <RZN1_PINMUX(122, RZN1_FUNC_USB)>;
> +       };
>  };
>
>  &rtc0 {

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

* Re: [PATCH v2 2/2] ARM: dts: renesas: r9a06g032-rzn1d400-eb: enable USB host port
  2025-05-08  7:43 ` [PATCH v2 2/2] ARM: dts: renesas: r9a06g032-rzn1d400-eb: enable USB host port Wolfram Sang
@ 2025-05-08 17:50   ` Geert Uytterhoeven
  0 siblings, 0 replies; 5+ messages in thread
From: Geert Uytterhoeven @ 2025-05-08 17:50 UTC (permalink / raw)
  To: Wolfram Sang
  Cc: linux-renesas-soc, Magnus Damm, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, devicetree

On Thu, 8 May 2025 at 09:43, Wolfram Sang
<wsa+renesas@sang-engineering.com> wrote:
> Can be used via the USB connector J20.
>
> Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>

Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
i.e. will queue in renesas-devel for v6.16.

> --- a/arch/arm/boot/dts/renesas/r9a06g032-rzn1d400-eb.dts
> +++ b/arch/arm/boot/dts/renesas/r9a06g032-rzn1d400-eb.dts
> @@ -238,3 +238,7 @@ &uart2 {
>         status = "okay";
>         uart-has-rtscts;
>  };
> +
> +&pci_usb {

... with this node moved up, to preserve sort order.

> +       status = "okay";
> +};

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

end of thread, other threads:[~2025-05-08 17:51 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-05-08  7:43 [PATCH v2 0/2] ARM: dts: renesas: r9a06g032-rzn1d400: enable USB host Wolfram Sang
2025-05-08  7:43 ` [PATCH v2 1/2] ARM: dts: renesas: r9a06g032-rzn1d400-db: add pinmux for the CPLD Wolfram Sang
2025-05-08 17:49   ` Geert Uytterhoeven
2025-05-08  7:43 ` [PATCH v2 2/2] ARM: dts: renesas: r9a06g032-rzn1d400-eb: enable USB host port Wolfram Sang
2025-05-08 17:50   ` Geert Uytterhoeven

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