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-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1303313954.3186.117.camel@edumazet-laptop>
Date:	Wed, 20 Apr 2011 17:39:14 +0200
From:	Eric Dumazet <eric.dumazet@...il.com>
To:	Oliver Hartkopp <socketcan@...tkopp.net>
Cc:	David Miller <davem@...emloft.net>,
	Linux Netdev List <netdev@...r.kernel.org>,
	Kurt Van Dijck <kurt.van.dijck@....be>,
	Urs Thuermann <urs@...ogud.escape.de>
Subject: Re: [RFC net-next-2.6] can: replace spinlocks with mutexes

Le mercredi 20 avril 2011 à 17:31 +0200, Oliver Hartkopp a écrit :
> This patch removes spinlocks for the CAN netdevice specific receive lists.
> The RCU-based receive lists can be modified from process context or from the
> netdevice notifier call. As both might sleep we can safely replace the
> spinlocks with mutexes.
> 
> Signed-off-by: Oliver Hartkopp <socketcan@...tkopp.net>
> 
> ---

But... why ?

A spinlock is faster/smaller than a mutex.

Maybe you wanted to _remove_ spinlock, since/if writer hold RTNL and
doesnt need to exclude another writer(s) ?

Note : I did not check the RTNL assertion, you might add appropriate
ASSERT_RTNL() calls just to be 100% safe.



--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ