mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
synced 2025-01-18 06:15:12 +00:00
net: dsa: b53: Improve flow control setup on BCM5301x
According to the Broadcom's reference driver flow control needs to be enabled for any CPU switch port (5, 7 or 8 - depending on which one is used). Current code makes it work only for the port 5. Use dsa_is_cpu_port() which solved that problem. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> Reviewed-by: Florian Fainelli <f.fainelli@gmail.com> Tested-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
parent
b290c6384a
commit
3ff26b2923
@ -1222,7 +1222,7 @@ static void b53_adjust_link(struct dsa_switch *ds, int port,
|
|||||||
return;
|
return;
|
||||||
|
|
||||||
/* Enable flow control on BCM5301x's CPU port */
|
/* Enable flow control on BCM5301x's CPU port */
|
||||||
if (is5301x(dev) && port == dev->cpu_port)
|
if (is5301x(dev) && dsa_is_cpu_port(ds, port))
|
||||||
tx_pause = rx_pause = true;
|
tx_pause = rx_pause = true;
|
||||||
|
|
||||||
if (phydev->pause) {
|
if (phydev->pause) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user