aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/ethernet/ti/keystone_ethss2.c')
-rw-r--r--drivers/net/ethernet/ti/keystone_ethss2.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/drivers/net/ethernet/ti/keystone_ethss2.c b/drivers/net/ethernet/ti/keystone_ethss2.c
index bfd3382354d..df4e21568ad 100644
--- a/drivers/net/ethernet/ti/keystone_ethss2.c
+++ b/drivers/net/ethernet/ti/keystone_ethss2.c
@@ -63,6 +63,7 @@
63#define GMACSL_RET_WARN_RESET_INCOMPLETE -2 63#define GMACSL_RET_WARN_RESET_INCOMPLETE -2
64 64
65#define CPSW2_NUM_PORTS 9 65#define CPSW2_NUM_PORTS 9
66#define CPSW_CTL_P0_TX_CRC_REMOVE BIT(13)
66#define CPSW2_CTL_P0_ENABLE BIT(2) 67#define CPSW2_CTL_P0_ENABLE BIT(2)
67#define CPSW2_CTL_VLAN_AWARE BIT(1) 68#define CPSW2_CTL_VLAN_AWARE BIT(1)
68#define CPSW2_REG_VAL_STAT_ENABLE_ALL(x) ((1 << (x)) - 1) 69#define CPSW2_REG_VAL_STAT_ENABLE_ALL(x) ((1 << (x)) - 1)
@@ -3391,6 +3392,9 @@ static int cpsw2_open(void *intf_priv, struct net_device *ndev)
3391 CPSW2_MAJOR_VERSION(reg), CPSW2_MINOR_VERSION(reg), 3392 CPSW2_MAJOR_VERSION(reg), CPSW2_MINOR_VERSION(reg),
3392 CPSW2_RTL_VERSION(reg), CPSW2_SGMII_IDENT(reg)); 3393 CPSW2_RTL_VERSION(reg), CPSW2_SGMII_IDENT(reg));
3393 3394
3395 /* Use CPSW_NU P0 TX crc remove capability to remove FCS */
3396 netcp->hw_capabilities |= CPSW_HAS_P0_TX_CRC_REMOVE;
3397
3394 ret = netcp_txpipe_open(&cpsw_intf->tx_pipe); 3398 ret = netcp_txpipe_open(&cpsw_intf->tx_pipe);
3395 if (ret) 3399 if (ret)
3396 goto txpipe_fail; 3400 goto txpipe_fail;
@@ -3436,7 +3440,8 @@ static int cpsw2_open(void *intf_priv, struct net_device *ndev)
3436 writel(0, &cpsw_dev->regs->ptype); 3440 writel(0, &cpsw_dev->regs->ptype);
3437 3441
3438 /* Control register */ 3442 /* Control register */
3439 writel(CPSW2_CTL_P0_ENABLE, &cpsw_dev->regs->control); 3443 __raw_writel(CPSW2_CTL_P0_ENABLE | CPSW_CTL_P0_TX_CRC_REMOVE,
3444 &cpsw_dev->regs->control);
3440 3445
3441 /* All statistics enabled by default */ 3446 /* All statistics enabled by default */
3442 writel(CPSW2_REG_VAL_STAT_ENABLE_ALL(cpsw_dev->num_slaves + 1), 3447 writel(CPSW2_REG_VAL_STAT_ENABLE_ALL(cpsw_dev->num_slaves + 1),