dsp: avtimer: add __user attribute to identify userspace address
Add __user attribute for avtimer_ioctl's input parameter ioctl_param to explicitly identify user space pointer in copy_to_user. Change-Id: I59fa9d39e5ec3ff9cde3a06af9da2d38e36d557d Signed-off-by: Xiaoyu Ye <benyxy@codeaurora.org>
This commit is contained in:
parent
d88c1e68dc
commit
b424e05893
1 changed files with 1 additions and 1 deletions
|
@ -345,7 +345,7 @@ static long avtimer_ioctl(struct file *file, unsigned int ioctl_num,
|
|||
|
||||
pr_debug_ratelimited("%s: AV Timer tick: time %llx\n",
|
||||
__func__, avtimer_tick);
|
||||
if (copy_to_user((void *) ioctl_param, &avtimer_tick,
|
||||
if (copy_to_user((void __user *)ioctl_param, &avtimer_tick,
|
||||
sizeof(avtimer_tick))) {
|
||||
pr_err("%s: copy_to_user failed\n", __func__);
|
||||
return -EFAULT;
|
||||
|
|
Loading…
Add table
Reference in a new issue