Skip to contentSkip to conversation

dmaengine: xilinx_dma: Use list_move_tail instead of list_del/list_add_tail

PATCH Applied Baokun Li 3 participants 3 messages Jun 8, 2021 – Jul 28, 2021

Subsystems (3)

v1 of 2 Applied Latest is v2 →

lore
Share & tools
lore

Baokun Li

author
#0 lore raw

PATCH 1/1 dmaengine: xilinx_dma: Use list_move_tail instead of list_del/list_add_tail

Using list_move_tail() instead of list_del() + list_add_tail().

---
 drivers/dma/xilinx/xilinx_dma.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
drivers/dma/xilinx/xilinx_dma.c +1 -2
index 75c0b8e904e5..77022ef05ac5 100644
@@ -1411,8 +1411,7 @@ static void xilinx_vdma_start_transfer(struct xilinx_dma_chan *chan)
 
 	chan->desc_submitcount++;
 	chan->desc_pendingcount--;
-	list_del(&desc->node);
-	list_add_tail(&desc->node, &chan->active_list);
+	list_move_tail(&desc->node, &chan->active_list);
 	if (chan->desc_submitcount == chan->num_frms)
 		chan->desc_submitcount = 0;
 
Reviewed-by on v1 1/1
#1 lore raw
Quoted 16 lines

-----Original Message-----
From: Baokun Li <[email protected]>
Sent: Tuesday, June 8, 2021 8:39 AM
To: [email protected]; Vinod Koul <[email protected]>; Michal Simek <[email protected]>; Radhey Shyam Pandey <[email protected]>; Shravya Kumbham <[email protected]>; Matthew Murrian <[email protected]>; Romain Perier <[email protected]>; Lars-Peter Clausen <[email protected]>; Krzysztof Kozlowski <[email protected]>; Allen Pais <[email protected]>
Cc: [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; kernel- [email protected]; Hulk Robot <[email protected]>
Subject: [PATCH -next] dmaengine: xilinx_dma: Use list_move_tail instead of list_del/list_add_tail

Quoted 4 lines

Using list_move_tail() instead of list_del() + list_add_tail().

Thanks!

Quoted 19 lines
---
 drivers/dma/xilinx/xilinx_dma.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
drivers/dma/xilinx/xilinx_dma.c +1 -2
index 75c0b8e904e5..77022ef05ac5 100644
@@ -1411,8 +1411,7 @@ static void xilinx_vdma_start_transfer(struct
 xilinx_dma_chan *chan)
 
 	chan->desc_submitcount++;
 	chan->desc_pendingcount--;
-	list_del(&desc->node);
-	list_add_tail(&desc->node, &chan->active_list);
+	list_move_tail(&desc->node, &chan->active_list);
 	if (chan->desc_submitcount == chan->num_frms)
 		chan->desc_submitcount = 0;
maintainer Applied
#2 lore raw
In reply to Baokun Li
Quoted 1 line · Baokun Li

Using list_move_tail() instead of list_del() + list_add_tail().

Applied, thanks

Signature · 1 line
~Vinod