]> git.kernelconcepts.de Git - karo-tx-uboot.git/commitdiff
add CONFIG_SYS_FEC_FULL_MII for MCF5445x
authorWolfgang Wegner <w.wegner@astro-kom.de>
Tue, 30 Mar 2010 18:19:51 +0000 (19:19 +0100)
committerTsiChung Liew <tsicliew@gmail.com>
Fri, 28 May 2010 07:15:57 +0000 (02:15 -0500)
This patch adds support for full MII interface on MCF5445x (in contrast
to RMII as used on the evaluation boards).

Signed-off-by: Wolfgang Wegner <w.wegner at astro-kom.de>
arch/m68k/cpu/mcf5445x/cpu_init.c

index e2a1293cac498382f9f995ba4fb985c8e287d7d7..fdcd18585d9e41d4aa993165ed9ef629e5d87d1c 100644 (file)
@@ -207,10 +207,19 @@ int fecpin_setclear(struct eth_device *dev, int setclear)
                gpio->par_feci2c &=
                    ~(GPIO_PAR_FECI2C_MDC0_MDC0 | GPIO_PAR_FECI2C_MDIO0_MDIO0);
 
-               if (info->iobase == CONFIG_SYS_FEC0_IOBASE)
+               if (info->iobase == CONFIG_SYS_FEC0_IOBASE) {
+#ifdef CONFIG_SYS_FEC_FULL_MII
+                       gpio->par_fec |= GPIO_PAR_FEC_FEC0_MII;
+#else
                        gpio->par_fec &= GPIO_PAR_FEC_FEC0_UNMASK;
-               else
+#endif
+               } else {
+#ifdef CONFIG_SYS_FEC_FULL_MII
+                       gpio->par_fec |= GPIO_PAR_FEC_FEC1_MII;
+#else
                        gpio->par_fec &= GPIO_PAR_FEC_FEC1_UNMASK;
+#endif
+               }
        }
        return 0;
 }