* [PATCH -next] bnx2x: use list_move instead of list_del/list_add
@ 2013-03-11 14:40 Wei Yongjun
2013-03-11 16:53 ` Ariel Elior
2013-03-12 12:15 ` David Miller
0 siblings, 2 replies; 3+ messages in thread
From: Wei Yongjun @ 2013-03-11 14:40 UTC (permalink / raw)
To: eilong; +Cc: yongjun_wei, netdev
From: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
Using list_move() instead of list_del() + list_add().
Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
---
drivers/net/ethernet/broadcom/bnx2x/bnx2x_sriov.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_sriov.c b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_sriov.c
index 71fcef0..c32a066 100644
--- a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_sriov.c
+++ b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_sriov.c
@@ -556,8 +556,7 @@ static int bnx2x_vfop_config_list(struct bnx2x *bp,
rc = bnx2x_config_vlan_mac(bp, vlan_mac);
if (rc >= 0) {
cnt += pos->add ? 1 : -1;
- list_del(&pos->link);
- list_add(&pos->link, &rollback_list);
+ list_move(&pos->link, &rollback_list);
rc = 0;
} else if (rc == -EEXIST) {
rc = 0;
^ permalink raw reply related [flat|nested] 3+ messages in thread* RE: [PATCH -next] bnx2x: use list_move instead of list_del/list_add
2013-03-11 14:40 [PATCH -next] bnx2x: use list_move instead of list_del/list_add Wei Yongjun
@ 2013-03-11 16:53 ` Ariel Elior
2013-03-12 12:15 ` David Miller
1 sibling, 0 replies; 3+ messages in thread
From: Ariel Elior @ 2013-03-11 16:53 UTC (permalink / raw)
To: Wei Yongjun, Eilon Greenstein
Cc: yongjun_wei@trendmicro.com.cn, netdev@vger.kernel.org,
davem@davemloft.net
On Monday, March 11, 2013 4:40 PM Wei Yongjun wrote:
> Using list_move() instead of list_del() + list_add().
>
> Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
> ---
> drivers/net/ethernet/broadcom/bnx2x/bnx2x_sriov.c | 3 +--
> 1 file changed, 1 insertion(+), 2 deletions(-)
>
> diff --git a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_sriov.c
> b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_sriov.c
> index 71fcef0..c32a066 100644
> --- a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_sriov.c
> +++ b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_sriov.c
> @@ -556,8 +556,7 @@ static int bnx2x_vfop_config_list(struct bnx2x *bp,
> rc = bnx2x_config_vlan_mac(bp, vlan_mac);
> if (rc >= 0) {
> cnt += pos->add ? 1 : -1;
> - list_del(&pos->link);
> - list_add(&pos->link, &rollback_list);
> + list_move(&pos->link, &rollback_list);
> rc = 0;
> } else if (rc == -EEXIST) {
> rc = 0;
>
> --
Thanks
Acked-by: Ariel Elior <ariele@broadcom.com>
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [PATCH -next] bnx2x: use list_move instead of list_del/list_add
2013-03-11 14:40 [PATCH -next] bnx2x: use list_move instead of list_del/list_add Wei Yongjun
2013-03-11 16:53 ` Ariel Elior
@ 2013-03-12 12:15 ` David Miller
1 sibling, 0 replies; 3+ messages in thread
From: David Miller @ 2013-03-12 12:15 UTC (permalink / raw)
To: weiyj.lk; +Cc: eilong, yongjun_wei, netdev
From: Wei Yongjun <weiyj.lk@gmail.com>
Date: Mon, 11 Mar 2013 22:40:14 +0800
> From: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
>
> Using list_move() instead of list_del() + list_add().
>
> Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
Applied.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2013-03-12 12:15 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-03-11 14:40 [PATCH -next] bnx2x: use list_move instead of list_del/list_add Wei Yongjun
2013-03-11 16:53 ` Ariel Elior
2013-03-12 12:15 ` David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox