Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b424e058 authored by Xiaoyu Ye's avatar Xiaoyu Ye
Browse files

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: default avatarXiaoyu Ye <benyxy@codeaurora.org>
parent d88c1e68
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -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;