net: stmmac: set TxQ mode back to DCB after disabling CBS
Subsystems (4)
PATCH 1/1 net: stmmac: set TxQ mode back to DCB after disabling CBS
From: Mohammad Athari Bin Ismail <[email protected]>
When disable CBS, mode_to_use parameter is not updated even the operation mode of Tx Queue is changed to Data Centre Bridging (DCB). Therefore, when tc_setup_cbs() function is called to re-enable CBS, the operation mode of Tx Queue remains at DCB, which causing CBS fails to work.
This patch updates the value of mode_to_use parameter to MTL_QUEUE_DCB after operation mode of Tx Queue is changed to DCB in stmmac_dma_qmode() callback function.
--- drivers/net/ethernet/stmicro/stmmac/stmmac_tc.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-)
drivers/net/ethernet/stmicro/stmmac/stmmac_tc.c +6 -1
@@ -324,7 +324,12 @@ static int tc_setup_cbs(struct stmmac_priv *priv, priv->plat->tx_queues_cfg[queue].mode_to_use =MTL_QUEUE_AVB ; }else if (!qopt->enable) { -return stmmac_dma_qmode (priv, priv->ioaddr, queue,MTL_QUEUE_DCB ); + ret =stmmac_dma_qmode (priv, priv->ioaddr, queue, +MTL_QUEUE_DCB ); +if (ret) +return ret; + + priv->plat->tx_queues_cfg[queue].mode_to_use =MTL_QUEUE_DCB ; }/* Port Transmit Rate and Speed Divider */
Signature · 1 line
2.7.4
Quoted 7 lines · Song Yoong Siang
From: Mohammad Athari Bin Ismail <[email protected]>
When disable CBS,
mode_to_useparameter is not updated even the operation mode of Tx Queue is changed to Data Centre Bridging (DCB). Therefore, whentc_setup_cbs()function is called to re-enable CBS, the operation mode of Tx Queue remains at DCB, which causing CBS fails to work.
Quoted 8 lines
This patch updates the value of
mode_to_useparameter toMTL_QUEUE_DCBafter operation mode of Tx Queue is changed to DCB instmmac_dma_qmode()callback function.Fixes 1f705bc61aee ("net: stmmac: Add support for CBS QDISC")Suggested-by Gomes, Vinicius <[email protected]>Signed-off-by Mohammad Athari Bin Ismail <[email protected]>Signed-off-by Song, Yoong Siang <[email protected]>
Quoted 7 lines · Song Yoong Siang
From: Mohammad Athari Bin Ismail <[email protected]>
When disable CBS,
mode_to_useparameter is not updated even the operation mode of Tx Queue is changed to Data Centre Bridging (DCB). Therefore, whentc_setup_cbs()function is called to re-enable CBS, the operation mode of Tx Queue remains at DCB, which causing CBS fails to work.
Quoted 6 lines
This patch updates the value of
mode_to_useparameter toMTL_QUEUE_DCBafter operation mode of Tx Queue is changed to DCB instmmac_dma_qmode()callback function.Fixes 1f705bc61aee ("net: stmmac: Add support for CBS QDISC")Suggested-by Gomes, Vinicius <[email protected]>
Just a nitpick/formality, I would prefer if you used:
Quoted 2 lines
Signed-off-by Mohammad Athari Bin Ismail <[email protected]>Signed-off-by Song, Yoong Siang <[email protected]>
Patch looks good.
Cheers,
Signature · 6 lines
Vinicius _______________________________________________ linux-arm-kernel mailing list [email protected] http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
This patch was applied to netdev/net.git (refs/heads/master):
Hello:
This patch was applied to netdev/net.git (refs/heads/master):
Quoted 8 lines · On Thu, 4 Feb 2021 22:03:16 +0800 you wrote:
From: Mohammad Athari Bin Ismail <[email protected]>
When disable CBS,
mode_to_useparameter is not updated even the operation mode of Tx Queue is changed to Data Centre Bridging (DCB). Therefore, whentc_setup_cbs()function is called to re-enable CBS, the operation mode of Tx Queue remains at DCB, which causing CBS fails to work.[...]
Here is the summary with links:
- [net,1/1] net: stmmac: set TxQ mode back to DCB after disabling CBS
https://git.kernel.org/netdev/net/c/f317e2ea8c88
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
_______________________________________________
linux-arm-kernel mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel