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

Commit 891ae449 authored by Ravi Aravamudhan's avatar Ravi Aravamudhan
Browse files

diag: Set real time value correctly



Diag user space clients sends an IOCTL to get the real time value
from the driver. The driver was setting this value incorrectly. This
patch fixes this issue.

Change-Id: Ia9ff16e5b1affc05bb0f99b32e97fa80ec25aa14
Signed-off-by: default avatarRavi Aravamudhan <aravamud@codeaurora.org>
parent 38fb8d37
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -1096,7 +1096,6 @@ static int diag_ioctl_vote_real_time(unsigned long ioarg)
static int diag_ioctl_get_real_time(unsigned long ioarg)
{
	int result = -EINVAL;
	int real_time = 0;
	int retry_count = 0;
	int timer = 0;
	struct real_time_query_t rt_query;
@@ -1121,7 +1120,8 @@ static int diag_ioctl_get_real_time(unsigned long ioarg)
				       rt_query.proc, __func__);
				return -EINVAL;
			}
			real_time = driver->real_time_mode[rt_query.proc];
			rt_query.real_time =
				driver->real_time_mode[rt_query.proc];
			if (copy_to_user((void __user *)ioarg, &rt_query,
				sizeof(struct real_time_query_t)))
				return -EFAULT;