summaryrefslogtreecommitdiffstats
path: root/drivers/net/fec.h
diff options
context:
space:
mode:
authorShawn Guo <shawn.guo@freescale.com>2011-01-05 21:13:13 +0000
committerDavid S. Miller <davem@davemloft.net>2011-01-09 15:42:56 -0800
commitb5680e0b591f2701c5ba7d5fc8f96b55414073c8 (patch)
tree393a02162339aba1c10e6c558b078d82bf6cef96 /drivers/net/fec.h
parentbcc67771ed8ee31cc1f2b1e033ae822b40c72ff9 (diff)
downloadtalos-op-linux-b5680e0b591f2701c5ba7d5fc8f96b55414073c8.tar.gz
talos-op-linux-b5680e0b591f2701c5ba7d5fc8f96b55414073c8.zip
net/fec: add dual fec support for mx28
This patch is to add mx28 dual fec support. Here are some key notes for mx28 fec controller. - The mx28 fec controller naming ENET-MAC is a different IP from FEC used on other i.mx variants. But they are basically compatible on software interface, so it's possible to share the same driver. - ENET-MAC design on mx28 made an improper assumption that it runs on a big-endian system. As the result, driver has to swap every frame going to and coming from the controller. - The external phys can only be configured by fec0, which means fec1 can not work independently and both phys need to be configured by mii_bus attached on fec0. - ENET-MAC reset will get mac address registers reset too. - ENET-MAC MII/RMII mode and 10M/100M speed are configured differently FEC. - ETHER_EN bit must be set to get ENET-MAC interrupt work. Signed-off-by: Shawn Guo <shawn.guo@freescale.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/fec.h')
-rw-r--r--drivers/net/fec.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/net/fec.h b/drivers/net/fec.h
index 2c48b25668d5..ace318df4c8d 100644
--- a/drivers/net/fec.h
+++ b/drivers/net/fec.h
@@ -14,7 +14,8 @@
/****************************************************************************/
#if defined(CONFIG_M523x) || defined(CONFIG_M527x) || defined(CONFIG_M528x) || \
- defined(CONFIG_M520x) || defined(CONFIG_M532x) || defined(CONFIG_ARCH_MXC)
+ defined(CONFIG_M520x) || defined(CONFIG_M532x) || \
+ defined(CONFIG_ARCH_MXC) || defined(CONFIG_SOC_IMX28)
/*
* Just figures, Motorola would have to change the offsets for
* registers in the same peripheral device on different models
@@ -78,7 +79,7 @@
/*
* Define the buffer descriptor structure.
*/
-#ifdef CONFIG_ARCH_MXC
+#if defined(CONFIG_ARCH_MXC) || defined(CONFIG_SOC_IMX28)
struct bufdesc {
unsigned short cbd_datlen; /* Data length */
unsigned short cbd_sc; /* Control and status info */
OpenPOWER on IntegriCloud