提交 259e66bc 编写于 作者: B Bart Van Assche 提交者: Jason Gunthorpe

RDMA/uverbs: Add a __user annotation to a pointer

This patch avoids that sparse and smatch report the following:

  warning: cast removes address space of expression
Reviewed-by: NLeon Romanovsky <leonro@mellanox.com>
Fixes: 3a6532c9 ("RDMA/uverbs: Use uverbs_attr_bundle to pass udata for write")
Signed-off-by: NBart Van Assche <bvanassche@acm.org>
Signed-off-by: NJason Gunthorpe <jgg@mellanox.com>
上级 08304d71
......@@ -720,7 +720,7 @@ static ssize_t ib_uverbs_write(struct file *filp, const char __user *buf,
* then the command request structure starts
* with a '__aligned u64 response' member.
*/
ret = get_user(response, (const u64 *)buf);
ret = get_user(response, (const u64 __user *)buf);
if (ret)
goto out_unlock;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册