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
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <264300966@web.de>
Date:	Sun, 04 May 2008 11:33:12 +0200
From:	devzero@....de
To:	David Miller <davem@...emloft.net>
Cc:	akpm@...ux-foundation.org, g4klx@...lx.demon.co.uk,
	linux-kernel@...r.kernel.org, netdev@...r.kernel.org
Subject: Re: 24rc8: unregister_netdevice: waiting for ... to become free

> Roland, does this fix your bug?

Yes! 
With this patch i can unload the nic driver again.
Thank you !



> -----Ursprüngliche Nachricht-----
> Von: "David Miller" <davem@...emloft.net>
> Gesendet: 04.05.08 06:11:32
> An: devzero@....de
> CC: akpm@...ux-foundation.org, linux-kernel@...r.kernel.org, netdev@...r.kernel.org, g4klx@...lx.demon.co.uk
> Betreff: Re: 24rc8: unregister_netdevice: waiting for ... to become free


> From: David Miller <davem@...emloft.net>
> Date: Fri, 02 May 2008 05:45:36 -0700 (PDT)
> 
> > From: "Roland" <devzero@....de>
> > Date: Fri, 2 May 2008 14:38:36 +0200
> > 
> > > it seems it`s lapbether driver
> > > 
> > > reproduce:
> > > 
> > > on system with pcnet32 (vmware) do
> > > 
> > > modprobe pcnet32
> > > modprobe lapbether
> > > modprobe -r lapbether
> > > modprobe -r pcnet32 -> hang -> unregister_netdevice: waiting for eth0 to 
> > > become free
> > 
> > lapbeth_cleanup_driver() unregisters the netdevice, but does not
> > release the reference to lapbeth->ethdev in those device instances.
> > 
> > Once this happens, and the lapbeth_dev_notifier is unregistered,
> > these references will leak forever.
> 
> Roland, does this fix your bug?
> 
> lapbeth: Release ->ethdev when unregistering device.
> 
> Otherwise it leaks forever.
> 
> Based upon a report by Roland <devzero@....de>
> 
> Signed-off-by: David S. Miller <davem@...emloft.net>
> 
> diff --git a/drivers/net/wan/lapbether.c b/drivers/net/wan/lapbether.c
> index b5860b9..24fd613 100644
> --- a/drivers/net/wan/lapbether.c
> +++ b/drivers/net/wan/lapbether.c
> @@ -459,6 +459,7 @@ static void __exit lapbeth_cleanup_driver(void)
>  	list_for_each_safe(entry, tmp, &lapbeth_devices) {
>  		lapbeth = list_entry(entry, struct lapbethdev, node);
>  
> +		dev_put(lapbeth->ethdev);
>  		unregister_netdevice(lapbeth->axdev);
>  	}
>  	rtnl_unlock();

Acked-by: Roland Kletzing <devzero@....de>


_______________________________________________________________________
Jetzt neu! Schützen Sie Ihren PC mit McAfee und WEB.DE. 30 Tage
kostenlos testen. http://www.pc-sicherheit.web.de/startseite/?mc=022220

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ