From: Paul Moore <pmoore@redhat.com>
To: Jason Wang <jasowang@redhat.com>
Cc: netdev@vger.kernel.org, linux-security-module@vger.kernel.org,
selinux@tycho.nsa.gov, mst@redhat.com
Subject: Re: [RFC PATCH v2 1/3] tun: correctly report an error in tun_flow_init()
Date: Thu, 06 Dec 2012 10:46:42 -0500 [thread overview]
Message-ID: <1925714.MfFlfY86Ce@sifl> (raw)
In-Reply-To: <2215330.qi9iHRh0XG@jason-thinkpad-t430s>
On Thursday, December 06, 2012 06:31:29 PM Jason Wang wrote:
> On Wednesday, December 05, 2012 03:26:04 PM Paul Moore wrote:
> > On error, the error code from tun_flow_init() is lost inside
> > tun_set_iff(), this patch fixes this by assigning the tun_flow_init()
> > error code to the "err" variable which is returned by
> > the tun_flow_init() function on error.
> >
> > Signed-off-by: Paul Moore <pmoore@redhat.com>
> > ---
> >
> > drivers/net/tun.c | 3 ++-
> > 1 file changed, 2 insertions(+), 1 deletion(-)
> >
> > diff --git a/drivers/net/tun.c b/drivers/net/tun.c
> > index a1b2389..14a0454 100644
> > --- a/drivers/net/tun.c
> > +++ b/drivers/net/tun.c
> > @@ -1591,7 +1591,8 @@ static int tun_set_iff(struct net *net, struct file
> > *file, struct ifreq *ifr)
> >
> > tun_net_init(dev);
> >
> > - if (tun_flow_init(tun))
> > + err = tun_flow_init(tun);
> > + if (err < 0)
> >
> > goto err_free_dev;
> >
> > dev->hw_features = NETIF_F_SG | NETIF_F_FRAGLIST |
> >
> > --
>
> Looks fine, we can separate this out of this series and replace the RFC with
> net-next to let David apply it soon.
Will do shortly.
--
paul moore
security and virtualization @ redhat
--
This message was distributed to subscribers of the selinux mailing list.
If you no longer wish to subscribe, send mail to majordomo@tycho.nsa.gov with
the words "unsubscribe selinux" without quotes as the message.
next prev parent reply other threads:[~2012-12-06 15:46 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-12-05 20:25 [RFC PATCH v2 0/3] Fix some multiqueue TUN problems Paul Moore
2012-12-05 20:26 ` [RFC PATCH v2 1/3] tun: correctly report an error in tun_flow_init() Paul Moore
[not found] ` <2215330.qi9iHRh0XG@jason-thinkpad-t430s>
2012-12-06 15:46 ` Paul Moore [this message]
2012-12-05 20:26 ` [RFC PATCH v2 2/3] selinux: add the "create_queue" permission to the "tun_socket" class Paul Moore
2012-12-05 20:26 ` [RFC PATCH v2 3/3] tun: fix LSM/SELinux labeling of tun/tap devices Paul Moore
[not found] ` <9040763.QsllgCP7TP@jason-thinkpad-t430s>
2012-12-06 15:36 ` Paul Moore
[not found] ` <20121206103325.GG10837@redhat.com>
2012-12-06 15:46 ` Paul Moore
[not found] ` <20121206161200.GA4340@redhat.com>
2012-12-06 16:56 ` Paul Moore
[not found] ` <20121206205716.GA6576@redhat.com>
2012-12-06 21:09 ` Paul Moore
[not found] ` <20121207122516.GA16577@redhat.com>
2012-12-10 17:04 ` Paul Moore
[not found] ` <20121210172656.GA30775@redhat.com>
2012-12-10 17:33 ` Paul Moore
[not found] ` <20121210175035.GA31856@redhat.com>
2012-12-10 18:42 ` Eric Paris
2012-12-10 22:21 ` Paul Moore
2012-12-10 22:43 ` Paul Moore
[not found] ` <20121212092236.GB4354@redhat.com>
2012-12-12 18:49 ` Paul Moore
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=1925714.MfFlfY86Ce@sifl \
--to=pmoore@redhat.com \
--cc=jasowang@redhat.com \
--cc=linux-security-module@vger.kernel.org \
--cc=mst@redhat.com \
--cc=netdev@vger.kernel.org \
--cc=selinux@tycho.nsa.gov \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.