Skip to content

Commit 92c03f3

Browse files
NET:ETH:ALTERA: FTile 1588PTP : Remove MAC Tx Disable/Enable in link monitor path (#241)
Software need not do a MAC TX Disable/Enable when the RxPCS goes down and comes up. Tx data path back pressuring is automatically provided by MAC control. Signed-off-by: Krishna Kumar S R <[email protected]>
1 parent aa09bdc commit 92c03f3

File tree

1 file changed

+11
-14
lines changed

1 file changed

+11
-14
lines changed

drivers/net/ethernet/altera/intel_fpga_ftile_driver.c

Lines changed: 11 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1369,19 +1369,18 @@ int ftile_init(intel_fpga_xtile_eth_private *priv)
13691369
/* Set/Config source MAC address */
13701370
ftile_update_mac_addr(priv);
13711371

1372+
/* Enable F-tile MAC datapath */
1373+
ftile_enable_mac(priv);
1374+
1375+
/* Enable flow ctrl */
1376+
ftile_enable_mac_flow_ctrl(priv);
13721377
return 0;
13731378
}
13741379

13751380
int ftile_start(intel_fpga_xtile_eth_private *priv)
13761381
{
13771382
int ret;
13781383

1379-
/* Enable F-tile MAC datapath */
1380-
ftile_enable_mac(priv);
1381-
1382-
/* Enable flow ctrl */
1383-
ftile_enable_mac_flow_ctrl(priv);
1384-
13851384
/* Enable PTP feature */
13861385
if (priv->ptp_enable) {
13871386
ret = eth_ftile_tx_rx_user_flow(priv);
@@ -1395,19 +1394,11 @@ int ftile_start(intel_fpga_xtile_eth_private *priv)
13951394
return 0;
13961395

13971396
ptp_error:
1398-
ftile_disable_mac(priv);
1399-
ftile_disable_mac_flow_ctrl(priv);
14001397
return ret;
14011398
}
14021399

14031400
int ftile_stop(intel_fpga_xtile_eth_private *priv)
14041401
{
1405-
/* Disable Ftile MAC datapath */
1406-
ftile_disable_mac(priv);
1407-
1408-
/* Disable Ftile MAC flow ctrl */
1409-
ftile_disable_mac_flow_ctrl(priv);
1410-
14111402
/* Stop UI thread */
14121403
if (priv->ptp_enable)
14131404
ftile_ui_adjustments_cancel_worker(priv);
@@ -1417,6 +1408,12 @@ int ftile_stop(intel_fpga_xtile_eth_private *priv)
14171408

14181409
int ftile_uninit(intel_fpga_xtile_eth_private *priv)
14191410
{
1411+
/* Disable Ftile MAC datapath */
1412+
ftile_disable_mac(priv);
1413+
1414+
/* Disable Ftile MAC flow ctrl */
1415+
ftile_disable_mac_flow_ctrl(priv);
1416+
14201417
/* Just to make sure Ftile feature are disabled */
14211418
return ftile_stop(priv);
14221419
}

0 commit comments

Comments
 (0)