mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-01-11 07:39:47 +00:00
RDMA/addr: list_move() cleanups
Replace a couple list_del()/list_add() combos with list_move(). Signed-off-by: Roland Dreier <rolandd@cisco.com>
This commit is contained in:
parent
c78bb8442b
commit
04699a1f86
@ -235,8 +235,7 @@ static void process_req(void *data)
|
|||||||
else if (req->status == -ENODATA)
|
else if (req->status == -ENODATA)
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
list_del(&req->list);
|
list_move_tail(&req->list, &done_list);
|
||||||
list_add_tail(&req->list, &done_list);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!list_empty(&req_list)) {
|
if (!list_empty(&req_list)) {
|
||||||
@ -346,8 +345,7 @@ void rdma_addr_cancel(struct rdma_dev_addr *addr)
|
|||||||
if (req->addr == addr) {
|
if (req->addr == addr) {
|
||||||
req->status = -ECANCELED;
|
req->status = -ECANCELED;
|
||||||
req->timeout = jiffies;
|
req->timeout = jiffies;
|
||||||
list_del(&req->list);
|
list_move(&req->list, &req_list);
|
||||||
list_add(&req->list, &req_list);
|
|
||||||
set_timeout(req->timeout);
|
set_timeout(req->timeout);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user