lists.openwall.net | lists / announce owl-users owl-dev john-users john-dev passwdqc-users yescrypt popa3d-users / oss-security kernel-hardening musl sabotage tlsify passwords / crypt-dev xvendor / Bugtraq Full-Disclosure linux-kernel linux-netdev linux-ext4 linux-hardening linux-cve-announce PHC | |
Open Source and information security mailing list archives
| ||
|
Date: Fri, 12 Apr 2019 11:38:57 +0300 From: Andy Shevchenko <andriy.shevchenko@...ux.intel.com> To: Wang Hai <wanghai26@...wei.com> Cc: davem@...emloft.net, idosch@...lanox.com, eric.dumazet@...il.com, alexander.h.duyck@...el.com, tyhicks@...onical.com, f.fainelli@...il.com, viro@...iv.linux.org.uk, amritha.nambiar@...el.com, joe@...ches.com, dmitry.torokhov@...il.com, stephen@...workplumber.org, netdev@...r.kernel.org, linux-kernel@...r.kernel.org Subject: Re: [PATCH 1/2] Revert "net-sysfs: Fix memory leak in netdev_register_kobject" On Fri, Apr 12, 2019 at 04:36:33PM -0400, Wang Hai wrote: > This reverts commit 6b70fc94afd165342876e53fc4b2f7d085009945. > > The reverted bugfix will cause another issue. > Reported by syzbot+6024817a931b2830bc93@...kaller.appspotmail.com. > See https://syzkaller.appspot.com/x/log.txt?x=1737671b200000 for > details. > Acked-by: Andy Shevchenko <andriy.shevchenko@...ux.intel.com> > Signed-off-by: Wang Hai <wanghai26@...wei.com> > --- > net/core/net-sysfs.c | 14 +++++--------- > 1 file changed, 5 insertions(+), 9 deletions(-) > > diff --git a/net/core/net-sysfs.c b/net/core/net-sysfs.c > index f8f9430..8f8b7b6 100644 > --- a/net/core/net-sysfs.c > +++ b/net/core/net-sysfs.c > @@ -1747,20 +1747,16 @@ int netdev_register_kobject(struct net_device *ndev) > > error = device_add(dev); > if (error) > - goto error_put_device; > + return error; > > error = register_queue_kobjects(ndev); > - if (error) > - goto error_device_del; > + if (error) { > + device_del(dev); > + return error; > + } > > pm_runtime_set_memalloc_noio(dev, true); > > - return 0; > - > -error_device_del: > - device_del(dev); > -error_put_device: > - put_device(dev); > return error; > } > > -- > 1.8.3.1 > -- With Best Regards, Andy Shevchenko
Powered by blists - more mailing lists