linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/4] arm64: dts: marvell: espressobin-ultra: enable UART output by default
@ 2021-09-27 15:41 Robert Marko
  2021-09-27 15:41 ` [PATCH 2/4] arm64: dts: marvell: espressobin-ultra: fix SPI-NOR config Robert Marko
                   ` (4 more replies)
  0 siblings, 5 replies; 13+ messages in thread
From: Robert Marko @ 2021-09-27 15:41 UTC (permalink / raw)
  To: andrew, gregory.clement, sebastian.hesselbarth, robh+dt,
	linux-arm-kernel, devicetree, linux-kernel
  Cc: Robert Marko

Since Espressobin Ultra board has a microUSB port
with the onboard USB to UART connected to it to be
used as a debug UART it makes no sense to require
the bootloader to pass console args to the kernel in
order to get console working.

So, use the "stdout-path" property to enable the UART
output on the microUSB port by default.

Signed-off-by: Robert Marko <robert.marko@sartura.hr>
---
 arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts b/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
index c5eb3604dd5b..c1770ceff3c1 100644
--- a/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
+++ b/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
@@ -15,6 +15,10 @@ / {
 	compatible = "globalscale,espressobin-ultra", "marvell,armada3720",
 		     "marvell,armada3710";
 
+	chosen {
+		stdout-path = "serial0:115200n8";
+	};
+
 	aliases {
 		/* ethernet1 is WAN port */
 		ethernet1 = &switch0port5;
-- 
2.31.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* [PATCH 2/4] arm64: dts: marvell: espressobin-ultra: fix SPI-NOR config
  2021-09-27 15:41 [PATCH 1/4] arm64: dts: marvell: espressobin-ultra: enable UART output by default Robert Marko
@ 2021-09-27 15:41 ` Robert Marko
  2021-09-27 15:41 ` [PATCH 3/4] arm64: dts: marvell: espressobin-ultra: add PHY and switch reset pins Robert Marko
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 13+ messages in thread
From: Robert Marko @ 2021-09-27 15:41 UTC (permalink / raw)
  To: andrew, gregory.clement, sebastian.hesselbarth, robh+dt,
	linux-arm-kernel, devicetree, linux-kernel
  Cc: Robert Marko

SPI config for the SPI-NOR is incorrect and completely breaking
reading/writing to the onboard SPI-NOR.

SPI-NOR is connected in the single(x1) IO mode and not in the quad
(x4) mode.
Also, there is no need to override the max frequency from the DTSI
as the mx25u3235f that is used supports 104Mhz.

Signed-off-by: Robert Marko <robert.marko@sartura.hr>
---
 arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts | 4 ----
 1 file changed, 4 deletions(-)

diff --git a/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts b/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
index c1770ceff3c1..8a700afd0570 100644
--- a/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
+++ b/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
@@ -75,10 +75,6 @@ &sdhci1 {
 
 &spi0 {
 	flash@0 {
-		spi-max-frequency = <108000000>;
-		spi-rx-bus-width = <4>;
-		spi-tx-bus-width = <4>;
-
 		partitions {
 			compatible = "fixed-partitions";
 			#address-cells = <1>;
-- 
2.31.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* [PATCH 3/4] arm64: dts: marvell: espressobin-ultra: add PHY and switch reset pins
  2021-09-27 15:41 [PATCH 1/4] arm64: dts: marvell: espressobin-ultra: enable UART output by default Robert Marko
  2021-09-27 15:41 ` [PATCH 2/4] arm64: dts: marvell: espressobin-ultra: fix SPI-NOR config Robert Marko
@ 2021-09-27 15:41 ` Robert Marko
  2021-09-27 16:38   ` Andrew Lunn
  2021-09-28 15:32   ` Pali Rohár
  2021-09-27 15:41 ` [PATCH 4/4] arm64: dts: marvell: espressobin-ultra: enable front USB3 port Robert Marko
                   ` (2 subsequent siblings)
  4 siblings, 2 replies; 13+ messages in thread
From: Robert Marko @ 2021-09-27 15:41 UTC (permalink / raw)
  To: andrew, gregory.clement, sebastian.hesselbarth, robh+dt,
	linux-arm-kernel, devicetree, linux-kernel
  Cc: Robert Marko

Both the Topaz switch and 88E1512 PHY have their reset and interrupts
connected to the SoC.

So, define the Topaz and 88E1512 reset pins in the DTS.

Defining the interrupt pins wont work as both the 88E1512 and the
Topaz switch uses active LOW IRQ signals but the A37xx GPIO controller
only supports edge triggers.
88E1512 would require special setup anyway as its INT pin is shared with
the LED2 and you first need to configure it as INT.

Signed-off-by: Robert Marko <robert.marko@sartura.hr>
---
 arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts b/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
index 8a700afd0570..96855a10b4a0 100644
--- a/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
+++ b/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
@@ -118,12 +118,16 @@ &usb3 {
 &mdio {
 	extphy: ethernet-phy@1 {
 		reg = <1>;
+
+		reset-gpios = <&gpionb 2 GPIO_ACTIVE_LOW>;
 	};
 };
 
 &switch0 {
 	reg = <3>;
 
+	reset-gpios = <&gpiosb 23 GPIO_ACTIVE_LOW>;
+
 	ports {
 		switch0port1: port@1 {
 			reg = <1>;
-- 
2.31.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* [PATCH 4/4] arm64: dts: marvell: espressobin-ultra: enable front USB3 port
  2021-09-27 15:41 [PATCH 1/4] arm64: dts: marvell: espressobin-ultra: enable UART output by default Robert Marko
  2021-09-27 15:41 ` [PATCH 2/4] arm64: dts: marvell: espressobin-ultra: fix SPI-NOR config Robert Marko
  2021-09-27 15:41 ` [PATCH 3/4] arm64: dts: marvell: espressobin-ultra: add PHY and switch reset pins Robert Marko
@ 2021-09-27 15:41 ` Robert Marko
  2021-09-28 15:37   ` Pali Rohár
  2021-09-27 16:37 ` [PATCH 1/4] arm64: dts: marvell: espressobin-ultra: enable UART output by default Andrew Lunn
  2021-09-28 15:13 ` Pali Rohár
  4 siblings, 1 reply; 13+ messages in thread
From: Robert Marko @ 2021-09-27 15:41 UTC (permalink / raw)
  To: andrew, gregory.clement, sebastian.hesselbarth, robh+dt,
	linux-arm-kernel, devicetree, linux-kernel
  Cc: Robert Marko

Espressobin Ultra has a front panel USB3.0 Type-A port which works
just fine so enable it.
I dont see a reason why it was disabled in the first place anyway.

Signed-off-by: Robert Marko <robert.marko@sartura.hr>
---
 arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts | 1 -
 1 file changed, 1 deletion(-)

diff --git a/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts b/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
index 96855a10b4a0..aada43fa236c 100644
--- a/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
+++ b/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
@@ -112,7 +112,6 @@ rtc@51 {
 
 &usb3 {
 	usb-phy = <&usb3_phy>;
-	status = "disabled";
 };
 
 &mdio {
-- 
2.31.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* Re: [PATCH 1/4] arm64: dts: marvell: espressobin-ultra: enable UART output by default
  2021-09-27 15:41 [PATCH 1/4] arm64: dts: marvell: espressobin-ultra: enable UART output by default Robert Marko
                   ` (2 preceding siblings ...)
  2021-09-27 15:41 ` [PATCH 4/4] arm64: dts: marvell: espressobin-ultra: enable front USB3 port Robert Marko
@ 2021-09-27 16:37 ` Andrew Lunn
  2021-09-28 15:13 ` Pali Rohár
  4 siblings, 0 replies; 13+ messages in thread
From: Andrew Lunn @ 2021-09-27 16:37 UTC (permalink / raw)
  To: Robert Marko
  Cc: gregory.clement, sebastian.hesselbarth, robh+dt,
	linux-arm-kernel, devicetree, linux-kernel

On Mon, Sep 27, 2021 at 05:41:56PM +0200, Robert Marko wrote:
> Since Espressobin Ultra board has a microUSB port
> with the onboard USB to UART connected to it to be
> used as a debug UART it makes no sense to require
> the bootloader to pass console args to the kernel in
> order to get console working.
> 
> So, use the "stdout-path" property to enable the UART
> output on the microUSB port by default.
> 
> Signed-off-by: Robert Marko <robert.marko@sartura.hr>

Reviewed-by: Andrew Lunn <andrew@lunn.ch>

    Andrew

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* Re: [PATCH 3/4] arm64: dts: marvell: espressobin-ultra: add PHY and switch reset pins
  2021-09-27 15:41 ` [PATCH 3/4] arm64: dts: marvell: espressobin-ultra: add PHY and switch reset pins Robert Marko
@ 2021-09-27 16:38   ` Andrew Lunn
  2021-09-28 15:32   ` Pali Rohár
  1 sibling, 0 replies; 13+ messages in thread
From: Andrew Lunn @ 2021-09-27 16:38 UTC (permalink / raw)
  To: Robert Marko
  Cc: gregory.clement, sebastian.hesselbarth, robh+dt,
	linux-arm-kernel, devicetree, linux-kernel

On Mon, Sep 27, 2021 at 05:41:58PM +0200, Robert Marko wrote:
> Both the Topaz switch and 88E1512 PHY have their reset and interrupts
> connected to the SoC.
> 
> So, define the Topaz and 88E1512 reset pins in the DTS.
> 
> Defining the interrupt pins wont work as both the 88E1512 and the
> Topaz switch uses active LOW IRQ signals but the A37xx GPIO controller
> only supports edge triggers.
> 88E1512 would require special setup anyway as its INT pin is shared with
> the LED2 and you first need to configure it as INT.
> 
> Signed-off-by: Robert Marko <robert.marko@sartura.hr>

Reviewed-by: Andrew Lunn <andrew@lunn.ch>

    Andrew

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* Re: [PATCH 1/4] arm64: dts: marvell: espressobin-ultra: enable UART output by default
  2021-09-27 15:41 [PATCH 1/4] arm64: dts: marvell: espressobin-ultra: enable UART output by default Robert Marko
                   ` (3 preceding siblings ...)
  2021-09-27 16:37 ` [PATCH 1/4] arm64: dts: marvell: espressobin-ultra: enable UART output by default Andrew Lunn
@ 2021-09-28 15:13 ` Pali Rohár
  2021-09-28 15:49   ` Robert Marko
  4 siblings, 1 reply; 13+ messages in thread
From: Pali Rohár @ 2021-09-28 15:13 UTC (permalink / raw)
  To: Robert Marko
  Cc: andrew, gregory.clement, sebastian.hesselbarth, robh+dt,
	linux-arm-kernel, devicetree, linux-kernel

On Monday 27 September 2021 17:41:56 Robert Marko wrote:
> Since Espressobin Ultra board has a microUSB port
> with the onboard USB to UART connected to it to be
> used as a debug UART it makes no sense to require
> the bootloader to pass console args to the kernel in
> order to get console working.
> 
> So, use the "stdout-path" property to enable the UART
> output on the microUSB port by default.
> 
> Signed-off-by: Robert Marko <robert.marko@sartura.hr>
> ---
>  arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts b/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
> index c5eb3604dd5b..c1770ceff3c1 100644
> --- a/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
> +++ b/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
> @@ -15,6 +15,10 @@ / {
>  	compatible = "globalscale,espressobin-ultra", "marvell,armada3720",
>  		     "marvell,armada3710";
>  
> +	chosen {
> +		stdout-path = "serial0:115200n8";
> +	};
> +

This code is duplication of common espressobin code from
armada-3720-espressobin.dtsi file:
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/arch/arm64/boot/dts/marvell/armada-3720-espressobin.dtsi

>  	aliases {
>  		/* ethernet1 is WAN port */
>  		ethernet1 = &switch0port5;
> -- 
> 2.31.1
> 

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* Re: [PATCH 3/4] arm64: dts: marvell: espressobin-ultra: add PHY and switch reset pins
  2021-09-27 15:41 ` [PATCH 3/4] arm64: dts: marvell: espressobin-ultra: add PHY and switch reset pins Robert Marko
  2021-09-27 16:38   ` Andrew Lunn
@ 2021-09-28 15:32   ` Pali Rohár
  2021-09-28 16:02     ` Robert Marko
  1 sibling, 1 reply; 13+ messages in thread
From: Pali Rohár @ 2021-09-28 15:32 UTC (permalink / raw)
  To: Robert Marko
  Cc: andrew, gregory.clement, sebastian.hesselbarth, robh+dt,
	linux-arm-kernel, devicetree, linux-kernel

On Monday 27 September 2021 17:41:58 Robert Marko wrote:
> Both the Topaz switch and 88E1512 PHY have their reset and interrupts
> connected to the SoC.
> 
> So, define the Topaz and 88E1512 reset pins in the DTS.

Are reset pins connected only on ultra variant? Or on all espressobin
variants? Because if they are on all variants then definitions should go
into common dtsi file.

I see that "gpionb 2" is on v7 variant connected to LED2. So I'm not
sure if this one gpio is also shared or not.

> Defining the interrupt pins wont work as both the 88E1512 and the
> Topaz switch uses active LOW IRQ signals but the A37xx GPIO controller
> only supports edge triggers.
> 88E1512 would require special setup anyway as its INT pin is shared with
> the LED2 and you first need to configure it as INT.

Do you plan to finish also this additional setup?

> Signed-off-by: Robert Marko <robert.marko@sartura.hr>
> ---
>  arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts b/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
> index 8a700afd0570..96855a10b4a0 100644
> --- a/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
> +++ b/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
> @@ -118,12 +118,16 @@ &usb3 {
>  &mdio {
>  	extphy: ethernet-phy@1 {
>  		reg = <1>;
> +
> +		reset-gpios = <&gpionb 2 GPIO_ACTIVE_LOW>;
>  	};
>  };
>  
>  &switch0 {
>  	reg = <3>;
>  
> +	reset-gpios = <&gpiosb 23 GPIO_ACTIVE_LOW>;
> +
>  	ports {
>  		switch0port1: port@1 {
>  			reg = <1>;
> -- 
> 2.31.1
> 

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* Re: [PATCH 4/4] arm64: dts: marvell: espressobin-ultra: enable front USB3 port
  2021-09-27 15:41 ` [PATCH 4/4] arm64: dts: marvell: espressobin-ultra: enable front USB3 port Robert Marko
@ 2021-09-28 15:37   ` Pali Rohár
  2021-09-28 16:02     ` Robert Marko
  0 siblings, 1 reply; 13+ messages in thread
From: Pali Rohár @ 2021-09-28 15:37 UTC (permalink / raw)
  To: Robert Marko
  Cc: andrew, gregory.clement, sebastian.hesselbarth, robh+dt,
	linux-arm-kernel, devicetree, linux-kernel

On Monday 27 September 2021 17:41:59 Robert Marko wrote:
> Espressobin Ultra has a front panel USB3.0 Type-A port which works
> just fine so enable it.
> I dont see a reason why it was disabled in the first place anyway.

If USB 3.0 port is was tested and is working fine, then what about
adding Fixes: tag into commit message?

> Signed-off-by: Robert Marko <robert.marko@sartura.hr>
> ---
>  arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts | 1 -
>  1 file changed, 1 deletion(-)
> 
> diff --git a/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts b/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
> index 96855a10b4a0..aada43fa236c 100644
> --- a/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
> +++ b/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
> @@ -112,7 +112,6 @@ rtc@51 {
>  
>  &usb3 {
>  	usb-phy = <&usb3_phy>;
> -	status = "disabled";
>  };
>  
>  &mdio {
> -- 
> 2.31.1
> 

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* Re: [PATCH 1/4] arm64: dts: marvell: espressobin-ultra: enable UART output by default
  2021-09-28 15:13 ` Pali Rohár
@ 2021-09-28 15:49   ` Robert Marko
  0 siblings, 0 replies; 13+ messages in thread
From: Robert Marko @ 2021-09-28 15:49 UTC (permalink / raw)
  To: Pali Rohár
  Cc: Andrew Lunn, gregory.clement, sebastian.hesselbarth, Rob Herring,
	linux-arm-kernel, devicetree, Linux Kernel Mailing List

On Tue, Sep 28, 2021 at 5:13 PM Pali Rohár <pali@kernel.org> wrote:
>
> On Monday 27 September 2021 17:41:56 Robert Marko wrote:
> > Since Espressobin Ultra board has a microUSB port
> > with the onboard USB to UART connected to it to be
> > used as a debug UART it makes no sense to require
> > the bootloader to pass console args to the kernel in
> > order to get console working.
> >
> > So, use the "stdout-path" property to enable the UART
> > output on the microUSB port by default.
> >
> > Signed-off-by: Robert Marko <robert.marko@sartura.hr>
> > ---
> >  arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts | 4 ++++
> >  1 file changed, 4 insertions(+)
> >
> > diff --git a/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts b/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
> > index c5eb3604dd5b..c1770ceff3c1 100644
> > --- a/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
> > +++ b/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
> > @@ -15,6 +15,10 @@ / {
> >       compatible = "globalscale,espressobin-ultra", "marvell,armada3720",
> >                    "marvell,armada3710";
> >
> > +     chosen {
> > +             stdout-path = "serial0:115200n8";
> > +     };
> > +
>
> This code is duplication of common espressobin code from
> armada-3720-espressobin.dtsi file:
> https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/arch/arm64/boot/dts/marvell/armada-3720-espressobin.dtsi

Ahh yes, I don't know why was it not working by default then.
Sorry for the noise, I will drop this patch.

Regards,
Robert
>
> >       aliases {
> >               /* ethernet1 is WAN port */
> >               ethernet1 = &switch0port5;
> > --
> > 2.31.1
> >



-- 
Robert Marko
Staff Embedded Linux Engineer
Sartura Ltd.
Lendavska ulica 16a
10000 Zagreb, Croatia
Email: robert.marko@sartura.hr
Web: www.sartura.hr

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* Re: [PATCH 3/4] arm64: dts: marvell: espressobin-ultra: add PHY and switch reset pins
  2021-09-28 15:32   ` Pali Rohár
@ 2021-09-28 16:02     ` Robert Marko
  2022-09-24 12:03       ` Pali Rohár
  0 siblings, 1 reply; 13+ messages in thread
From: Robert Marko @ 2021-09-28 16:02 UTC (permalink / raw)
  To: Pali Rohár
  Cc: Andrew Lunn, gregory.clement, sebastian.hesselbarth, Rob Herring,
	linux-arm-kernel, devicetree, Linux Kernel Mailing List

On Tue, Sep 28, 2021 at 5:32 PM Pali Rohár <pali@kernel.org> wrote:
>
> On Monday 27 September 2021 17:41:58 Robert Marko wrote:
> > Both the Topaz switch and 88E1512 PHY have their reset and interrupts
> > connected to the SoC.
> >
> > So, define the Topaz and 88E1512 reset pins in the DTS.
>
> Are reset pins connected only on ultra variant? Or on all espressobin
> variants? Because if they are on all variants then definitions should go
> into common dtsi file.
>
> I see that "gpionb 2" is on v7 variant connected to LED2. So I'm not
> sure if this one gpio is also shared or not.

As far as I know only Ultra has the reset pins connected, on the v5 and v7 Topaz
reset is tied to the system reset so it's not controllable.
I checked both the v5 and v7 schematics and it's like that.
>
> > Defining the interrupt pins wont work as both the 88E1512 and the
> > Topaz switch uses active LOW IRQ signals but the A37xx GPIO controller
> > only supports edge triggers.
> > 88E1512 would require special setup anyway as its INT pin is shared with
> > the LED2 and you first need to configure it as INT.
>
> Do you plan to finish also this additional setup?

Yes as the MOCHAbin board that I have sent the DTS for also has it connected
so I can use it as Armada 7040 supports level triggers, unlike the A3720.
It's in the queue but as a low priority, so I don't know when will I get to it.

Regards,
Robert
>
> > Signed-off-by: Robert Marko <robert.marko@sartura.hr>
> > ---
> >  arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts | 4 ++++
> >  1 file changed, 4 insertions(+)
> >
> > diff --git a/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts b/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
> > index 8a700afd0570..96855a10b4a0 100644
> > --- a/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
> > +++ b/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
> > @@ -118,12 +118,16 @@ &usb3 {
> >  &mdio {
> >       extphy: ethernet-phy@1 {
> >               reg = <1>;
> > +
> > +             reset-gpios = <&gpionb 2 GPIO_ACTIVE_LOW>;
> >       };
> >  };
> >
> >  &switch0 {
> >       reg = <3>;
> >
> > +     reset-gpios = <&gpiosb 23 GPIO_ACTIVE_LOW>;
> > +
> >       ports {
> >               switch0port1: port@1 {
> >                       reg = <1>;
> > --
> > 2.31.1
> >



-- 
Robert Marko
Staff Embedded Linux Engineer
Sartura Ltd.
Lendavska ulica 16a
10000 Zagreb, Croatia
Email: robert.marko@sartura.hr
Web: www.sartura.hr

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* Re: [PATCH 4/4] arm64: dts: marvell: espressobin-ultra: enable front USB3 port
  2021-09-28 15:37   ` Pali Rohár
@ 2021-09-28 16:02     ` Robert Marko
  0 siblings, 0 replies; 13+ messages in thread
From: Robert Marko @ 2021-09-28 16:02 UTC (permalink / raw)
  To: Pali Rohár
  Cc: Andrew Lunn, gregory.clement, sebastian.hesselbarth, Rob Herring,
	linux-arm-kernel, devicetree, Linux Kernel Mailing List

On Tue, Sep 28, 2021 at 5:37 PM Pali Rohár <pali@kernel.org> wrote:
>
> On Monday 27 September 2021 17:41:59 Robert Marko wrote:
> > Espressobin Ultra has a front panel USB3.0 Type-A port which works
> > just fine so enable it.
> > I dont see a reason why it was disabled in the first place anyway.
>
> If USB 3.0 port is was tested and is working fine, then what about
> adding Fixes: tag into commit message?

Sure, gotta send a v4 anyway dropping the first patch.

Regards,
Robert
>
> > Signed-off-by: Robert Marko <robert.marko@sartura.hr>
> > ---
> >  arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts | 1 -
> >  1 file changed, 1 deletion(-)
> >
> > diff --git a/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts b/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
> > index 96855a10b4a0..aada43fa236c 100644
> > --- a/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
> > +++ b/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
> > @@ -112,7 +112,6 @@ rtc@51 {
> >
> >  &usb3 {
> >       usb-phy = <&usb3_phy>;
> > -     status = "disabled";
> >  };
> >
> >  &mdio {
> > --
> > 2.31.1
> >



-- 
Robert Marko
Staff Embedded Linux Engineer
Sartura Ltd.
Lendavska ulica 16a
10000 Zagreb, Croatia
Email: robert.marko@sartura.hr
Web: www.sartura.hr

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* Re: [PATCH 3/4] arm64: dts: marvell: espressobin-ultra: add PHY and switch reset pins
  2021-09-28 16:02     ` Robert Marko
@ 2022-09-24 12:03       ` Pali Rohár
  0 siblings, 0 replies; 13+ messages in thread
From: Pali Rohár @ 2022-09-24 12:03 UTC (permalink / raw)
  To: Robert Marko
  Cc: Andrew Lunn, gregory.clement, sebastian.hesselbarth, Rob Herring,
	linux-arm-kernel, devicetree, Linux Kernel Mailing List

On Tuesday 28 September 2021 18:02:19 Robert Marko wrote:
> On Tue, Sep 28, 2021 at 5:32 PM Pali Rohár <pali@kernel.org> wrote:
> >
> > On Monday 27 September 2021 17:41:58 Robert Marko wrote:
> > > Both the Topaz switch and 88E1512 PHY have their reset and interrupts
> > > connected to the SoC.
> > >
> > > So, define the Topaz and 88E1512 reset pins in the DTS.
> >
> > Are reset pins connected only on ultra variant? Or on all espressobin
> > variants? Because if they are on all variants then definitions should go
> > into common dtsi file.
> >
> > I see that "gpionb 2" is on v7 variant connected to LED2. So I'm not
> > sure if this one gpio is also shared or not.
> 
> As far as I know only Ultra has the reset pins connected, on the v5 and v7 Topaz
> reset is tied to the system reset so it's not controllable.
> I checked both the v5 and v7 schematics and it's like that.
> >
> > > Defining the interrupt pins wont work as both the 88E1512 and the
> > > Topaz switch uses active LOW IRQ signals but the A37xx GPIO controller
> > > only supports edge triggers.
> > > 88E1512 would require special setup anyway as its INT pin is shared with
> > > the LED2 and you first need to configure it as INT.
> >
> > Do you plan to finish also this additional setup?
> 
> Yes as the MOCHAbin board that I have sent the DTS for also has it connected
> so I can use it as Armada 7040 supports level triggers, unlike the A3720.
> It's in the queue but as a low priority, so I don't know when will I get to it.

I have WIP patch for A37xx gpio/pinctrl driver which adds support for
level interrupts. I think you would need it for testing...

> Regards,
> Robert
> >
> > > Signed-off-by: Robert Marko <robert.marko@sartura.hr>
> > > ---
> > >  arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts | 4 ++++
> > >  1 file changed, 4 insertions(+)
> > >
> > > diff --git a/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts b/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
> > > index 8a700afd0570..96855a10b4a0 100644
> > > --- a/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
> > > +++ b/arch/arm64/boot/dts/marvell/armada-3720-espressobin-ultra.dts
> > > @@ -118,12 +118,16 @@ &usb3 {
> > >  &mdio {
> > >       extphy: ethernet-phy@1 {
> > >               reg = <1>;
> > > +
> > > +             reset-gpios = <&gpionb 2 GPIO_ACTIVE_LOW>;
> > >       };
> > >  };
> > >
> > >  &switch0 {
> > >       reg = <3>;
> > >
> > > +     reset-gpios = <&gpiosb 23 GPIO_ACTIVE_LOW>;
> > > +
> > >       ports {
> > >               switch0port1: port@1 {
> > >                       reg = <1>;
> > > --
> > > 2.31.1
> > >
> 
> 
> 
> -- 
> Robert Marko
> Staff Embedded Linux Engineer
> Sartura Ltd.
> Lendavska ulica 16a
> 10000 Zagreb, Croatia
> Email: robert.marko@sartura.hr
> Web: www.sartura.hr

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

end of thread, other threads:[~2022-09-24 12:04 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-09-27 15:41 [PATCH 1/4] arm64: dts: marvell: espressobin-ultra: enable UART output by default Robert Marko
2021-09-27 15:41 ` [PATCH 2/4] arm64: dts: marvell: espressobin-ultra: fix SPI-NOR config Robert Marko
2021-09-27 15:41 ` [PATCH 3/4] arm64: dts: marvell: espressobin-ultra: add PHY and switch reset pins Robert Marko
2021-09-27 16:38   ` Andrew Lunn
2021-09-28 15:32   ` Pali Rohár
2021-09-28 16:02     ` Robert Marko
2022-09-24 12:03       ` Pali Rohár
2021-09-27 15:41 ` [PATCH 4/4] arm64: dts: marvell: espressobin-ultra: enable front USB3 port Robert Marko
2021-09-28 15:37   ` Pali Rohár
2021-09-28 16:02     ` Robert Marko
2021-09-27 16:37 ` [PATCH 1/4] arm64: dts: marvell: espressobin-ultra: enable UART output by default Andrew Lunn
2021-09-28 15:13 ` Pali Rohár
2021-09-28 15:49   ` Robert Marko

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