diff options
| author | Li Haoran <li.haoran7@zte.com.cn> | 2025-04-01 21:09:23 +0800 |
|---|---|---|
| committer | Jason Gunthorpe <jgg@nvidia.com> | 2025-04-07 15:12:07 -0300 |
| commit | 7bc871af417a3011739ccddabb64db482ff7d752 (patch) | |
| tree | d8489a4a55c7829d411c8be10dc6a3228470a0c3 /drivers/infiniband/core/uverbs_cmd.c | |
| parent | 41e2649c796e1f49c7b4d9176d2437504b78580f (diff) | |
RDMA/uverbs: Convert to use ERR_CAST()
As opposed to open-code, using the ERR_CAST macro clearly indicates that
this is a pointer to an error value and a type conversion was performed.
Link: https://patch.msgid.link/r/202504012109233981_YPVbd4wQzmAzP3tA5IG@zte.com.cn
Signed-off-by: Li Haoran <li.haoran7@zte.com.cn>
Signed-off-by: Shao Mingyin <shao.mingyin@zte.com.cn>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
Diffstat (limited to 'drivers/infiniband/core/uverbs_cmd.c')
| -rw-r--r-- | drivers/infiniband/core/uverbs_cmd.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/infiniband/core/uverbs_cmd.c b/drivers/infiniband/core/uverbs_cmd.c index 3c3bb670c805..bc9fe3ceca4d 100644 --- a/drivers/infiniband/core/uverbs_cmd.c +++ b/drivers/infiniband/core/uverbs_cmd.c @@ -193,7 +193,7 @@ _ib_uverbs_lookup_comp_file(s32 fd, struct uverbs_attr_bundle *attrs) fd, attrs); if (IS_ERR(uobj)) - return (void *)uobj; + return ERR_CAST(uobj); uverbs_uobject_get(uobj); uobj_put_read(uobj); |
