diff mbox

[2/2] ARM: dts: zynq: Add linux,stdout-path and stdout-path

Message ID ea777ffbffea442e3bc69fe11183811772a5716e.1423657710.git.michal.simek@xilinx.com (mailing list archive)
State New, archived
Headers show

Commit Message

Michal Simek Feb. 11, 2015, 12:29 p.m. UTC
parallella - Use reference instead of hardcoded path
             (linux,stdout-path)

stdout-path is used by bootloader to identify console.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
---

U-Boot driver model requires stdout-path.
---
 arch/arm/boot/dts/zynq-parallella.dts | 3 ++-
 arch/arm/boot/dts/zynq-zc702.dts      | 2 ++
 arch/arm/boot/dts/zynq-zc706.dts      | 2 ++
 arch/arm/boot/dts/zynq-zed.dts        | 2 ++
 arch/arm/boot/dts/zynq-zybo.dts       | 2 ++
 5 files changed, 10 insertions(+), 1 deletion(-)

Comments

Mark Rutland Feb. 11, 2015, 12:40 p.m. UTC | #1
On Wed, Feb 11, 2015 at 12:29:02PM +0000, Michal Simek wrote:
> parallella - Use reference instead of hardcoded path
>              (linux,stdout-path)
> 
> stdout-path is used by bootloader to identify console.
> 
> Signed-off-by: Michal Simek <michal.simek@xilinx.com>
> ---
> 
> U-Boot driver model requires stdout-path.
> ---
>  arch/arm/boot/dts/zynq-parallella.dts | 3 ++-
>  arch/arm/boot/dts/zynq-zc702.dts      | 2 ++
>  arch/arm/boot/dts/zynq-zc706.dts      | 2 ++
>  arch/arm/boot/dts/zynq-zed.dts        | 2 ++
>  arch/arm/boot/dts/zynq-zybo.dts       | 2 ++
>  5 files changed, 10 insertions(+), 1 deletion(-)
> 
> diff --git a/arch/arm/boot/dts/zynq-parallella.dts b/arch/arm/boot/dts/zynq-parallella.dts
> index 6a5f51daa708..45228a427006 100644
> --- a/arch/arm/boot/dts/zynq-parallella.dts
> +++ b/arch/arm/boot/dts/zynq-parallella.dts
> @@ -35,7 +35,8 @@
>  
>  	chosen {
>  		bootargs = "console=ttyPS0,115200 earlyprintk root=/dev/mmcblk0p2 rootfstype=ext4 rw rootwait";
> -		linux,stdout-path = "/amba/serial@e0001000";
> +		linux,stdout-path = &uart1;
> +		stdout-path = &uart1;

Given that you added aliases in the last patch, you can use that to
refer to the serial:

	stdout-path - "serial0:115200n8";

With or without the alias you can encode the UART configuration here
too:

	stdout-path = "/amba/serial@e0001000:115200n8"

Which makes the expected configuration explicit without relying on the
Linux-specific bootargs.

Is there any reason to keep linux,stdout-path?

Thanks,
Mark.
Michal Simek Feb. 11, 2015, 2:25 p.m. UTC | #2
On 02/11/2015 01:40 PM, Mark Rutland wrote:
> On Wed, Feb 11, 2015 at 12:29:02PM +0000, Michal Simek wrote:
>> parallella - Use reference instead of hardcoded path
>>              (linux,stdout-path)
>>
>> stdout-path is used by bootloader to identify console.
>>
>> Signed-off-by: Michal Simek <michal.simek@xilinx.com>
>> ---
>>
>> U-Boot driver model requires stdout-path.
>> ---
>>  arch/arm/boot/dts/zynq-parallella.dts | 3 ++-
>>  arch/arm/boot/dts/zynq-zc702.dts      | 2 ++
>>  arch/arm/boot/dts/zynq-zc706.dts      | 2 ++
>>  arch/arm/boot/dts/zynq-zed.dts        | 2 ++
>>  arch/arm/boot/dts/zynq-zybo.dts       | 2 ++
>>  5 files changed, 10 insertions(+), 1 deletion(-)
>>
>> diff --git a/arch/arm/boot/dts/zynq-parallella.dts b/arch/arm/boot/dts/zynq-parallella.dts
>> index 6a5f51daa708..45228a427006 100644
>> --- a/arch/arm/boot/dts/zynq-parallella.dts
>> +++ b/arch/arm/boot/dts/zynq-parallella.dts
>> @@ -35,7 +35,8 @@
>>  
>>  	chosen {
>>  		bootargs = "console=ttyPS0,115200 earlyprintk root=/dev/mmcblk0p2 rootfstype=ext4 rw rootwait";
>> -		linux,stdout-path = "/amba/serial@e0001000";
>> +		linux,stdout-path = &uart1;
>> +		stdout-path = &uart1;
> 
> Given that you added aliases in the last patch, you can use that to
> refer to the serial:
> 
> 	stdout-path - "serial0:115200n8";
> 
> With or without the alias you can encode the UART configuration here
> too:
> 
> 	stdout-path = "/amba/serial@e0001000:115200n8"

let me check this configuration if it is supported by u-boot.

> 
> Which makes the expected configuration explicit without relying on the
> Linux-specific bootargs.
> 
> Is there any reason to keep linux,stdout-path?

Agree when stdout-patch is defined there is no reason to use linux,stdout-patch.

Thanks,
Michal
Andreas Färber Feb. 11, 2015, 6:18 p.m. UTC | #3
Am 11.02.2015 um 15:25 schrieb Michal Simek:
> On 02/11/2015 01:40 PM, Mark Rutland wrote:
>> On Wed, Feb 11, 2015 at 12:29:02PM +0000, Michal Simek wrote:
>>> parallella - Use reference instead of hardcoded path
>>>              (linux,stdout-path)
>>>
>>> stdout-path is used by bootloader to identify console.
>>>
>>> Signed-off-by: Michal Simek <michal.simek@xilinx.com>
>>> ---
>>>
>>> U-Boot driver model requires stdout-path.
>>> ---
>>>  arch/arm/boot/dts/zynq-parallella.dts | 3 ++-
>>>  arch/arm/boot/dts/zynq-zc702.dts      | 2 ++
>>>  arch/arm/boot/dts/zynq-zc706.dts      | 2 ++
>>>  arch/arm/boot/dts/zynq-zed.dts        | 2 ++
>>>  arch/arm/boot/dts/zynq-zybo.dts       | 2 ++
>>>  5 files changed, 10 insertions(+), 1 deletion(-)
>>>
>>> diff --git a/arch/arm/boot/dts/zynq-parallella.dts b/arch/arm/boot/dts/zynq-parallella.dts
>>> index 6a5f51daa708..45228a427006 100644
>>> --- a/arch/arm/boot/dts/zynq-parallella.dts
>>> +++ b/arch/arm/boot/dts/zynq-parallella.dts
>>> @@ -35,7 +35,8 @@
>>>  
>>>  	chosen {
>>>  		bootargs = "console=ttyPS0,115200 earlyprintk root=/dev/mmcblk0p2 rootfstype=ext4 rw rootwait";
>>> -		linux,stdout-path = "/amba/serial@e0001000";
>>> +		linux,stdout-path = &uart1;
>>> +		stdout-path = &uart1;
>>
>> Given that you added aliases in the last patch, you can use that to
>> refer to the serial:
>>
>> 	stdout-path - "serial0:115200n8";
>>
>> With or without the alias you can encode the UART configuration here
>> too:
>>
>> 	stdout-path = "/amba/serial@e0001000:115200n8"
> 
> let me check this configuration if it is supported by u-boot.

I would be surprised if either is supported - my Parallella ships:
U-Boot 2012.10-00003-g792c31c (Jan 03 2014 - 12:24:08)
and upstream U-Boot still doesn't have support for the Parallella.

>> Which makes the expected configuration explicit without relying on the
>> Linux-specific bootargs.
>>
>> Is there any reason to keep linux,stdout-path?
> 
> Agree when stdout-patch is defined there is no reason to use linux,stdout-patch.

It's not used, it was added on reviewers' request at the time. Feel free
to drop. But again, we are bound for patch conflict here.

Regards,
Andreas
Michal Simek Feb. 12, 2015, 9:36 a.m. UTC | #4
On 02/11/2015 07:18 PM, Andreas Färber wrote:
> Am 11.02.2015 um 15:25 schrieb Michal Simek:
>> On 02/11/2015 01:40 PM, Mark Rutland wrote:
>>> On Wed, Feb 11, 2015 at 12:29:02PM +0000, Michal Simek wrote:
>>>> parallella - Use reference instead of hardcoded path
>>>>              (linux,stdout-path)
>>>>
>>>> stdout-path is used by bootloader to identify console.
>>>>
>>>> Signed-off-by: Michal Simek <michal.simek@xilinx.com>
>>>> ---
>>>>
>>>> U-Boot driver model requires stdout-path.
>>>> ---
>>>>  arch/arm/boot/dts/zynq-parallella.dts | 3 ++-
>>>>  arch/arm/boot/dts/zynq-zc702.dts      | 2 ++
>>>>  arch/arm/boot/dts/zynq-zc706.dts      | 2 ++
>>>>  arch/arm/boot/dts/zynq-zed.dts        | 2 ++
>>>>  arch/arm/boot/dts/zynq-zybo.dts       | 2 ++
>>>>  5 files changed, 10 insertions(+), 1 deletion(-)
>>>>
>>>> diff --git a/arch/arm/boot/dts/zynq-parallella.dts b/arch/arm/boot/dts/zynq-parallella.dts
>>>> index 6a5f51daa708..45228a427006 100644
>>>> --- a/arch/arm/boot/dts/zynq-parallella.dts
>>>> +++ b/arch/arm/boot/dts/zynq-parallella.dts
>>>> @@ -35,7 +35,8 @@
>>>>  
>>>>  	chosen {
>>>>  		bootargs = "console=ttyPS0,115200 earlyprintk root=/dev/mmcblk0p2 rootfstype=ext4 rw rootwait";
>>>> -		linux,stdout-path = "/amba/serial@e0001000";
>>>> +		linux,stdout-path = &uart1;
>>>> +		stdout-path = &uart1;
>>>
>>> Given that you added aliases in the last patch, you can use that to
>>> refer to the serial:
>>>
>>> 	stdout-path - "serial0:115200n8";
>>>
>>> With or without the alias you can encode the UART configuration here
>>> too:
>>>
>>> 	stdout-path = "/amba/serial@e0001000:115200n8"
>>
>> let me check this configuration if it is supported by u-boot.
> 
> I would be surprised if either is supported - my Parallella ships:
> U-Boot 2012.10-00003-g792c31c (Jan 03 2014 - 12:24:08)
> and upstream U-Boot still doesn't have support for the Parallella.

Ancient u-boot versions are not using this features. Zynq hasn't been
switched to DM anyway.

>>> Which makes the expected configuration explicit without relying on the
>>> Linux-specific bootargs.
>>>
>>> Is there any reason to keep linux,stdout-path?
>>
>> Agree when stdout-patch is defined there is no reason to use linux,stdout-patch.
> 
> It's not used, it was added on reviewers' request at the time. Feel free
> to drop. But again, we are bound for patch conflict here.

I will solved that conflicts - it is easy one.

Thanks,
Michal
Michal Simek Feb. 12, 2015, 9:38 a.m. UTC | #5
Hi Mark and Simon,

On 02/11/2015 03:25 PM, Michal Simek wrote:
> On 02/11/2015 01:40 PM, Mark Rutland wrote:
>> On Wed, Feb 11, 2015 at 12:29:02PM +0000, Michal Simek wrote:
>>> parallella - Use reference instead of hardcoded path
>>>              (linux,stdout-path)
>>>
>>> stdout-path is used by bootloader to identify console.
>>>
>>> Signed-off-by: Michal Simek <michal.simek@xilinx.com>
>>> ---
>>>
>>> U-Boot driver model requires stdout-path.
>>> ---
>>>  arch/arm/boot/dts/zynq-parallella.dts | 3 ++-
>>>  arch/arm/boot/dts/zynq-zc702.dts      | 2 ++
>>>  arch/arm/boot/dts/zynq-zc706.dts      | 2 ++
>>>  arch/arm/boot/dts/zynq-zed.dts        | 2 ++
>>>  arch/arm/boot/dts/zynq-zybo.dts       | 2 ++
>>>  5 files changed, 10 insertions(+), 1 deletion(-)
>>>
>>> diff --git a/arch/arm/boot/dts/zynq-parallella.dts b/arch/arm/boot/dts/zynq-parallella.dts
>>> index 6a5f51daa708..45228a427006 100644
>>> --- a/arch/arm/boot/dts/zynq-parallella.dts
>>> +++ b/arch/arm/boot/dts/zynq-parallella.dts
>>> @@ -35,7 +35,8 @@
>>>  
>>>  	chosen {
>>>  		bootargs = "console=ttyPS0,115200 earlyprintk root=/dev/mmcblk0p2 rootfstype=ext4 rw rootwait";
>>> -		linux,stdout-path = "/amba/serial@e0001000";
>>> +		linux,stdout-path = &uart1;
>>> +		stdout-path = &uart1;
>>
>> Given that you added aliases in the last patch, you can use that to
>> refer to the serial:
>>
>> 	stdout-path - "serial0:115200n8";
>>
>> With or without the alias you can encode the UART configuration here
>> too:
>>
>> 	stdout-path = "/amba/serial@e0001000:115200n8"
> 
> let me check this configuration if it is supported by u-boot.

I have converted Linux DTSes to this style and it is working fine.
For U-Boot DM this description is not supported.
Simon: Do you have any plan to support this new description?

Thanks,
Michal
diff mbox

Patch

diff --git a/arch/arm/boot/dts/zynq-parallella.dts b/arch/arm/boot/dts/zynq-parallella.dts
index 6a5f51daa708..45228a427006 100644
--- a/arch/arm/boot/dts/zynq-parallella.dts
+++ b/arch/arm/boot/dts/zynq-parallella.dts
@@ -35,7 +35,8 @@ 
 
 	chosen {
 		bootargs = "console=ttyPS0,115200 earlyprintk root=/dev/mmcblk0p2 rootfstype=ext4 rw rootwait";
-		linux,stdout-path = "/amba/serial@e0001000";
+		linux,stdout-path = &uart1;
+		stdout-path = &uart1;
 	};
 };
 
diff --git a/arch/arm/boot/dts/zynq-zc702.dts b/arch/arm/boot/dts/zynq-zc702.dts
index 1fc1d3911e9b..205c7c472bac 100644
--- a/arch/arm/boot/dts/zynq-zc702.dts
+++ b/arch/arm/boot/dts/zynq-zc702.dts
@@ -31,6 +31,8 @@ 
 
 	chosen {
 		bootargs = "console=ttyPS0,115200 earlyprintk";
+		linux,stdout-path = &uart1;
+		stdout-path = &uart1;
 	};
 
 	leds {
diff --git a/arch/arm/boot/dts/zynq-zc706.dts b/arch/arm/boot/dts/zynq-zc706.dts
index 850518d9b8ac..f624747719dd 100644
--- a/arch/arm/boot/dts/zynq-zc706.dts
+++ b/arch/arm/boot/dts/zynq-zc706.dts
@@ -31,6 +31,8 @@ 
 
 	chosen {
 		bootargs = "console=ttyPS0,115200 earlyprintk";
+		linux,stdout-path = &uart1;
+		stdout-path = &uart1;
 	};
 
 	usb_phy0: phy0 {
diff --git a/arch/arm/boot/dts/zynq-zed.dts b/arch/arm/boot/dts/zynq-zed.dts
index 5658bc8434de..a957159104ea 100644
--- a/arch/arm/boot/dts/zynq-zed.dts
+++ b/arch/arm/boot/dts/zynq-zed.dts
@@ -30,6 +30,8 @@ 
 
 	chosen {
 		bootargs = "console=ttyPS0,115200 earlyprintk";
+		linux,stdout-path = &uart1;
+		stdout-path = &uart1;
 	};
 
 	usb_phy0: phy0 {
diff --git a/arch/arm/boot/dts/zynq-zybo.dts b/arch/arm/boot/dts/zynq-zybo.dts
index 935a561f6aa6..e51f889f7fc7 100644
--- a/arch/arm/boot/dts/zynq-zybo.dts
+++ b/arch/arm/boot/dts/zynq-zybo.dts
@@ -30,6 +30,8 @@ 
 
 	chosen {
 		bootargs = "console=ttyPS0,115200 earlyprintk";
+		linux,stdout-path = &uart1;
+		stdout-path = &uart1;
 	};
 
 };