summaryrefslogtreecommitdiffstats
path: root/net/rds/ib.c
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2019-10-05 22:37:23 +0200
committerDavid S. Miller <davem@davemloft.net>2019-10-05 22:37:23 +0200
commit6f4c930e02355664d89c976eccea5d999a90de16 (patch)
treebc08932fbf43b9560ba5bde3284674054e3b56eb /net/rds/ib.c
parentnet: dsa: sja1105: Make function sja1105_xfer_long_buf static (diff)
parentMerge tag 'kbuild-fixes-v5.4' of git://git.kernel.org/pub/scm/linux/kernel/gi... (diff)
downloadlinux-6f4c930e02355664d89c976eccea5d999a90de16.tar.xz
linux-6f4c930e02355664d89c976eccea5d999a90de16.zip
Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net
Diffstat (limited to 'net/rds/ib.c')
-rw-r--r--net/rds/ib.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/net/rds/ib.c b/net/rds/ib.c
index 01dc18993b4b..23a2ae53f231 100644
--- a/net/rds/ib.c
+++ b/net/rds/ib.c
@@ -145,6 +145,9 @@ static void rds_ib_add_one(struct ib_device *device)
refcount_set(&rds_ibdev->refcount, 1);
INIT_WORK(&rds_ibdev->free_work, rds_ib_dev_free);
+ INIT_LIST_HEAD(&rds_ibdev->ipaddr_list);
+ INIT_LIST_HEAD(&rds_ibdev->conn_list);
+
rds_ibdev->max_wrs = device->attrs.max_qp_wr;
rds_ibdev->max_sge = min(device->attrs.max_send_sge, RDS_IB_MAX_SGE);
@@ -211,9 +214,6 @@ static void rds_ib_add_one(struct ib_device *device)
device->name,
rds_ibdev->use_fastreg ? "FRMR" : "FMR");
- INIT_LIST_HEAD(&rds_ibdev->ipaddr_list);
- INIT_LIST_HEAD(&rds_ibdev->conn_list);
-
down_write(&rds_ib_devices_lock);
list_add_tail_rcu(&rds_ibdev->list, &rds_ib_devices);
up_write(&rds_ib_devices_lock);