diff options
author | Eric Nelson <eric.nelson@boundarydevices.com> | 2012-12-13 11:10:55 -0700 |
---|---|---|
committer | Justin Waters <justin.waters@timesys.com> | 2013-11-07 12:19:30 -0500 |
commit | c6c3fa4e1f45e70e59b215c1385db028d4942787 (patch) | |
tree | 32f8a2f4036877a32f365cd5ffeac07f9507ab25 /drivers | |
parent | a753ce79aaaa8bf15f91d8025888a64b1614718c (diff) |
fec: tune RSEM and RSFL values for tapeout 1.0
Signed-off-by: Eric Nelson <eric.nelson@boundarydevices.com>
Signed-off-by: Christian Hemp <c.hemp@phytec.de>
Diffstat (limited to 'drivers')
-rwxr-xr-x | 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 8840e7d6f721..ec7b0895ba99 100755 --- a/drivers/net/fec.c +++ b/drivers/net/fec.c @@ -163,7 +163,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 @@ -1771,11 +1773,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); |