Commit 68baf495 authored by Steve Wise's avatar Steve Wise Committed by Roland Dreier

RDMA/cxgb3: Mark RDMA device with CXIO_ERROR_FATAL when removing

If cxgb3 calls the iw_cxgb3 t3cclient remove function due to a device
removal event, then the iwch device must be marked with CXIO_ERROR_FATAL
since the device below us is going away.  Otherwise, we can get stuck in
a deadlock as RDMA ULPs try and deallocate objects (like MRs, QPs, etc).
So always mark the device with CXIO_ERROR_FATAL when removing.
Signed-off-by: default avatarSteve Wise <swise@opengridcomputing.com>
Signed-off-by: default avatarRoland Dreier <rolandd@cisco.com>
parent 5279d3ac
...@@ -188,6 +188,7 @@ static void close_rnic_dev(struct t3cdev *tdev) ...@@ -188,6 +188,7 @@ static void close_rnic_dev(struct t3cdev *tdev)
mutex_lock(&dev_mutex); mutex_lock(&dev_mutex);
list_for_each_entry_safe(dev, tmp, &dev_list, entry) { list_for_each_entry_safe(dev, tmp, &dev_list, entry) {
if (dev->rdev.t3cdev_p == tdev) { if (dev->rdev.t3cdev_p == tdev) {
dev->rdev.flags = CXIO_ERROR_FATAL;
cancel_delayed_work_sync(&dev->db_drop_task); cancel_delayed_work_sync(&dev->db_drop_task);
list_del(&dev->entry); list_del(&dev->entry);
iwch_unregister_device(dev); iwch_unregister_device(dev);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment