diff mbox

[1/2] arm64: dts: updates serial aliases for ls1043a rdb and qds boards

Message ID 1472244381-1766-2-git-send-email-stuart.yoder@nxp.com (mailing list archive)
State New, archived
Headers show

Commit Message

Stuart Yoder Aug. 26, 2016, 8:46 p.m. UTC
-add missing serial aliases to ls1043a-r4db
-update lss1043a-qds boards serial aliases to use the standard duarts
 instead of low power uarts

Signed-off-by: Stuart Yoder <stuart.yoder@nxp.com>
---
 arch/arm64/boot/dts/freescale/fsl-ls1043a-qds.dts | 10 ++++------
 arch/arm64/boot/dts/freescale/fsl-ls1043a-rdb.dts |  4 ++++
 2 files changed, 8 insertions(+), 6 deletions(-)

Comments

Arnd Bergmann Aug. 29, 2016, 11:01 a.m. UTC | #1
On Friday, August 26, 2016 3:46:20 PM CEST Stuart Yoder wrote:
> -               serial0 = &lpuart0;
> -               serial1 = &lpuart1;
> -               serial2 = &lpuart2;
> -               serial3 = &lpuart3;
> -               serial4 = &lpuart4;
> -               serial5 = &lpuart5;
> +               serial0 = &duart0;
> +               serial1 = &duart1;
> +               serial2 = &duart2;
> +               serial3 = &duart3;

It looks like your board has six uarts that are all driven with the
lpuart driver, but after the change, you only list four. Should
the serial4 and serial5 aliases keep pointing at lpuart devices
so you can still drive all physical connectors?

	Arnd
Shawn Guo Aug. 29, 2016, 2:01 p.m. UTC | #2
On Fri, Aug 26, 2016 at 03:46:20PM -0500, Stuart Yoder wrote:
> -add missing serial aliases to ls1043a-r4db

s/ls1043a-r4db/ls1043a-rdb

Shawn

> -update lss1043a-qds boards serial aliases to use the standard duarts
>  instead of low power uarts
> 
> Signed-off-by: Stuart Yoder <stuart.yoder@nxp.com>
Stuart Yoder Aug. 29, 2016, 6:30 p.m. UTC | #3
> -----Original Message-----
> From: Arnd Bergmann [mailto:arnd@arndb.de]
> Sent: Monday, August 29, 2016 6:01 AM
> To: Stuart Yoder <stuart.yoder@nxp.com>
> Cc: devicetree@vger.kernel.org; linux-arm-kernel@lists.infradead.org; shawnguo@kernel.org
> Subject: Re: [PATCH 1/2] arm64: dts: updates serial aliases for ls1043a rdb and qds boards
> 
> On Friday, August 26, 2016 3:46:20 PM CEST Stuart Yoder wrote:
> > -               serial0 = &lpuart0;
> > -               serial1 = &lpuart1;
> > -               serial2 = &lpuart2;
> > -               serial3 = &lpuart3;
> > -               serial4 = &lpuart4;
> > -               serial5 = &lpuart5;
> > +               serial0 = &duart0;
> > +               serial1 = &duart1;
> > +               serial2 = &duart2;
> > +               serial3 = &duart3;
> 
> It looks like your board has six uarts that are all driven with the
> lpuart driver, but after the change, you only list four. Should
> the serial4 and serial5 aliases keep pointing at lpuart devices
> so you can still drive all physical connectors?

The only existing reference I can find to the serial aliases is if the
OF_STDOUT_VIA_ALIAS is enabled in u-boot to specify the console.  The
standard ls1043aqds_defconfig in u-boot specifies DUARTs for the console,
which is why I'm proposing making the 4 DUARTs the default serial aliases
in the device tree.

There is a separate defconfig in u-boot to enable/use LPUARTs instead
of the normal DUARTs.  For that scenario, my take is that firmware should
update the DT aliases to reflect the actual use of the serial ports.

But, the default should be the DUARTs which is the normal case for this
board, which is why this patch is changing them.

Thanks,
Stuart
Arnd Bergmann Aug. 29, 2016, 8:38 p.m. UTC | #4
On Monday 29 August 2016, Stuart Yoder wrote:
> > -----Original Message-----
> > From: Arnd Bergmann [mailto:arnd@arndb.de]
> > Sent: Monday, August 29, 2016 6:01 AM
> > To: Stuart Yoder <stuart.yoder@nxp.com>
> > Cc: devicetree@vger.kernel.org; linux-arm-kernel@lists.infradead.org; shawnguo@kernel.org
> > Subject: Re: [PATCH 1/2] arm64: dts: updates serial aliases for ls1043a rdb and qds boards
> > 
> > On Friday, August 26, 2016 3:46:20 PM CEST Stuart Yoder wrote:
> > > -               serial0 = &lpuart0;
> > > -               serial1 = &lpuart1;
> > > -               serial2 = &lpuart2;
> > > -               serial3 = &lpuart3;
> > > -               serial4 = &lpuart4;
> > > -               serial5 = &lpuart5;
> > > +               serial0 = &duart0;
> > > +               serial1 = &duart1;
> > > +               serial2 = &duart2;
> > > +               serial3 = &duart3;
> > 
> > It looks like your board has six uarts that are all driven with the
> > lpuart driver, but after the change, you only list four. Should
> > the serial4 and serial5 aliases keep pointing at lpuart devices
> > so you can still drive all physical connectors?
> 
> The only existing reference I can find to the serial aliases is if the
> OF_STDOUT_VIA_ALIAS is enabled in u-boot to specify the console.  The
> standard ls1043aqds_defconfig in u-boot specifies DUARTs for the console,
> which is why I'm proposing making the 4 DUARTs the default serial aliases
> in the device tree.

Ok, so they are mutually exclusive, and the last two ports are
unavailable in the default configuration?
 
> There is a separate defconfig in u-boot to enable/use LPUARTs instead
> of the normal DUARTs.  For that scenario, my take is that firmware should
> update the DT aliases to reflect the actual use of the serial ports.

Yes, makes sense.

> But, the default should be the DUARTs which is the normal case for this
> board, which is why this patch is changing them.

Ok

	Arnd
Stuart Yoder Aug. 29, 2016, 9:10 p.m. UTC | #5
> -----Original Message-----
> From: Arnd Bergmann [mailto:arnd@arndb.de]
> Sent: Monday, August 29, 2016 3:38 PM
> To: linux-arm-kernel@lists.infradead.org
> Cc: Stuart Yoder <stuart.yoder@nxp.com>; devicetree@vger.kernel.org; shawnguo@kernel.org
> Subject: Re: [PATCH 1/2] arm64: dts: updates serial aliases for ls1043a rdb and qds boards
> 
> On Monday 29 August 2016, Stuart Yoder wrote:
> > > -----Original Message-----
> > > From: Arnd Bergmann [mailto:arnd@arndb.de]
> > > Sent: Monday, August 29, 2016 6:01 AM
> > > To: Stuart Yoder <stuart.yoder@nxp.com>
> > > Cc: devicetree@vger.kernel.org; linux-arm-kernel@lists.infradead.org; shawnguo@kernel.org
> > > Subject: Re: [PATCH 1/2] arm64: dts: updates serial aliases for ls1043a rdb and qds boards
> > >
> > > On Friday, August 26, 2016 3:46:20 PM CEST Stuart Yoder wrote:
> > > > -               serial0 = &lpuart0;
> > > > -               serial1 = &lpuart1;
> > > > -               serial2 = &lpuart2;
> > > > -               serial3 = &lpuart3;
> > > > -               serial4 = &lpuart4;
> > > > -               serial5 = &lpuart5;
> > > > +               serial0 = &duart0;
> > > > +               serial1 = &duart1;
> > > > +               serial2 = &duart2;
> > > > +               serial3 = &duart3;
> > >
> > > It looks like your board has six uarts that are all driven with the
> > > lpuart driver, but after the change, you only list four. Should
> > > the serial4 and serial5 aliases keep pointing at lpuart devices
> > > so you can still drive all physical connectors?
> >
> > The only existing reference I can find to the serial aliases is if the
> > OF_STDOUT_VIA_ALIAS is enabled in u-boot to specify the console.  The
> > standard ls1043aqds_defconfig in u-boot specifies DUARTs for the console,
> > which is why I'm proposing making the 4 DUARTs the default serial aliases
> > in the device tree.
> 
> Ok, so they are mutually exclusive, and the last two ports are
> unavailable in the default configuration?

Yes, that's the case with u-boot's defconfig.  I'm still trying to
find out whether that mutual exlusivity was a firmware decision or
a hardware limitation.

Stuart
diff mbox

Patch

diff --git a/arch/arm64/boot/dts/freescale/fsl-ls1043a-qds.dts b/arch/arm64/boot/dts/freescale/fsl-ls1043a-qds.dts
index 9d3e9fe..f813d67 100644
--- a/arch/arm64/boot/dts/freescale/fsl-ls1043a-qds.dts
+++ b/arch/arm64/boot/dts/freescale/fsl-ls1043a-qds.dts
@@ -56,12 +56,10 @@ 
 		gpio1 = &gpio2;
 		gpio2 = &gpio3;
 		gpio3 = &gpio4;
-		serial0 = &lpuart0;
-		serial1 = &lpuart1;
-		serial2 = &lpuart2;
-		serial3 = &lpuart3;
-		serial4 = &lpuart4;
-		serial5 = &lpuart5;
+		serial0 = &duart0;
+		serial1 = &duart1;
+		serial2 = &duart2;
+		serial3 = &duart3;
 	};
 };
 
diff --git a/arch/arm64/boot/dts/freescale/fsl-ls1043a-rdb.dts b/arch/arm64/boot/dts/freescale/fsl-ls1043a-rdb.dts
index 4084631..8031cde 100644
--- a/arch/arm64/boot/dts/freescale/fsl-ls1043a-rdb.dts
+++ b/arch/arm64/boot/dts/freescale/fsl-ls1043a-rdb.dts
@@ -52,6 +52,10 @@ 
 
 	aliases {
 		crypto = &crypto;
+		serial0 = &duart0;
+		serial1 = &duart1;
+		serial2 = &duart2;
+		serial3 = &duart3;
 	};
 };