diff options
Diffstat (limited to 'drivers/infiniband/core/device.c')
-rw-r--r-- | drivers/infiniband/core/device.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/infiniband/core/device.c b/drivers/infiniband/core/device.c index a5dfab6adf49..221468f77128 100644 --- a/drivers/infiniband/core/device.c +++ b/drivers/infiniband/core/device.c | |||
@@ -537,10 +537,11 @@ void ib_unregister_device(struct ib_device *device) | |||
537 | } | 537 | } |
538 | up_read(&lists_rwsem); | 538 | up_read(&lists_rwsem); |
539 | 539 | ||
540 | mutex_unlock(&device_mutex); | ||
541 | |||
542 | ib_device_unregister_rdmacg(device); | 540 | ib_device_unregister_rdmacg(device); |
543 | ib_device_unregister_sysfs(device); | 541 | ib_device_unregister_sysfs(device); |
542 | |||
543 | mutex_unlock(&device_mutex); | ||
544 | |||
544 | ib_cache_cleanup_one(device); | 545 | ib_cache_cleanup_one(device); |
545 | 546 | ||
546 | ib_security_destroy_port_pkey_list(device); | 547 | ib_security_destroy_port_pkey_list(device); |