netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Pablo Neira Ayuso <pablo@netfilter.org>
To: netfilter-devel@vger.kernel.org
Cc: davem@davemloft.net, netdev@vger.kernel.org, kuba@kernel.org
Subject: [PATCH nf-next 1/7] ipvs: remove unused variable for ip_vs_new_dest
Date: Thu, 16 Dec 2021 00:49:05 +0100	[thread overview]
Message-ID: <20211215234911.170741-2-pablo@netfilter.org> (raw)
In-Reply-To: <20211215234911.170741-1-pablo@netfilter.org>

From: GuoYong Zheng <zhenggy@chinatelecom.cn>

The dest variable is not used after ip_vs_new_dest anymore in
ip_vs_add_dest, do not need pass it to ip_vs_new_dest, remove it.

Signed-off-by: GuoYong Zheng <zhenggy@chinatelecom.cn>
Acked-by: Julian Anastasov <ja@ssi.bg>
Acked-by: Simon Horman <horms@verge.net.au>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
---
 net/netfilter/ipvs/ip_vs_ctl.c | 7 ++-----
 1 file changed, 2 insertions(+), 5 deletions(-)

diff --git a/net/netfilter/ipvs/ip_vs_ctl.c b/net/netfilter/ipvs/ip_vs_ctl.c
index 39c523bd775c..7f645328b47f 100644
--- a/net/netfilter/ipvs/ip_vs_ctl.c
+++ b/net/netfilter/ipvs/ip_vs_ctl.c
@@ -960,8 +960,7 @@ __ip_vs_update_dest(struct ip_vs_service *svc, struct ip_vs_dest *dest,
  *	Create a destination for the given service
  */
 static int
-ip_vs_new_dest(struct ip_vs_service *svc, struct ip_vs_dest_user_kern *udest,
-	       struct ip_vs_dest **dest_p)
+ip_vs_new_dest(struct ip_vs_service *svc, struct ip_vs_dest_user_kern *udest)
 {
 	struct ip_vs_dest *dest;
 	unsigned int atype, i;
@@ -1021,8 +1020,6 @@ ip_vs_new_dest(struct ip_vs_service *svc, struct ip_vs_dest_user_kern *udest,
 	spin_lock_init(&dest->stats.lock);
 	__ip_vs_update_dest(svc, dest, udest, 1);
 
-	*dest_p = dest;
-
 	LeaveFunction(2);
 	return 0;
 
@@ -1096,7 +1093,7 @@ ip_vs_add_dest(struct ip_vs_service *svc, struct ip_vs_dest_user_kern *udest)
 		/*
 		 * Allocate and initialize the dest structure
 		 */
-		ret = ip_vs_new_dest(svc, udest, &dest);
+		ret = ip_vs_new_dest(svc, udest);
 	}
 	LeaveFunction(2);
 
-- 
2.30.2


  reply	other threads:[~2021-12-15 23:49 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-12-15 23:49 [PATCH nf-next 0/7] Netfilter updates for net-next Pablo Neira Ayuso
2021-12-15 23:49 ` Pablo Neira Ayuso [this message]
2021-12-16  1:50   ` [PATCH nf-next 1/7] ipvs: remove unused variable for ip_vs_new_dest patchwork-bot+netdevbpf
2021-12-15 23:49 ` [PATCH nf-next 2/7] netfilter: conntrack: Use memset_startat() to zero struct nf_conn Pablo Neira Ayuso
2021-12-15 23:49 ` [PATCH nf-next 3/7] netfilter: nf_queue: remove leftover synchronize_rcu Pablo Neira Ayuso
2021-12-15 23:49 ` [PATCH nf-next 4/7] netfilter: ctnetlink: remove useless type conversion to bool Pablo Neira Ayuso
2021-12-15 23:49 ` [PATCH nf-next 5/7] netfilter: nft_fwd_netdev: Support egress hook Pablo Neira Ayuso
2021-12-15 23:49 ` [PATCH nf-next 6/7] netfilter: bridge: add support for pppoe filtering Pablo Neira Ayuso
2021-12-15 23:49 ` [PATCH nf-next 7/7] netfilter: conntrack: Remove useless assignment statements Pablo Neira Ayuso

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20211215234911.170741-2-pablo@netfilter.org \
    --to=pablo@netfilter.org \
    --cc=davem@davemloft.net \
    --cc=kuba@kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=netfilter-devel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).