IB/ipoib: Grab rtnl lock on heavy flush when calling ndo_open/stop
authorAlex Vesker <valex@mellanox.com>
Tue, 10 Oct 2017 07:36:41 +0000 (10:36 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 20 Dec 2017 09:10:37 +0000 (10:10 +0100)
commit023bff1b335860493dce3769c942b0172ea0fb5a
treed3e3b15398a6fa13748cb34f2b02256b33947a64
parent02ef1dd301c2f1ca0ffe58f75bf2f0f4bd291270
IB/ipoib: Grab rtnl lock on heavy flush when calling ndo_open/stop

[ Upstream commit b4b678b06f6eef18bff44a338c01870234db0bc9 ]

When ndo_open and ndo_stop are called RTNL lock should be held.
In this specific case ipoib_ib_dev_open calls the offloaded ndo_open
which re-sets the number of TX queue assuming RTNL lock is held.
Since RTNL lock is not held, RTNL assert will fail.

Signed-off-by: Alex Vesker <valex@mellanox.com>
Signed-off-by: Sasha Levin <alexander.levin@verizon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/infiniband/ulp/ipoib/ipoib_ib.c