diff options
author | Jason Gunthorpe <jgg@nvidia.com> | 2021-06-11 19:00:32 +0300 |
---|---|---|
committer | Jason Gunthorpe <jgg@nvidia.com> | 2021-06-17 02:58:31 +0300 |
commit | d7407d16699884817f3a93218e77b0801942362b (patch) | |
tree | 62354cafcb7d6ae509521eef88a4ab11393d07a4 /include/rdma/ib_sysfs.h | |
parent | 8f1708f19f919135a5d7eddcdccc15b7fd7d524d (diff) | |
download | linux-d7407d16699884817f3a93218e77b0801942362b.tar.xz |
RDMA: Change ops->init_port to ops->port_groups
init_port was only being used to register sysfs attributes against the
port kobject. Now that all users are creating static attribute_group's we
can simply set the attribute_group list in the ops and the core code can
just handle it directly.
This makes all the sysfs management quite straightforward and prevents any
driver from abusing the naked port kobject in future because no driver
code can access it.
Link: https://lore.kernel.org/r/114f68f3d921460eafe14cea5a80ca65d81729c3.1623427137.git.leonro@nvidia.com
Signed-off-by: Leon Romanovsky <leonro@nvidia.com>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
Diffstat (limited to 'include/rdma/ib_sysfs.h')
-rw-r--r-- | include/rdma/ib_sysfs.h | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/include/rdma/ib_sysfs.h b/include/rdma/ib_sysfs.h index f869d0e4fd30..3b77cfd74d9a 100644 --- a/include/rdma/ib_sysfs.h +++ b/include/rdma/ib_sysfs.h @@ -31,10 +31,6 @@ struct ib_port_attribute { #define IB_PORT_ATTR_WO(_name) \ struct ib_port_attribute ib_port_attr_##_name = __ATTR_WO(_name) -int ib_port_sysfs_create_groups(struct ib_device *ibdev, u32 port_num, - const struct attribute_group **groups); -void ib_port_sysfs_remove_groups(struct ib_device *ibdev, u32 port_num, - const struct attribute_group **groups); struct ib_device *ib_port_sysfs_get_ibdev_kobj(struct kobject *kobj, u32 *port_num); |