aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/ethernet')
-rw-r--r--drivers/net/ethernet/amd/xgbe/xgbe-dev.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/ethernet/amd/xgbe/xgbe-dev.c b/drivers/net/ethernet/amd/xgbe/xgbe-dev.c
index acde00c8fdb4..6d0207eac265 100644
--- a/drivers/net/ethernet/amd/xgbe/xgbe-dev.c
+++ b/drivers/net/ethernet/amd/xgbe/xgbe-dev.c
@@ -348,7 +348,7 @@ static int xgbe_disable_tx_flow_control(struct xgbe_prv_data *pdata)
348 348
349 /* Clear MAC flow control */ 349 /* Clear MAC flow control */
350 max_q_count = XGMAC_MAX_FLOW_CONTROL_QUEUES; 350 max_q_count = XGMAC_MAX_FLOW_CONTROL_QUEUES;
351 q_count = min_t(unsigned int, pdata->rx_q_count, max_q_count); 351 q_count = min_t(unsigned int, pdata->tx_q_count, max_q_count);
352 reg = MAC_Q0TFCR; 352 reg = MAC_Q0TFCR;
353 for (i = 0; i < q_count; i++) { 353 for (i = 0; i < q_count; i++) {
354 reg_val = XGMAC_IOREAD(pdata, reg); 354 reg_val = XGMAC_IOREAD(pdata, reg);
@@ -373,7 +373,7 @@ static int xgbe_enable_tx_flow_control(struct xgbe_prv_data *pdata)
373 373
374 /* Set MAC flow control */ 374 /* Set MAC flow control */
375 max_q_count = XGMAC_MAX_FLOW_CONTROL_QUEUES; 375 max_q_count = XGMAC_MAX_FLOW_CONTROL_QUEUES;
376 q_count = min_t(unsigned int, pdata->rx_q_count, max_q_count); 376 q_count = min_t(unsigned int, pdata->tx_q_count, max_q_count);
377 reg = MAC_Q0TFCR; 377 reg = MAC_Q0TFCR;
378 for (i = 0; i < q_count; i++) { 378 for (i = 0; i < q_count; i++) {
379 reg_val = XGMAC_IOREAD(pdata, reg); 379 reg_val = XGMAC_IOREAD(pdata, reg);