From: Quanyang Wang <quanyang.w...@windriver.com>

In mainline commit db2f2842e6f5 ("net: stmmac: add per-queue TX & RX
coalesce ethtool support"), the argument "number_chan" of the function
"rx_watchdog" in stmmac_dma_ops has been changed to "queue", so apply
the same change to the function "dwmac4_rx_watchdog_e50082".

Signed-off-by: Quanyang Wang <quanyang.w...@windriver.com>
Signed-off-by: Zhantao Tang <zhantao.t...@windriver.com>
---
 .../net/ethernet/stmicro/stmmac/dwmac4_dma.c  | 23 +++++++++----------
 1 file changed, 11 insertions(+), 12 deletions(-)

diff --git a/drivers/net/ethernet/stmicro/stmmac/dwmac4_dma.c 
b/drivers/net/ethernet/stmicro/stmmac/dwmac4_dma.c
index f870bb025861..3f03ada8b4d7 100644
--- a/drivers/net/ethernet/stmicro/stmmac/dwmac4_dma.c
+++ b/drivers/net/ethernet/stmicro/stmmac/dwmac4_dma.c
@@ -272,22 +272,21 @@ static void dwmac4_dump_dma_regs(void __iomem *ioaddr, 
u32 *reg_space)
 
 static void dwmac4_rx_watchdog(void __iomem *ioaddr, u32 riwt, u32 queue)
 {
+
        writel(riwt, ioaddr + DMA_CHAN_RX_WATCHDOG(queue));
 }
 
-static void dwmac4_rx_watchdog_e50082(void __iomem *ioaddr, u32 riwt, u32 
number_chan)
+static void dwmac4_rx_watchdog_e50082(void __iomem *ioaddr, u32 riwt, u32 
queue)
 {
-       u32 chan, temp;
-
-       for (chan = 0; chan < number_chan; chan++) {
-               temp = readl(ioaddr + DMA_CHAN_RX_WATCHDOG(chan));
-               /* Update only RWT first */
-               temp = (temp & ~DMA_CHAN_RX_WATCHDOG_RWT) | (riwt & 
DMA_CHAN_RX_WATCHDOG_RWT);
-               writel(temp, ioaddr + DMA_CHAN_RX_WATCHDOG(chan));
-               /* Update RWTU */
-               temp = (temp & ~DMA_CHAN_RX_WATCHDOG_RWTU) | (riwt & 
DMA_CHAN_RX_WATCHDOG_RWTU);
-               writel(temp, ioaddr + DMA_CHAN_RX_WATCHDOG(chan));
-       }
+       u32 temp;
+
+       temp = readl(ioaddr + DMA_CHAN_RX_WATCHDOG(queue));
+       /* Update only RWT first */
+       temp = (temp & ~DMA_CHAN_RX_WATCHDOG_RWT) | (riwt & 
DMA_CHAN_RX_WATCHDOG_RWT);
+       writel(temp, ioaddr + DMA_CHAN_RX_WATCHDOG(queue));
+       /* Update RWTU */
+       temp = (temp & ~DMA_CHAN_RX_WATCHDOG_RWTU) | (riwt & 
DMA_CHAN_RX_WATCHDOG_RWTU);
+       writel(temp, ioaddr + DMA_CHAN_RX_WATCHDOG(queue));
 }
 
 static void dwmac4_dma_rx_chan_op_mode(void __iomem *ioaddr, int mode,
-- 
2.25.1

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#12368): 
https://lists.yoctoproject.org/g/linux-yocto/message/12368
Mute This Topic: https://lists.yoctoproject.org/mt/98234466/21656
Group Owner: linux-yocto+ow...@lists.yoctoproject.org
Unsubscribe: https://lists.yoctoproject.org/g/linux-yocto/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to