From: Kirill Tkhai <ktkhai@virtuozzo.com>
To: netdev@vger.kernel.org
Cc: davem@davemloft.net, harald.albrecht@gmx.net,
jasowang@redhat.com, brouer@redhat.com, edumazet@google.com,
mst@redhat.com, nicolas.dichtel@6wind.com, wangli39@baidu.com,
ktkhai@virtuozzo.com
Subject: [PATCH 2/2] tun: Remove unused first parameter of tun_get_iff()
Date: Wed, 20 Mar 2019 12:16:53 +0300 [thread overview]
Message-ID: <155307340980.17673.6302431836499933065.stgit@localhost.localdomain> (raw)
In-Reply-To: <155307337803.17673.7357500798893442953.stgit@localhost.localdomain>
Signed-off-by: Kirill Tkhai <ktkhai@virtuozzo.com>
---
drivers/net/tun.c | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/drivers/net/tun.c b/drivers/net/tun.c
index b7137edff624..b834b0d168f9 100644
--- a/drivers/net/tun.c
+++ b/drivers/net/tun.c
@@ -2873,8 +2873,7 @@ static int tun_set_iff(struct net *net, struct file *file, struct ifreq *ifr)
return err;
}
-static void tun_get_iff(struct net *net, struct tun_struct *tun,
- struct ifreq *ifr)
+static void tun_get_iff(struct tun_struct *tun, struct ifreq *ifr)
{
tun_debug(KERN_INFO, tun, "tun_get_iff\n");
@@ -3107,7 +3106,7 @@ static long __tun_chr_ioctl(struct file *file, unsigned int cmd,
ret = 0;
switch (cmd) {
case TUNGETIFF:
- tun_get_iff(current->nsproxy->net_ns, tun, &ifr);
+ tun_get_iff(tun, &ifr);
if (tfile->detached)
ifr.ifr_flags |= IFF_DETACH_QUEUE;
@@ -3465,7 +3464,7 @@ static void tun_chr_show_fdinfo(struct seq_file *m, struct file *file)
rtnl_lock();
tun = tun_get(tfile);
if (tun)
- tun_get_iff(current->nsproxy->net_ns, tun, &ifr);
+ tun_get_iff(tun, &ifr);
rtnl_unlock();
if (tun)
next prev parent reply other threads:[~2019-03-20 9:16 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-03-20 9:16 [PATCH 1/2] tun: Add ioctl() TUNGETDEVNETNS cmd to allow obtaining real net ns of tun device Kirill Tkhai
2019-03-20 9:16 ` Kirill Tkhai [this message]
2019-03-21 20:19 ` [PATCH 2/2] tun: Remove unused first parameter of tun_get_iff() David Miller
2019-03-21 20:19 ` [PATCH 1/2] tun: Add ioctl() TUNGETDEVNETNS cmd to allow obtaining real net ns of tun device David Miller
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=155307340980.17673.6302431836499933065.stgit@localhost.localdomain \
--to=ktkhai@virtuozzo.com \
--cc=brouer@redhat.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=harald.albrecht@gmx.net \
--cc=jasowang@redhat.com \
--cc=mst@redhat.com \
--cc=netdev@vger.kernel.org \
--cc=nicolas.dichtel@6wind.com \
--cc=wangli39@baidu.com \
/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