Skip to content

Commit

Permalink
dpaa_eth: fix pause capability advertisement logic
Browse files Browse the repository at this point in the history
The ADVERTISED_Asym_Pause bit was being improperly set when both
rx and tx pause were enabled. When rx and tx are both enabled, only
the ADVERTISED_Pause bit is supposed to be set.

Signed-off-by: Jake Moroni <mail@jakemoroni.com>
Acked-by: Madalin Bucur <madalin.bucur@nxp.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Jake Moroni authored and David S. Miller committed Feb 19, 2018
1 parent 607ea03 commit 3021efb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/net/ethernet/freescale/dpaa/dpaa_ethtool.c
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ static int dpaa_set_pauseparam(struct net_device *net_dev,
if (epause->rx_pause)
newadv = ADVERTISED_Pause | ADVERTISED_Asym_Pause;
if (epause->tx_pause)
newadv |= ADVERTISED_Asym_Pause;
newadv ^= ADVERTISED_Asym_Pause;

oldadv = phydev->advertising &
(ADVERTISED_Pause | ADVERTISED_Asym_Pause);
Expand Down

0 comments on commit 3021efb

Please sign in to comment.