net: stmmac: Set MAC's flow control register to reflect current settings
Subsystems (4)
PATCH v4 1/1 net: stmmac: Set MAC's flow control register to reflect current settings
Currently, pause frame register GMAC_RX_FLOW_CTRL_RFE is not updated correctly when 'ethtool -A <IFACE> autoneg off rx off tx off' command is issued. This fix ensures the flow control change is reflected directly in the GMAC_RX_FLOW_CTRL_RFE register.
---
V3 -> V4: Fix commit message and incorrect insertions(+) value
V2 -> V3: Removed value assign for 'flow' in else statement based on review comments V1 -> V2: Removed needless condition based on review comments
drivers/net/ethernet/stmicro/stmmac/dwmac4_core.c | 2 ++ drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 12 ++++++++++-- 2 files changed, 12 insertions(+), 2 deletions(-)
drivers/net/ethernet/stmicro/stmmac/dwmac4_core.c +2 -0
@@ -748,6 +748,8 @@ static void dwmac4_flow_ctrl(struct mac_device_info *hw, unsigned int duplex,if (fc &FLOW_RX ) {pr_debug ("\tReceive Flow-Control ON\n" ); flow |=GMAC_RX_FLOW_CTRL_RFE ; + }else { +pr_debug ("\tReceive Flow-Control OFF\n" ); }writel (flow, ioaddr +GMAC_RX_FLOW_CTRL );
drivers/net/ethernet/stmicro/stmmac/stmmac_main.c +10 -2
@@ -1061,8 +1061,16 @@ static void stmmac_mac_link_up(struct phylink_config *config, ctrl |= priv->hw->link.duplex;/* Flow Control operation */ -if (tx_pause && rx_pause) -stmmac_mac_flow_ctrl (priv, duplex); +if (rx_pause && tx_pause) + priv->flow_ctrl =FLOW_AUTO ; +else if (rx_pause && !tx_pause) + priv->flow_ctrl =FLOW_RX ; +else if (!rx_pause && tx_pause) + priv->flow_ctrl =FLOW_TX ; +else + priv->flow_ctrl =FLOW_OFF ; + +stmmac_mac_flow_ctrl (priv, duplex);if (ctrl != old_ctrl)writel (ctrl, priv->ioaddr +MAC_CTRL_REG );
Signature · 7 lines
2.17.1 _______________________________________________ linux-arm-kernel mailing list [email protected] http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
This patch was applied to netdev/net.git (master) by David S. Miller <[email protected]>:
Hello:
This patch was applied to netdev/net.git (master)
by David S. Miller <[email protected]>:
Quoted 11 lines · On Wed, 23 Nov 2022 18:51:10 +0800 you wrote:
Currently, pause frame register
GMAC_RX_FLOW_CTRL_RFEis not updated correctly when 'ethtool -A <IFACE> autoneg off rx off tx off' command is issued. This fix ensures the flow control change is reflected directly in theGMAC_RX_FLOW_CTRL_RFEregister.Fixes 46f69ded988d ("net: stmmac: Use resolved link config in mac_link_up()")Cc <[email protected]> # 5.10.xSigned-off-by Goh, Wei Sheng <[email protected]>Signed-off-by Noor Azura Ahmad Tarmizi <[email protected]>[...]
Here is the summary with links:
- [net,v4] net: stmmac: Set MAC's flow control register to reflect current settings
https://git.kernel.org/netdev/net/c/cc3d2b5fc0d6
You are awesome, thank you!
Signature · 2 lines
Deet-doot-dot, I am a bot. https://korg.docs.kernel.org/patchwork/pwbot.html
From: "Goh, Wei Sheng" <[email protected]>
Date: Wed, 23 Nov 2022 18:51:10 +0800
Quoted 4 lines
Currently, pause frame register
GMAC_RX_FLOW_CTRL_RFEis not updated correctly when 'ethtool -A <IFACE> autoneg off rx off tx off' command is issued. This fix ensures the flow control change is reflected directly in theGMAC_RX_FLOW_CTRL_RFEregister.
Any particular reason why you completely ignored by review comments to the v3[0]? I'd like to see them fixed or at least replied.
Quoted 13 lines
Fixes 46f69ded988d ("net: stmmac: Use resolved link config in mac_link_up()")Cc <[email protected]> # 5.10.xSigned-off-by Goh, Wei Sheng <[email protected]>Signed-off-by Noor Azura Ahmad Tarmizi <[email protected]>---
V3 -> V4: Fix commit message and incorrect insertions(+) value
V2 -> V3: Removed value assign for 'flow' in else statement based on review comments V1 -> V2: Removed needless condition based on review commentsdrivers/net/ethernet/stmicro/stmmac/dwmac4_core.c | 2 ++ drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 12 ++++++++++-- 2 files changed, 12 insertions(+), 2 deletions(-)
[...]
Quoted 2 lines
Signature · 1 line
2.17.1
[0] https://lore.kernel.org/netdev/[email protected]
Thanks,
Olek
Hi,
Quoted 49 lines
-----Original Message-----
From: Lobakin, Alexandr <[email protected]>
Sent: Saturday, 26 November, 2022 12:02 AM
To: Goh, Wei Sheng <[email protected]>
Cc: Lobakin, Alexandr <[email protected]>; Giuseppe Cavallaro <[email protected]>; Alexandre Torgue <[email protected]>; Jose Abreu <[email protected]>; David S . Miller <[email protected]>; Eric Dumazet <[email protected]>; Jakub Kicinski <[email protected]>; Paolo Abeni <[email protected]>; Maxime Coquelin <[email protected]>; [email protected]; linux-stm32@st-md- mailman.stormreply.com; [email protected]; linux- [email protected]; Alexandre Torgue <[email protected]>; Ong, Boon Leong <[email protected]>; Voon, Weifeng <[email protected]>; Tan, Tee Min <[email protected]>; Ahmad Tarmizi, Noor Azura <[email protected]>; Looi, Hong Aun <[email protected]>
Subject: Re: [PATCH net v4] net: stmmac: Set MAC's flow control register to reflect current settingsFrom: "Goh, Wei Sheng" <[email protected]>
Date: Wed, 23 Nov 2022 18:51:10 +0800Quoted 4 lines
Currently, pause frame register
GMAC_RX_FLOW_CTRL_RFEis not updated correctly when 'ethtool -A <IFACE> autoneg off rx off tx off' command is issued. This fix ensures the flow control change is reflected directly in theGMAC_RX_FLOW_CTRL_RFEregister.Any particular reason why you completely ignored by review comments to the v3[0]? I'd like to see them fixed or at least replied.
Quoted 16 lines
Fixes 46f69ded988d ("net: stmmac: Use resolved link config in
mac_link_up()")Cc <[email protected]> # 5.10.xSigned-off-by Goh, Wei Sheng <[email protected]>Signed-off-by Noor Azura Ahmad Tarmizi<[email protected]>
---
V3 -> V4: Fix commit message and incorrect insertions(+) value V2 -> V3: Removed value assign for 'flow' in else statement based on review comments
V1 -> V2: Removed needless condition based on review commentsdrivers/net/ethernet/stmicro/stmmac/dwmac4_core.c | 2 ++ drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 12 ++++++++++-- 2 files changed, 12 insertions(+), 2 deletions(-)[...]
Quoted 8 lines
Quoted 2 lines
--
2.17.1[0] https://lore.kernel.org/netdev/20221123180947.488302-1-
[email protected]Thanks,
Olek
Due to v4 is being accepted. Therefore I will submit a new patch to address your review comments. Thanks and appreciate your effort for reviewing my patch.
Quoted 7 lines · Wei Sheng
Hi,
Quoted 5 lines
-----Original Message-----
From: Lobakin, Alexandr <[email protected]>
Any particular reason why you completely ignored by review comments to the v3[0]? I'd like to see them fixed or at least replied.
Quoted 8 lines
Quoted 5 lines
[0] https://lore.kernel.org/netdev/20221123180947.488302-1-
[email protected]Thanks,
OlekDue to v4 is being accepted. Therefore I will submit a new patch to address your review comments. Thanks and appreciate your effort for reviewing my patch.
And on that very same subject, why did you ignore my review comments on v2?
Signature · 2 lines
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/ FTTP is here! 40Mbps down 10Mbps up. Decent connectivity at last!
Hi,
Quoted 36 lines
-----Original Message-----
From: Russell King <[email protected]>
Sent: Saturday, 3 December, 2022 1:24 AM
To: Goh, Wei Sheng <[email protected]>
Cc: Lobakin, Alexandr <[email protected]>; Giuseppe Cavallaro <[email protected]>; Alexandre Torgue <[email protected]>; Jose Abreu <[email protected]>; David S . Miller <[email protected]>; Eric Dumazet <[email protected]>; Jakub Kicinski <[email protected]>; Paolo Abeni <[email protected]>; Maxime Coquelin <[email protected]>; [email protected]; linux- [email protected]; linux-arm- [email protected]; [email protected]; Alexandre Torgue <[email protected]>; Ong, Boon Leong <[email protected]>; Voon, Weifeng <[email protected]>; Tan, Tee Min <[email protected]>; Ahmad Tarmizi, Noor Azura <[email protected]>; Looi, Hong Aun <[email protected]>
Subject: Re: [PATCH net v4] net: stmmac: Set MAC's flow control register to reflect current settingsQuoted 7 lines · Wei Sheng
Hi,
Quoted 5 lines
-----Original Message-----
From: Lobakin, Alexandr <[email protected]> Any particular reason why you completely ignored by review comments to the v3[0]? I'd like to see them fixed or at least replied.Quoted 7 lines
Quoted 5 lines
[0] https://lore.kernel.org/netdev/20221123180947.488302-1-
[email protected]Thanks,
OlekDue to v4 is being accepted. Therefore I will submit a new patch to address
your review comments.
Quoted 8 lines
Quoted 1 line
Thanks and appreciate your effort for reviewing my patch.
And on that very same subject, why did you ignore my review comments on v2?
--
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTP is here! 40Mbps down 10Mbps up. Decent connectivity at last!
Sorry I missed some of your comment. Will try to address them in the next submission. Also thanks and appreciate your effort for reviewing my patch.