diff options
author | zhong jiang <zhongjiang@huawei.com> | 2018-09-26 16:53:00 +0800 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2018-09-26 10:11:36 -0700 |
commit | 631e871edc768210d5d5716f5787e4f363c65352 (patch) | |
tree | 8f5239a55486050142e8350e2748119b9397dac7 /drivers/net/ethernet/qlogic/qed/qed_ooo.c | |
parent | 30b0594a3e6c2bcbe5bd59753d0319d6f9925e40 (diff) |
net: qed: 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 <zhongjiang@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/qlogic/qed/qed_ooo.c')
-rw-r--r-- | drivers/net/ethernet/qlogic/qed/qed_ooo.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/drivers/net/ethernet/qlogic/qed/qed_ooo.c b/drivers/net/ethernet/qlogic/qed/qed_ooo.c index 6172354b451c..63931dfc77cf 100644 --- a/drivers/net/ethernet/qlogic/qed/qed_ooo.c +++ b/drivers/net/ethernet/qlogic/qed/qed_ooo.c @@ -211,9 +211,8 @@ void qed_ooo_release_connection_isles(struct qed_hwfn *p_hwfn, if (!p_buffer) break; - list_del(&p_buffer->list_entry); - list_add_tail(&p_buffer->list_entry, - &p_ooo_info->free_buffers_list); + list_move_tail(&p_buffer->list_entry, + &p_ooo_info->free_buffers_list); } list_add_tail(&p_isle->list_entry, &p_ooo_info->free_isles_list); @@ -247,9 +246,8 @@ void qed_ooo_release_all_isles(struct qed_hwfn *p_hwfn, if (!p_buffer) break; - list_del(&p_buffer->list_entry); - list_add_tail(&p_buffer->list_entry, - &p_ooo_info->free_buffers_list); + list_move_tail(&p_buffer->list_entry, + &p_ooo_info->free_buffers_list); } list_add_tail(&p_isle->list_entry, &p_ooo_info->free_isles_list); |