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  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Thu, 28 Jan 2016 16:22:15 -0800 (PST)
From:	David Miller <davem@...emloft.net>
To:	jiri@...nulli.us
Cc:	netdev@...r.kernel.org, idosch@...lanox.com, eladr@...lanox.com,
	yotamg@...lanox.com, ogerlitz@...lanox.com,
	stephen@...workplumber.org, sfeldma@...il.com
Subject: Re: [patch net] switchdev: Require RTNL mutex to be held when
 sending FDB notifications

From: Jiri Pirko <jiri@...nulli.us>
Date: Wed, 27 Jan 2016 15:16:43 +0100

> From: Ido Schimmel <idosch@...lanox.com>
> 
> When switchdev drivers process FDB notifications from the underlying
> device they resolve the netdev to which the entry points to and notify
> the bridge using the switchdev notifier.
> 
> However, since the RTNL mutex is not held there is nothing preventing
> the netdev from disappearing in the middle, which will cause
> br_switchdev_event() to dereference a non-existing netdev.
> 
> Make switchdev drivers hold the lock at the beginning of the
> notification processing session and release it once it ends, after
> notifying the bridge.
> 
> Also, remove switchdev_mutex and fdb_lock, as they are no longer needed
> when RTNL mutex is held.
> 
> Fixes: 03bf0c281234 ("switchdev: introduce switchdev notifier")
> Signed-off-by: Ido Schimmel <idosch@...lanox.com>
> Signed-off-by: Jiri Pirko <jiri@...lanox.com>

Applied and queued up for -stable, thanks Jiri.

Powered by blists - more mailing lists