[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20171201141442.0020f9a4@cakuba.netronome.com>
Date: Fri, 1 Dec 2017 14:14:42 -0800
From: Jakub Kicinski <jakub.kicinski@...ronome.com>
To: Phil Sutter <phil@....cc>
Cc: netdev@...r.kernel.org, davem@...emloft.net, daniel@...earbox.net,
alexei.starovoitov@...il.com, jiri@...nulli.us,
oss-drivers@...ronome.com, Sabrina Dubroca <sd@...asysnail.net>
Subject: Re: [PATCH net-next v2 7/8] netdevsim: add SR-IOV functionality
On Fri, 1 Dec 2017 22:58:29 +0100, Phil Sutter wrote:
> > > > > > + ret = count;
> > > > > > +exit_unlock:
> > > > > > + rtnl_unlock();
> > > > > > +
> > > > > > + return ret;
> > > > > > +}
> > > > >
> > > > > [...]
> > > > >
> > > > > > +static void nsim_free(struct net_device *dev)
> > > > > > +{
> > > > > > + struct netdevsim *ns = netdev_priv(dev);
> > > > > > +
> > > > > > + device_unregister(&ns->dev);
> > > > > > }
> > > > >
> > > > > Shouldn't this also kfree(ns->vfconfigs)?
> > > >
> > > > It's in uninit, I will move it to release.
> > >
> > > Oh, I missed that. If you're certain this won't lead to memleaks, no
> > > objection from my side. :)
> >
> > OK, I will respin v3 with the free moved :)
>
> So it did leak? I'm glad the traffic I caused wasn't completely
> pointless then. :)
There is a window where it could've been re-enabled and that
would leak, yes. Thanks for catching it :)
Powered by blists - more mailing lists