diff mbox

[2/5] arm64: dts: APM X-Gene SoC Ethernet device tree nodes

Message ID 1387597376-29303-3-git-send-email-isubramanian@apm.com (mailing list archive)
State New, archived
Headers show

Commit Message

Iyappan Subramanian Dec. 21, 2013, 3:42 a.m. UTC
Device tree files for APM X-Gene SoC Ethernet.

Signed-off-by: Iyappan Subramanian <isubramanian@apm.com>
Signed-off-by: Ravi Patel <rapatel@apm.com>
Signed-off-by: Keyur Chudgar <kchudgar@apm.com>
---
 arch/arm64/boot/dts/apm-mustang.dts |    8 ++++++++
 arch/arm64/boot/dts/apm-storm.dtsi  |   19 +++++++++++++++++++
 2 files changed, 27 insertions(+)

Comments

Mark Salter Jan. 24, 2014, 5:01 p.m. UTC | #1
On Fri, 2013-12-20 at 19:42 -0800, Iyappan Subramanian wrote:
> Device tree files for APM X-Gene SoC Ethernet.
> 
> Signed-off-by: Iyappan Subramanian <isubramanian@apm.com>
> Signed-off-by: Ravi Patel <rapatel@apm.com>
> Signed-off-by: Keyur Chudgar <kchudgar@apm.com>
> ---
>  arch/arm64/boot/dts/apm-mustang.dts |    8 ++++++++
>  arch/arm64/boot/dts/apm-storm.dtsi  |   19 +++++++++++++++++++
>  2 files changed, 27 insertions(+)
> 
> diff --git a/arch/arm64/boot/dts/apm-mustang.dts b/arch/arm64/boot/dts/apm-mustang.dts
> index 1247ca1..ccb2771 100644
> --- a/arch/arm64/boot/dts/apm-mustang.dts
> +++ b/arch/arm64/boot/dts/apm-mustang.dts
> @@ -17,6 +17,10 @@
>  	model = "APM X-Gene Mustang board";
>  	compatible = "apm,mustang", "apm,xgene-storm";
>  
> +        aliases {
> +                ethernet0 = &menet;
> +        };
> +
>  	chosen { };
>  
>  	memory {
> @@ -24,3 +28,7 @@
>  		reg = < 0x1 0x00000000 0x0 0x80000000 >; /* Updated by bootloader */
>  	};
>  };
> +
> +&menet {
> +        status = "ok";
> +};
> diff --git a/arch/arm64/boot/dts/apm-storm.dtsi b/arch/arm64/boot/dts/apm-storm.dtsi
> index f64f946..9c7b8cd 100644
> --- a/arch/arm64/boot/dts/apm-storm.dtsi
> +++ b/arch/arm64/boot/dts/apm-storm.dtsi
> @@ -204,5 +204,24 @@
>  			#clock-cells = <1>;
>  			clocks = <&qmlclk 0>;
>  		};
> +
> +		menet: ethernet@17020000 {
> +			compatible = "apm,xgene-enet";
> +			status = "disabled";
> +			reg = <0x0 0x17020000 0x0 0x30>,
> +			      <0x0 0x17020000 0x0 0x10000>,
> +			      <0x0 0x17020000 0x0 0x20>;
> +			slave-name = "RGMII";
> +			interrupts = <0x0 0x38 0x4>,
> +				     <0x0 0x39 0x4>,
> +				     <0x0 0x3a 0x4>;
> +			#clock-cells = <1>;
> +			clocks = <&eth8clk 0>;
> +			local-mac-address = <0x0 0x11 0x3a 0x8a 0x5a 0x78>;

Shouldn't this be a byte string?:

			local-mac-address = [ 00 11 3a 8a 5a 78 ];

> +			max-frame-size = <0x233a>;
> +			devid = <8>;
> +			phyid = <3>;
> +			phy-mode = "rgmii";
> +		};
>  	};
>  };
Iyappan Subramanian April 11, 2014, 8:03 p.m. UTC | #2
Hi Mark,

Thanks for the review comment and I apologize for not replying sooner.

We are completely redesigning the ethernet driver to make it simple
and cleaner and will be posted shortly.

Please find my response by searching for isubrama:

Thanks,
Iyappan

On Fri, Jan 24, 2014 at 9:01 AM, Mark Salter <msalter@redhat.com> wrote:
> On Fri, 2013-12-20 at 19:42 -0800, Iyappan Subramanian wrote:
>> Device tree files for APM X-Gene SoC Ethernet.
>>
>> Signed-off-by: Iyappan Subramanian <isubramanian@apm.com>
>> Signed-off-by: Ravi Patel <rapatel@apm.com>
>> Signed-off-by: Keyur Chudgar <kchudgar@apm.com>
>> ---
>>  arch/arm64/boot/dts/apm-mustang.dts |    8 ++++++++
>>  arch/arm64/boot/dts/apm-storm.dtsi  |   19 +++++++++++++++++++
>>  2 files changed, 27 insertions(+)
>>
>> diff --git a/arch/arm64/boot/dts/apm-mustang.dts b/arch/arm64/boot/dts/apm-mustang.dts
>> index 1247ca1..ccb2771 100644
>> --- a/arch/arm64/boot/dts/apm-mustang.dts
>> +++ b/arch/arm64/boot/dts/apm-mustang.dts
>> @@ -17,6 +17,10 @@
>>       model = "APM X-Gene Mustang board";
>>       compatible = "apm,mustang", "apm,xgene-storm";
>>
>> +        aliases {
>> +                ethernet0 = &menet;
>> +        };
>> +
>>       chosen { };
>>
>>       memory {
>> @@ -24,3 +28,7 @@
>>               reg = < 0x1 0x00000000 0x0 0x80000000 >; /* Updated by bootloader */
>>       };
>>  };
>> +
>> +&menet {
>> +        status = "ok";
>> +};
>> diff --git a/arch/arm64/boot/dts/apm-storm.dtsi b/arch/arm64/boot/dts/apm-storm.dtsi
>> index f64f946..9c7b8cd 100644
>> --- a/arch/arm64/boot/dts/apm-storm.dtsi
>> +++ b/arch/arm64/boot/dts/apm-storm.dtsi
>> @@ -204,5 +204,24 @@
>>                       #clock-cells = <1>;
>>                       clocks = <&qmlclk 0>;
>>               };
>> +
>> +             menet: ethernet@17020000 {
>> +                     compatible = "apm,xgene-enet";
>> +                     status = "disabled";
>> +                     reg = <0x0 0x17020000 0x0 0x30>,
>> +                           <0x0 0x17020000 0x0 0x10000>,
>> +                           <0x0 0x17020000 0x0 0x20>;
>> +                     slave-name = "RGMII";
>> +                     interrupts = <0x0 0x38 0x4>,
>> +                                  <0x0 0x39 0x4>,
>> +                                  <0x0 0x3a 0x4>;
>> +                     #clock-cells = <1>;
>> +                     clocks = <&eth8clk 0>;
>> +                     local-mac-address = <0x0 0x11 0x3a 0x8a 0x5a 0x78>;
>
> Shouldn't this be a byte string?:
isubrama:
Agree.  I changed the driver.
>
>                         local-mac-address = [ 00 11 3a 8a 5a 78 ];
>
>> +                     max-frame-size = <0x233a>;
>> +                     devid = <8>;
>> +                     phyid = <3>;
>> +                     phy-mode = "rgmii";
>> +             };
>>       };
>>  };
>
>
Alex Bennée May 9, 2014, 3:29 p.m. UTC | #3
Iyappan Subramanian <isubramanian@apm.com> writes:

> Hi Mark,
>
> Thanks for the review comment and I apologize for not replying sooner.
>
> We are completely redesigning the ethernet driver to make it simple
> and cleaner and will be posted shortly.

Hi Iyappan,

Did this ever get posted? I'm trying to get a close-to-HEAD kernel up
and running on our APM hardware but have run afoul of the differences
between the latest XGENE_MBOX patch set and the older NET_XGENE patch
set.

If it's not long away then I shall wait a bit otherwise I'll see if the
missing bits can be forward ported from our working
3.8.0-mustang_sw_1.08.12-beta_rc.jcm15 kernel (purely for testing
purposes).

Do you have a public tree where your latest kernels are visible?

Cheers,

--
Alex Bennée
QEMU/KVM Hacker for Linaro
diff mbox

Patch

diff --git a/arch/arm64/boot/dts/apm-mustang.dts b/arch/arm64/boot/dts/apm-mustang.dts
index 1247ca1..ccb2771 100644
--- a/arch/arm64/boot/dts/apm-mustang.dts
+++ b/arch/arm64/boot/dts/apm-mustang.dts
@@ -17,6 +17,10 @@ 
 	model = "APM X-Gene Mustang board";
 	compatible = "apm,mustang", "apm,xgene-storm";
 
+        aliases {
+                ethernet0 = &menet;
+        };
+
 	chosen { };
 
 	memory {
@@ -24,3 +28,7 @@ 
 		reg = < 0x1 0x00000000 0x0 0x80000000 >; /* Updated by bootloader */
 	};
 };
+
+&menet {
+        status = "ok";
+};
diff --git a/arch/arm64/boot/dts/apm-storm.dtsi b/arch/arm64/boot/dts/apm-storm.dtsi
index f64f946..9c7b8cd 100644
--- a/arch/arm64/boot/dts/apm-storm.dtsi
+++ b/arch/arm64/boot/dts/apm-storm.dtsi
@@ -204,5 +204,24 @@ 
 			#clock-cells = <1>;
 			clocks = <&qmlclk 0>;
 		};
+
+		menet: ethernet@17020000 {
+			compatible = "apm,xgene-enet";
+			status = "disabled";
+			reg = <0x0 0x17020000 0x0 0x30>,
+			      <0x0 0x17020000 0x0 0x10000>,
+			      <0x0 0x17020000 0x0 0x20>;
+			slave-name = "RGMII";
+			interrupts = <0x0 0x38 0x4>,
+				     <0x0 0x39 0x4>,
+				     <0x0 0x3a 0x4>;
+			#clock-cells = <1>;
+			clocks = <&eth8clk 0>;
+			local-mac-address = <0x0 0x11 0x3a 0x8a 0x5a 0x78>;
+			max-frame-size = <0x233a>;
+			devid = <8>;
+			phyid = <3>;
+			phy-mode = "rgmii";
+		};
 	};
 };