diff mbox

[U-Boot,PATCHv4,3/3] ARM64: poplar: hi3798cv200: u-boot support for Poplar 96Boards

Message ID 60eaa472-2a4d-8cf0-c2d1-7111b9644549@linaro.org
State Not Applicable
Delegated to: Tom Rini
Headers show

Commit Message

Jorge Ramirez May 26, 2017, 7:46 a.m. UTC
On 05/26/2017 09:28 AM, Jorge Ramirez wrote:
>>>>>
>>>>> [1] 
>>>>> https://github.com/ldts/poplar-u-boot/blob/upstream/arch/arm/dts/hi3798cv200-u-boot.dtsi 
>>>>>
>>>> Yes, sorry.  [1] needs to be updated to disable uart0 so that you can
>>>> use platform data, at least for now.  I do want to talk more with Rob
>>>> about the general problem this exposes.
>>> so you want me to
>>>
>>> 1) keep the node in 
>>> https://github.com/ldts/poplar-u-boot/blob/upstream/arch/arm/dts/hi3798cv200-u-boot.dtsi 
>>>
>> Well, a uart0 node, but no "clock" property as that just needs to go
>> away.
>
> Sounds good to me. now see below
>
>>
>>> 2) add status=disable
>>> 3) then add the platform_data
>>>
>>> BUT for the pl011 driver to take the platform_data dont I also have
>>> to disable CONFIG_OF?
>>>
>>> but  if I disable CONFIG_OF then I lose USB_DM
>> No, the status = "disable" on uart0 should remove it from the dtb, or at
>> least we should see it and go "Oh, no, we don't have uart0 via DT".
>>
>
>
> 1) Since the UART0 is enabled in the kernel's DTS I will have to 
> modify the device tree that I am importing from kernel.org to disable it.
>
> 2) But even doing this is not enough: I have to completely remove the 
> uart0 node from the tree.
>
>
> So to sum up:
>
> In order to get the platform data for pl01x I have to either disable 
> OF (so I lose the USB node as I said earlier) or *completely* remove 
> the UART0 node from from the kernel dts.
> I personally would rather not modify the kernel's DTS trees that I am 
> importing into uboot but I am really confused about the policy now.

ie: to be clear from my side, doing the following is not enough:




Is this the right way to go then? alter the kernel DTS when merging into 
uboot?

>
> please could you clarify?
>
> I still think what I proposed when we started is the better way to go: 
> a uboot specific hi3798cv200-u-boot.dtsifile that contains the two 
> nodes that are giving trouble.
>
> The timeline then goes:
> - the usb node will disappear as soon as it lands in korg
> - the uart node and the whole file will be removed during the cleanup 
> of all the pl01x uart offenders.
>
> but if you think modifying the kernels dts is better I can do that as 
> well.
diff mbox

Patch

diff --git a/arch/arm/dts/hi3798cv200-poplar.dts 
b/arch/arm/dts/hi3798cv200-poplar.dts
index b914287..d4ce16d 100644
--- a/arch/arm/dts/hi3798cv200-poplar.dts
+++ b/arch/arm/dts/hi3798cv200-poplar.dts
@@ -152,7 +152,7 @@ 
  };

  &uart0 {
-   status = "okay";
+ status = "disabled";
  };


I have to actually do

diff --git a/arch/arm/dts/hi3798cv200-poplar.dts 
b/arch/arm/dts/hi3798cv200-poplar.dts
index b914287..028013f 100644
--- a/arch/arm/dts/hi3798cv200-poplar.dts
+++ b/arch/arm/dts/hi3798cv200-poplar.dts
@@ -17,7 +17,6 @@ 
         compatible = "hisilicon,hi3798cv200-poplar", 
"hisilicon,hi3798cv200";

         aliases {
-           serial0 = &uart0;
                 serial2 = &uart2;
         };

@@ -151,12 +150,9 @@ 
         label = "LS-SPI0";
  };

-&uart0 {
-   status = "okay";
-};

  &uart2 {
         status = "okay";
         label = "LS-UART0";
  };


OR

[jramirez@titan git.u-boot (upstream *$)]$ git diff
diff --git a/arch/arm/dts/hi3798cv200-poplar.dts 
b/arch/arm/dts/hi3798cv200-poplar.dts
index b914287..5d909b83 100644
--- a/arch/arm/dts/hi3798cv200-poplar.dts
+++ b/arch/arm/dts/hi3798cv200-poplar.dts
@@ -21,10 +21,6 @@ 
                 serial2 = &uart2;
         };

-   chosen {
-           stdout-path = "serial0:115200n8";
-   };
-
         memory@0 {
                 device_type = "memory";
                 reg = <0x0 0x0 0x0 0x80000000>;
@@ -152,7 +148,7 @@ 
  };

  &uart0 {
-   status = "okay";
+ status = "disabled";
  };

  &uart2 {