diff options
author | Maxime Ripard <maxime.ripard@free-electrons.com> | 2012-10-06 22:36:28 -0400 |
---|---|---|
committer | Shawn Guo <shawn.guo@linaro.org> | 2012-10-15 03:44:39 -0400 |
commit | 8eec4b3117405e5561d2c65c9222cf3334c0ca3a (patch) | |
tree | 1c1f223dc3dd5b1981a1d11ff1d4947deba2951f | |
parent | 098e7522896c0d0fe5264124949626df44520f57 (diff) |
ARM: dts: cfa10049: Add FEC to the CFA-10049 expansion board
Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
-rw-r--r-- | arch/arm/boot/dts/imx28-cfa10049.dts | 11 | ||||
-rw-r--r-- | arch/arm/mach-mxs/mach-mxs.c | 14 |
2 files changed, 25 insertions, 0 deletions
diff --git a/arch/arm/boot/dts/imx28-cfa10049.dts b/arch/arm/boot/dts/imx28-cfa10049.dts index 05c892e931e..a34676f9f40 100644 --- a/arch/arm/boot/dts/imx28-cfa10049.dts +++ b/arch/arm/boot/dts/imx28-cfa10049.dts | |||
@@ -96,4 +96,15 @@ | |||
96 | gpio = <&gpio0 7 1>; | 96 | gpio = <&gpio0 7 1>; |
97 | }; | 97 | }; |
98 | }; | 98 | }; |
99 | |||
100 | ahb@80080000 { | ||
101 | mac0: ethernet@800f0000 { | ||
102 | phy-mode = "rmii"; | ||
103 | pinctrl-names = "default"; | ||
104 | pinctrl-0 = <&mac0_pins_a>; | ||
105 | phy-reset-gpios = <&gpio2 21 0>; | ||
106 | phy-reset-duration = <100>; | ||
107 | status = "okay"; | ||
108 | }; | ||
109 | }; | ||
99 | }; | 110 | }; |
diff --git a/arch/arm/mach-mxs/mach-mxs.c b/arch/arm/mach-mxs/mach-mxs.c index 4748ec551a6..b8c452a1b0a 100644 --- a/arch/arm/mach-mxs/mach-mxs.c +++ b/arch/arm/mach-mxs/mach-mxs.c | |||
@@ -160,6 +160,7 @@ static struct sys_timer imx28_timer = { | |||
160 | enum mac_oui { | 160 | enum mac_oui { |
161 | OUI_FSL, | 161 | OUI_FSL, |
162 | OUI_DENX, | 162 | OUI_DENX, |
163 | OUI_CRYSTALFONTZ, | ||
163 | }; | 164 | }; |
164 | 165 | ||
165 | static void __init update_fec_mac_prop(enum mac_oui oui) | 166 | static void __init update_fec_mac_prop(enum mac_oui oui) |
@@ -205,6 +206,11 @@ static void __init update_fec_mac_prop(enum mac_oui oui) | |||
205 | macaddr[1] = 0xe5; | 206 | macaddr[1] = 0xe5; |
206 | macaddr[2] = 0x4e; | 207 | macaddr[2] = 0x4e; |
207 | break; | 208 | break; |
209 | case OUI_CRYSTALFONTZ: | ||
210 | macaddr[0] = 0x58; | ||
211 | macaddr[1] = 0xb9; | ||
212 | macaddr[2] = 0xe1; | ||
213 | break; | ||
208 | } | 214 | } |
209 | val = ocotp[i]; | 215 | val = ocotp[i]; |
210 | macaddr[3] = (val >> 16) & 0xff; | 216 | macaddr[3] = (val >> 16) & 0xff; |
@@ -355,6 +361,12 @@ static void __init tx28_post_init(void) | |||
355 | pinctrl_put(pctl); | 361 | pinctrl_put(pctl); |
356 | } | 362 | } |
357 | 363 | ||
364 | static void __init cfa10049_init(void) | ||
365 | { | ||
366 | enable_clk_enet_out(); | ||
367 | update_fec_mac_prop(OUI_CRYSTALFONTZ); | ||
368 | } | ||
369 | |||
358 | static void __init mxs_machine_init(void) | 370 | static void __init mxs_machine_init(void) |
359 | { | 371 | { |
360 | if (of_machine_is_compatible("fsl,imx28-evk")) | 372 | if (of_machine_is_compatible("fsl,imx28-evk")) |
@@ -365,6 +377,8 @@ static void __init mxs_machine_init(void) | |||
365 | m28evk_init(); | 377 | m28evk_init(); |
366 | else if (of_machine_is_compatible("bluegiga,apx4devkit")) | 378 | else if (of_machine_is_compatible("bluegiga,apx4devkit")) |
367 | apx4devkit_init(); | 379 | apx4devkit_init(); |
380 | else if (of_machine_is_compatible("crystalfontz,cfa10049")) | ||
381 | cfa10049_init(); | ||
368 | 382 | ||
369 | of_platform_populate(NULL, of_default_bus_match_table, | 383 | of_platform_populate(NULL, of_default_bus_match_table, |
370 | mxs_auxdata_lookup, NULL); | 384 | mxs_auxdata_lookup, NULL); |