]> git.baikalelectronics.ru Git - kernel.git/commitdiff
net: mvpp2: set 802.3x GoP Flow Control mode
authorStefan Chulski <stefanc@marvell.com>
Thu, 11 Feb 2021 10:49:01 +0000 (12:49 +0200)
committerDavid S. Miller <davem@davemloft.net>
Thu, 11 Feb 2021 22:50:24 +0000 (14:50 -0800)
This patch fix GMAC TX flow control autoneg.
Flow control autoneg wrongly were disabled with enabled TX
flow control.

Signed-off-by: Stefan Chulski <stefanc@marvell.com>
Acked-by: Marcin Wojtas <mw@semihalf.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c

index 9aa2165960cde2d836d79e2d9e35799959756095..886934f186d9c5c57d20e558a0770616038566f0 100644 (file)
@@ -6284,7 +6284,7 @@ static void mvpp2_gmac_config(struct mvpp2_port *port, unsigned int mode,
        old_ctrl4 = ctrl4 = readl(port->base + MVPP22_GMAC_CTRL_4_REG);
 
        ctrl0 &= ~MVPP2_GMAC_PORT_TYPE_MASK;
-       ctrl2 &= ~(MVPP2_GMAC_INBAND_AN_MASK | MVPP2_GMAC_PCS_ENABLE_MASK);
+       ctrl2 &= ~(MVPP2_GMAC_INBAND_AN_MASK | MVPP2_GMAC_PCS_ENABLE_MASK | MVPP2_GMAC_FLOW_CTRL_MASK);
 
        /* Configure port type */
        if (phy_interface_mode_is_8023z(state->interface)) {