aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/infiniband/core/uverbs_std_types_cq.c
diff options
context:
space:
mode:
authorJason Gunthorpe <jgg@mellanox.com>2018-07-04 08:50:26 +0300
committerJason Gunthorpe <jgg@mellanox.com>2018-07-04 13:47:01 -0600
commit595c7736d48037d67e7926f5d3ebf484b95b1d13 (patch)
tree24961a06b5f83db6b638415fa575e5cd5d4115be /drivers/infiniband/core/uverbs_std_types_cq.c
parentRDMA/uverbs: Simplify UVERBS_ATTR family of macros (diff)
downloadlinux-dev-595c7736d48037d67e7926f5d3ebf484b95b1d13.tar.xz
linux-dev-595c7736d48037d67e7926f5d3ebf484b95b1d13.zip
RDMA/uverbs: Simplify method definition macros
Instead of the large set of indirecting macros, define the few needed macros to directly instantiate the struct uverbs_method_def and associated attributes list. This is small amount of code duplication but the readability is far better. Signed-off-by: Jason Gunthorpe <jgg@mellanox.com> Signed-off-by: Leon Romanovsky <leonro@mellanox.com>
Diffstat (limited to 'drivers/infiniband/core/uverbs_std_types_cq.c')
-rw-r--r--drivers/infiniband/core/uverbs_std_types_cq.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/infiniband/core/uverbs_std_types_cq.c b/drivers/infiniband/core/uverbs_std_types_cq.c
index f67b0895b48c..ca0f6a7435d0 100644
--- a/drivers/infiniband/core/uverbs_std_types_cq.c
+++ b/drivers/infiniband/core/uverbs_std_types_cq.c
@@ -147,7 +147,7 @@ err_event_file:
return ret;
};
-static DECLARE_UVERBS_NAMED_METHOD(UVERBS_METHOD_CQ_CREATE,
+DECLARE_UVERBS_NAMED_METHOD(UVERBS_METHOD_CQ_CREATE,
&UVERBS_ATTR_IDR(UVERBS_ATTR_CREATE_CQ_HANDLE, UVERBS_OBJECT_CQ,
UVERBS_ACCESS_NEW,
UA_FLAGS(UVERBS_ATTR_SPEC_F_MANDATORY)),
@@ -196,7 +196,7 @@ static int UVERBS_HANDLER(UVERBS_METHOD_CQ_DESTROY)(struct ib_device *ib_dev,
sizeof(resp));
}
-static DECLARE_UVERBS_NAMED_METHOD(UVERBS_METHOD_CQ_DESTROY,
+DECLARE_UVERBS_NAMED_METHOD(UVERBS_METHOD_CQ_DESTROY,
&UVERBS_ATTR_IDR(UVERBS_ATTR_DESTROY_CQ_HANDLE, UVERBS_OBJECT_CQ,
UVERBS_ACCESS_DESTROY,
UA_FLAGS(UVERBS_ATTR_SPEC_F_MANDATORY)),