mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-07-16 17:57:38 -04:00
RDMA/core: Move ucaps into ib_uverbs_support.ko
mlx5 uses these move them into the support module from ib_uverbs.ko. Link: https://patch.msgid.link/r/5-v3-43aba1969751+1988-ib_uverbs_support_ko_jgg@nvidia.com Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
This commit is contained in:
@@ -46,7 +46,7 @@ ib_uverbs-y := uverbs_main.o uverbs_cmd.o uverbs_marshall.o \
|
||||
uverbs_std_types_async_fd.o \
|
||||
uverbs_std_types_srq.o \
|
||||
uverbs_std_types_wq.o \
|
||||
uverbs_std_types_qp.o \
|
||||
ucaps.o
|
||||
uverbs_std_types_qp.o
|
||||
|
||||
ib_uverbs_support-y := rdma_core.o
|
||||
ib_uverbs_support-y := rdma_core.o \
|
||||
ucaps.o
|
||||
|
||||
@@ -46,12 +46,7 @@ static const struct file_operations ucaps_cdev_fops = {
|
||||
.open = simple_open,
|
||||
};
|
||||
|
||||
/**
|
||||
* ib_cleanup_ucaps - cleanup all API resources and class.
|
||||
*
|
||||
* This is called once, when removing the ib_uverbs module.
|
||||
*/
|
||||
void ib_cleanup_ucaps(void)
|
||||
static __exit void ib_cleanup_ucaps(void)
|
||||
{
|
||||
mutex_lock(&ucaps_mutex);
|
||||
if (!ucaps_class_is_registered) {
|
||||
@@ -265,3 +260,6 @@ int ib_get_ucaps(int *fds, int fd_count, uint64_t *idx_mask)
|
||||
mutex_unlock(&ucaps_mutex);
|
||||
return ret;
|
||||
}
|
||||
EXPORT_SYMBOL_NS_GPL(ib_get_ucaps, "rdma_core");
|
||||
|
||||
module_exit(ib_cleanup_ucaps);
|
||||
|
||||
@@ -1350,7 +1350,6 @@ static void __exit ib_uverbs_cleanup(void)
|
||||
IB_UVERBS_NUM_FIXED_MINOR);
|
||||
unregister_chrdev_region(dynamic_uverbs_dev,
|
||||
IB_UVERBS_NUM_DYNAMIC_MINOR);
|
||||
ib_cleanup_ucaps();
|
||||
mmu_notifier_synchronize();
|
||||
}
|
||||
|
||||
|
||||
@@ -14,7 +14,6 @@ enum rdma_user_cap {
|
||||
RDMA_UCAP_MAX
|
||||
};
|
||||
|
||||
void ib_cleanup_ucaps(void);
|
||||
int ib_get_ucaps(int *fds, int fd_count, uint64_t *idx_mask);
|
||||
#if IS_ENABLED(CONFIG_INFINIBAND_USER_ACCESS)
|
||||
int ib_create_ucap(enum rdma_user_cap type);
|
||||
|
||||
Reference in New Issue
Block a user