diff options
author | Michael S. Tsirkin <mst@mellanox.co.il> | 2005-08-24 17:41:51 -0400 |
---|---|---|
committer | Roland Dreier <rolandd@cisco.com> | 2005-08-26 23:37:38 -0400 |
commit | 1ad62a19f177e61d4dde111ba35fb4badd0c2106 (patch) | |
tree | e427260a9049b1300fe69c7542bdb4a85fa2fa9a | |
parent | fe9e08e17af414a5fd8f3141b0fd88677f81a883 (diff) |
[PATCH] IPoIB: Fix device removal race
Currently we may have work scheduled in default kernel workqueue when
the device is going down. The device could get freed before this
workqueue gets serviced. I am actually seeing this causing system
hangs.
The following patch fixes this by using ipoib_workqueue which gets
flushed when the device is going down.
Signed-off-by: Michael S. Tsirkin <mst@mellanox.co.il>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
-rw-r--r-- | drivers/infiniband/ulp/ipoib/ipoib_main.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/infiniband/ulp/ipoib/ipoib_main.c b/drivers/infiniband/ulp/ipoib/ipoib_main.c index 57c3ac98991f..0e8ac138e355 100644 --- a/drivers/infiniband/ulp/ipoib/ipoib_main.c +++ b/drivers/infiniband/ulp/ipoib/ipoib_main.c | |||
@@ -672,7 +672,7 @@ static void ipoib_set_mcast_list(struct net_device *dev) | |||
672 | { | 672 | { |
673 | struct ipoib_dev_priv *priv = netdev_priv(dev); | 673 | struct ipoib_dev_priv *priv = netdev_priv(dev); |
674 | 674 | ||
675 | schedule_work(&priv->restart_task); | 675 | queue_work(ipoib_workqueue, &priv->restart_task); |
676 | } | 676 | } |
677 | 677 | ||
678 | static void ipoib_neigh_destructor(struct neighbour *n) | 678 | static void ipoib_neigh_destructor(struct neighbour *n) |