aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/infiniband/core/device.c
diff options
context:
space:
mode:
authorDoug Ledford <dledford@redhat.com>2017-08-18 14:12:04 -0400
committerDoug Ledford <dledford@redhat.com>2017-08-18 14:12:04 -0400
commitb0e32e20e3c63778d8c20a40d8bec8b18baffecb (patch)
tree2e0c3311c53889473b94d49132fe5b7cdee71d51 /drivers/infiniband/core/device.c
parentMerge branch 'misc' into k.o/for-next (diff)
parentIB/uverbs: Fix NULL pointer dereference during device removal (diff)
downloadlinux-dev-b0e32e20e3c63778d8c20a40d8bec8b18baffecb.tar.xz
linux-dev-b0e32e20e3c63778d8c20a40d8bec8b18baffecb.zip
Merge branch 'k.o/for-4.13-rc' into k.o/for-next
Merging our (hopefully) final -rc pull branch into our for-next branch because some of our pending patches won't apply cleanly without having the -rc patches in our tree. Signed-off-by: Doug Ledford <dledford@redhat.com>
Diffstat (limited to 'drivers/infiniband/core/device.c')
-rw-r--r--drivers/infiniband/core/device.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/infiniband/core/device.c b/drivers/infiniband/core/device.c
index 6a848f159380..91d7cea1a0b9 100644
--- a/drivers/infiniband/core/device.c
+++ b/drivers/infiniband/core/device.c
@@ -572,10 +572,11 @@ void ib_unregister_device(struct ib_device *device)
}
up_read(&lists_rwsem);
- mutex_unlock(&device_mutex);
-
ib_device_unregister_rdmacg(device);
ib_device_unregister_sysfs(device);
+
+ mutex_unlock(&device_mutex);
+
ib_cache_cleanup_one(device);
ib_security_destroy_port_pkey_list(device);