diff options
author | Eric Nelson <eric.nelson@boundarydevices.com> | 2012-12-13 11:10:55 -0700 |
---|---|---|
committer | Eric Nelson <eric.nelson@boundarydevices.com> | 2012-12-13 11:12:37 -0700 |
commit | 5b153d52c09d8cf35014d410bb7aec7462a6209c (patch) | |
tree | 799e9da08612c8f50cac585b488e2437bd5c9d2a | |
parent | 23f8463da111a5d0f151cb233d5259d280e44a53 (diff) |
fec: tune RSEM and RSFL values for tapeout 1.0
Signed-off-by: Eric Nelson <eric.nelson@boundarydevices.com>
-rw-r--r-- | drivers/net/fec.c | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/drivers/net/fec.c b/drivers/net/fec.c index ff967e578e91..437718890e65 100644 --- a/drivers/net/fec.c +++ b/drivers/net/fec.c @@ -159,7 +159,9 @@ MODULE_PARM_DESC(macaddr, "FEC Ethernet MAC address"); /* Pause frame feild and FIFO threshold */ #define FEC_ENET_FCE (1 << 5) #define FEC_ENET_RSEM_V 0x84 +#define FEC_ENET_RSEM_V_TO1 0x10 #define FEC_ENET_RSFL_V 16 +#define FEC_ENET_RSFL_V_TO1 0x20 #define FEC_ENET_RAEM_V 0x8 #define FEC_ENET_RAFL_V 0x8 #define FEC_ENET_OPD_V 0xFFF0 @@ -1705,11 +1707,18 @@ fec_restart(struct net_device *dev, int duplex) * The issue has been fixed on Rigel TO1.1 and Arik TO1.2 */ if (cpu_is_mx6q() || (cpu_is_mx6dl() - && (mx6dl_revision() >= IMX_CHIP_REVISION_1_1))) - rsem_val = FEC_ENET_RSEM_V; + && (mx6dl_revision() >= IMX_CHIP_REVISION_1_1))) { + if (cpu_is_mx6q() && (mx6q_revision() < IMX_CHIP_REVISION_1_1)) { + rsem_val = FEC_ENET_RSEM_V_TO1; + } else + rsem_val = FEC_ENET_RSEM_V; + } writel(rsem_val, fep->hwp + FEC_R_FIFO_RSEM); - writel(FEC_ENET_RSFL_V, fep->hwp + FEC_R_FIFO_RSFL); + if (cpu_is_mx6q() && (mx6q_revision() < IMX_CHIP_REVISION_1_1)) + writel(FEC_ENET_RSFL_V_TO1, fep->hwp + FEC_R_FIFO_RSFL); + else + writel(FEC_ENET_RSFL_V, fep->hwp + FEC_R_FIFO_RSFL); writel(FEC_ENET_RAEM_V, fep->hwp + FEC_R_FIFO_RAEM); writel(FEC_ENET_RAFL_V, fep->hwp + FEC_R_FIFO_RAFL); |