mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-05 18:41:58 +09:00
dpaa_eth: fix pause capability advertisement logic
[ Upstream commit 3021efb440 ]
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>
Signed-off-by: Sasha Levin <alexander.levin@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
80300e879f
commit
f0cf2575cd
@@ -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);
|
||||
|
||||
Reference in New Issue
Block a user