i40e: Use list_move instead of list_del/list_add
Using list_move() instead of list_del() + list_add(). Signed-off-by: Wei Yongjun <weiyj.lk@gmail.com> Tested-by: Andrew Bowers <andrewx.bowers@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
This commit is contained in:

committed by
Jeff Kirsher

parent
60747ef4d1
commit
eb27163b2e
@@ -662,8 +662,7 @@ static int i40e_client_release(struct i40e_client *client)
|
|||||||
client->name, pf->hw.pf_id);
|
client->name, pf->hw.pf_id);
|
||||||
}
|
}
|
||||||
/* delete the client instance from the list */
|
/* delete the client instance from the list */
|
||||||
list_del(&cdev->list);
|
list_move(&cdev->list, &cdevs_tmp);
|
||||||
list_add(&cdev->list, &cdevs_tmp);
|
|
||||||
atomic_dec(&client->ref_cnt);
|
atomic_dec(&client->ref_cnt);
|
||||||
dev_info(&pf->pdev->dev, "Deleted client instance of Client %s\n",
|
dev_info(&pf->pdev->dev, "Deleted client instance of Client %s\n",
|
||||||
client->name);
|
client->name);
|
||||||
|
Reference in New Issue
Block a user