aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/infiniband/core/cache.c
diff options
context:
space:
mode:
authorAnand Khoje <[email protected]>2021-07-12 12:26:24 +0000
committerJason Gunthorpe <[email protected]>2021-07-16 13:57:28 +0000
commit36721a6d4cf2a39f411e3ac04d5771d1ffef9d23 (patch)
tree023641c3af6edd1f8a1344ebdc02622a5d6e5831 /drivers/infiniband/core/cache.c
parentIB/core: Updating cache for subnet_prefix in config_non_roce_gid_cache() (diff)
downloadkernel-36721a6d4cf2a39f411e3ac04d5771d1ffef9d23.tar.gz
kernel-36721a6d4cf2a39f411e3ac04d5771d1ffef9d23.zip
IB/core: Shifting initialization of device->cache_lock
The lock cache_lock of struct ib_device is initialized in function ib_cache_setup_one(). This is much later than the device initialization in _ib_alloc_device(). This change shifts initialization of cache_lock in _ib_alloc_device(). Link: https://lore.kernel.org/r/[email protected] Suggested-by: Haakon Bugge <[email protected]> Signed-off-by: Anand Khoje <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
Diffstat (limited to 'drivers/infiniband/core/cache.c')
-rw-r--r--drivers/infiniband/core/cache.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/drivers/infiniband/core/cache.c b/drivers/infiniband/core/cache.c
index 929399e103d1..0c98dd3dee67 100644
--- a/drivers/infiniband/core/cache.c
+++ b/drivers/infiniband/core/cache.c
@@ -1621,8 +1621,6 @@ int ib_cache_setup_one(struct ib_device *device)
u32 p;
int err;
- rwlock_init(&device->cache_lock);
-
err = gid_table_setup_one(device);
if (err)
return err;