summaryrefslogtreecommitdiff
path: root/drivers/infiniband
diff options
context:
space:
mode:
authorParav Pandit <parav@mellanox.com>2018-10-07 12:12:41 +0300
committerDoug Ledford <dledford@redhat.com>2018-10-16 21:09:45 +0300
commit1ae4cfa03902c83d1d77123e5ac8f0812c61b90e (patch)
treef177e0a1c8fec48414ad529dafb3c6ee6c5307ee /drivers/infiniband
parent0f6ef65d1c6ec8deb5d0f11f86631ec4cfe8f22e (diff)
downloadlinux-1ae4cfa03902c83d1d77123e5ac8f0812c61b90e.tar.xz
RDMA/core: Rename ports_parent to ports_kobj
Normally kobj objects have kobj suffix to reflect it. Rename ports_parent to ports_kobj. Signed-off-by: Parav Pandit <parav@mellanox.com> Signed-off-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com>
Diffstat (limited to 'drivers/infiniband')
-rw-r--r--drivers/infiniband/core/sysfs.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/drivers/infiniband/core/sysfs.c b/drivers/infiniband/core/sysfs.c
index 107c8ba2046c..f54f107ef668 100644
--- a/drivers/infiniband/core/sysfs.c
+++ b/drivers/infiniband/core/sysfs.c
@@ -1036,7 +1036,7 @@ static int add_port(struct ib_device *device, int port_num,
p->port_num = port_num;
ret = kobject_init_and_add(&p->kobj, &port_type,
- device->ports_parent,
+ device->ports_kobj,
"%d", port_num);
if (ret) {
kfree(p);
@@ -1305,7 +1305,7 @@ static void free_port_list_attributes(struct ib_device *device)
kobject_put(p);
}
- kobject_put(device->ports_parent);
+ kobject_put(device->ports_kobj);
}
int ib_device_register_sysfs(struct ib_device *device,
@@ -1323,9 +1323,8 @@ int ib_device_register_sysfs(struct ib_device *device,
if (ret)
goto err;
- device->ports_parent = kobject_create_and_add("ports",
- &class_dev->kobj);
- if (!device->ports_parent) {
+ device->ports_kobj = kobject_create_and_add("ports", &class_dev->kobj);
+ if (!device->ports_kobj) {
ret = -ENOMEM;
goto err_put;
}