All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH -next] RDMA/irdma: Use list_move instead of list_del/list_add
@ 2021-06-08  3:10 Baokun Li
  2021-06-08  9:18 ` Dan Carpenter
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Baokun Li @ 2021-06-08  3:10 UTC (permalink / raw)
  To: linux-kernel, Mustafa Ismail, Shiraz Saleem, Doug Ledford,
	Jason Gunthorpe
  Cc: weiyongjun1, yuehaibing, yangjihong1, yukuai3, libaokun1,
	linux-rdma, kernel-janitors, Hulk Robot

Using list_move() instead of list_del() + list_add().

Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Baokun Li <libaokun1@huawei.com>
---
 drivers/infiniband/hw/irdma/puda.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/infiniband/hw/irdma/puda.c b/drivers/infiniband/hw/irdma/puda.c
index 18057139817d..c0be6e37d425 100644
--- a/drivers/infiniband/hw/irdma/puda.c
+++ b/drivers/infiniband/hw/irdma/puda.c
@@ -1420,8 +1420,7 @@ irdma_ieq_handle_partial(struct irdma_puda_rsrc *ieq, struct irdma_pfpdu *pfpdu,
 error:
 	while (!list_empty(&pbufl)) {
 		buf = (struct irdma_puda_buf *)(pbufl.prev);
-		list_del(&buf->list);
-		list_add(&buf->list, rxlist);
+		list_move(&buf->list, rxlist);
 	}
 	if (txbuf)
 		irdma_puda_ret_bufpool(ieq, txbuf);


^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2021-06-08 20:01 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-06-08  3:10 [PATCH -next] RDMA/irdma: Use list_move instead of list_del/list_add Baokun Li
2021-06-08  9:18 ` Dan Carpenter
2021-06-08 16:25 ` Saleem, Shiraz
2021-06-08 20:01 ` Jason Gunthorpe

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.