From 880e1b21115bb49e811352530017557ab692e934 Mon Sep 17 00:00:00 2001 From: zhong jiang Date: Wed, 26 Sep 2018 16:56:50 +0800 Subject: [PATCH] net: liquidio: list usage cleanup Trival cleanup, list_move_tail will implement the same function that list_del() + list_add_tail() will do. hence just replace them. Signed-off-by: zhong jiang Signed-off-by: David S. Miller --- drivers/net/ethernet/cavium/liquidio/octeon_device.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/net/ethernet/cavium/liquidio/octeon_device.c b/drivers/net/ethernet/cavium/liquidio/octeon_device.c index 0f0275cd153e..ce8c3f818666 100644 --- a/drivers/net/ethernet/cavium/liquidio/octeon_device.c +++ b/drivers/net/ethernet/cavium/liquidio/octeon_device.c @@ -1044,8 +1044,7 @@ void octeon_delete_dispatch_list(struct octeon_device *oct) dispatch = &oct->dispatch.dlist[i].list; while (dispatch->next != dispatch) { temp = dispatch->next; - list_del(temp); - list_add_tail(temp, &freelist); + list_move_tail(temp, &freelist); } oct->dispatch.dlist[i].opcode = 0;