Re: [U-Boot] [PATCH 1/6] sunxi: A64: dts: replace EMAC .dtsi with symlink

2017-07-14 Thread Simon Glass
On 7 July 2017 at 02:31, Andre Przywara  wrote:
> Hi,
>
> On 07/07/17 04:58, Simon Glass wrote:
>> Hi Andre,
>>
>> On 2 July 2017 at 18:59, Andre Przywara  wrote:
>>> Currently we add the U-Boot specific Ethernet MAC DT nodes for the
>>> Pine64 via a board-specific add-on .dtsi.
>>> However these nodes and properties in there are actually pretty generic
>>> for all A64 boards which use a PHY connected via RGMII.
>>> Rename the add-on .dtsi to reflect this and make the Pine64 .dtsi a
>>> symlink to this new file.
>>> This simplifies letting other boards use the EMAC too.
>>>
>>> Signed-off-by: Andre Przywara 
>>> ---
>>>  arch/arm/dts/sun50i-a64-pine64-plus-u-boot.dtsi | 51 
>>> +
>>>  arch/arm/dts/sun50i-a64-rgmii-emac.dtsi | 50 
>>> 
>>>  2 files changed, 51 insertions(+), 50 deletions(-)
>>>  mode change 100644 => 12 
>>> arch/arm/dts/sun50i-a64-pine64-plus-u-boot.dtsi
>>>  create mode 100644 arch/arm/dts/sun50i-a64-rgmii-emac.dtsi
>>
>> It seems odd to use the U-Boot dtsi feature to add code that should be
>> in the kernel .dts also. Can we instead just #include it?
>
> This -u-boot.dtsi was just a preliminary kludge until the official Linux
> Ethernet support was merged.
> I was hoping for getting this still into the release, since it's an easy
> change and enables TFTP boot on the two boards (this patch here is just
> preparation for the actual patch 2/6).
>
> So the Linux Ethernet driver happened to be merged yesterday. \O/
> I promise to update U-Boot's DTs with the kernel one's once we have at
> least an -rc1 in the kernel (though this requires patch 6/6 in U-Boot).
> This will then see these rgmii-emac.dtsi and the symlinks go away.

OK I see, thanks.

Reviewed-by: Simon Glass 
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


Re: [U-Boot] [PATCH 1/6] sunxi: A64: dts: replace EMAC .dtsi with symlink

2017-07-07 Thread Andre Przywara
Hi,

On 07/07/17 04:58, Simon Glass wrote:
> Hi Andre,
> 
> On 2 July 2017 at 18:59, Andre Przywara  wrote:
>> Currently we add the U-Boot specific Ethernet MAC DT nodes for the
>> Pine64 via a board-specific add-on .dtsi.
>> However these nodes and properties in there are actually pretty generic
>> for all A64 boards which use a PHY connected via RGMII.
>> Rename the add-on .dtsi to reflect this and make the Pine64 .dtsi a
>> symlink to this new file.
>> This simplifies letting other boards use the EMAC too.
>>
>> Signed-off-by: Andre Przywara 
>> ---
>>  arch/arm/dts/sun50i-a64-pine64-plus-u-boot.dtsi | 51 
>> +
>>  arch/arm/dts/sun50i-a64-rgmii-emac.dtsi | 50 
>> 
>>  2 files changed, 51 insertions(+), 50 deletions(-)
>>  mode change 100644 => 12 arch/arm/dts/sun50i-a64-pine64-plus-u-boot.dtsi
>>  create mode 100644 arch/arm/dts/sun50i-a64-rgmii-emac.dtsi
> 
> It seems odd to use the U-Boot dtsi feature to add code that should be
> in the kernel .dts also. Can we instead just #include it?

This -u-boot.dtsi was just a preliminary kludge until the official Linux
Ethernet support was merged.
I was hoping for getting this still into the release, since it's an easy
change and enables TFTP boot on the two boards (this patch here is just
preparation for the actual patch 2/6).

So the Linux Ethernet driver happened to be merged yesterday. \O/
I promise to update U-Boot's DTs with the kernel one's once we have at
least an -rc1 in the kernel (though this requires patch 6/6 in U-Boot).
This will then see these rgmii-emac.dtsi and the symlinks go away.

Cheers,
Andre.
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


Re: [U-Boot] [PATCH 1/6] sunxi: A64: dts: replace EMAC .dtsi with symlink

2017-07-06 Thread Simon Glass
Hi Andre,

On 2 July 2017 at 18:59, Andre Przywara  wrote:
> Currently we add the U-Boot specific Ethernet MAC DT nodes for the
> Pine64 via a board-specific add-on .dtsi.
> However these nodes and properties in there are actually pretty generic
> for all A64 boards which use a PHY connected via RGMII.
> Rename the add-on .dtsi to reflect this and make the Pine64 .dtsi a
> symlink to this new file.
> This simplifies letting other boards use the EMAC too.
>
> Signed-off-by: Andre Przywara 
> ---
>  arch/arm/dts/sun50i-a64-pine64-plus-u-boot.dtsi | 51 
> +
>  arch/arm/dts/sun50i-a64-rgmii-emac.dtsi | 50 
>  2 files changed, 51 insertions(+), 50 deletions(-)
>  mode change 100644 => 12 arch/arm/dts/sun50i-a64-pine64-plus-u-boot.dtsi
>  create mode 100644 arch/arm/dts/sun50i-a64-rgmii-emac.dtsi

It seems odd to use the U-Boot dtsi feature to add code that should be
in the kernel .dts also. Can we instead just #include it?

- Simon
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


[U-Boot] [PATCH 1/6] sunxi: A64: dts: replace EMAC .dtsi with symlink

2017-07-02 Thread Andre Przywara
Currently we add the U-Boot specific Ethernet MAC DT nodes for the
Pine64 via a board-specific add-on .dtsi.
However these nodes and properties in there are actually pretty generic
for all A64 boards which use a PHY connected via RGMII.
Rename the add-on .dtsi to reflect this and make the Pine64 .dtsi a
symlink to this new file.
This simplifies letting other boards use the EMAC too.

Signed-off-by: Andre Przywara 
---
 arch/arm/dts/sun50i-a64-pine64-plus-u-boot.dtsi | 51 +
 arch/arm/dts/sun50i-a64-rgmii-emac.dtsi | 50 
 2 files changed, 51 insertions(+), 50 deletions(-)
 mode change 100644 => 12 arch/arm/dts/sun50i-a64-pine64-plus-u-boot.dtsi
 create mode 100644 arch/arm/dts/sun50i-a64-rgmii-emac.dtsi

diff --git a/arch/arm/dts/sun50i-a64-pine64-plus-u-boot.dtsi 
b/arch/arm/dts/sun50i-a64-pine64-plus-u-boot.dtsi
deleted file mode 100644
index 9c61bea..000
--- a/arch/arm/dts/sun50i-a64-pine64-plus-u-boot.dtsi
+++ /dev/null
@@ -1,50 +0,0 @@
-/ {
-   aliases {
-   ethernet0 = 
-   };
-
-   soc {
-   emac: ethernet@01c3 {
-   compatible = "allwinner,sun50i-a64-emac";
-   reg = <0x01c3 0x2000>, <0x01c00030 0x4>;
-   reg-names = "emac", "syscon";
-   interrupts = ;
-   resets = < RST_BUS_EMAC>;
-   reset-names = "ahb";
-   clocks = < CLK_BUS_EMAC>;
-   clock-names = "ahb";
-   #address-cells = <1>;
-   #size-cells = <0>;
-   pinctrl-names = "default";
-   pinctrl-0 = <_pins>;
-   phy-mode = "rgmii";
-   phy = <>;
-   status = "okay";
-
-   phy1: ethernet-phy@1 {
-   reg = <1>;
-   };
-   };
-   };
-};
-
- {
-   rmii_pins: rmii_pins {
-   allwinner,pins = "PD10", "PD11", "PD13", "PD14",
-"PD17", "PD18", "PD19", "PD20",
-"PD22", "PD23";
-   allwinner,function = "emac";
-   allwinner,drive = <3>;
-   allwinner,pull = <0>;
-   };
-
-   rgmii_pins: rgmii_pins {
-   allwinner,pins = "PD8", "PD9", "PD10", "PD11",
-"PD12", "PD13", "PD15",
-"PD16", "PD17", "PD18", "PD19",
-"PD20", "PD21", "PD22", "PD23";
-   allwinner,function = "emac";
-   allwinner,drive = <3>;
-   allwinner,pull = <0>;
-   };
-};
diff --git a/arch/arm/dts/sun50i-a64-pine64-plus-u-boot.dtsi 
b/arch/arm/dts/sun50i-a64-pine64-plus-u-boot.dtsi
new file mode 12
index 000..350dc2b
--- /dev/null
+++ b/arch/arm/dts/sun50i-a64-pine64-plus-u-boot.dtsi
@@ -0,0 +1 @@
+sun50i-a64-rgmii-emac.dtsi
\ No newline at end of file
diff --git a/arch/arm/dts/sun50i-a64-rgmii-emac.dtsi 
b/arch/arm/dts/sun50i-a64-rgmii-emac.dtsi
new file mode 100644
index 000..9c61bea
--- /dev/null
+++ b/arch/arm/dts/sun50i-a64-rgmii-emac.dtsi
@@ -0,0 +1,50 @@
+/ {
+   aliases {
+   ethernet0 = 
+   };
+
+   soc {
+   emac: ethernet@01c3 {
+   compatible = "allwinner,sun50i-a64-emac";
+   reg = <0x01c3 0x2000>, <0x01c00030 0x4>;
+   reg-names = "emac", "syscon";
+   interrupts = ;
+   resets = < RST_BUS_EMAC>;
+   reset-names = "ahb";
+   clocks = < CLK_BUS_EMAC>;
+   clock-names = "ahb";
+   #address-cells = <1>;
+   #size-cells = <0>;
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins>;
+   phy-mode = "rgmii";
+   phy = <>;
+   status = "okay";
+
+   phy1: ethernet-phy@1 {
+   reg = <1>;
+   };
+   };
+   };
+};
+
+ {
+   rmii_pins: rmii_pins {
+   allwinner,pins = "PD10", "PD11", "PD13", "PD14",
+"PD17", "PD18", "PD19", "PD20",
+"PD22", "PD23";
+   allwinner,function = "emac";
+   allwinner,drive = <3>;
+   allwinner,pull = <0>;
+   };
+
+   rgmii_pins: rgmii_pins {
+   allwinner,pins = "PD8", "PD9", "PD10", "PD11",
+"PD12", "PD13", "PD15",
+"PD16", "PD17", "PD18", "PD19",
+"PD20", "PD21", "PD22", "PD23";
+   allwinner,function = "emac";
+