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 :)