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

Commit f600d8b9 authored by Maulik Shah's avatar Maulik Shah Committed by Kyle Yan
Browse files

msm-core: Move get_user out side critical section



get_user is not needed inside critical section. Move
it outside to avoid kernel crash due to sleeping
function called from invalid context.

Change-Id: I29a54dca6620dc75356067ce6ff9a0931b4d0724
Signed-off-by: default avatarMaulik Shah <mkshah@codeaurora.org>
parent a6a26ac3
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -428,8 +428,8 @@ static int update_userspace_power(struct sched_params __user *argp)
	/* Copy the same power values for all the cpus in the cpumask
	 * argp->cpumask within the cluster (argp->cluster)
	 */
	spin_lock(&update_lock);
	get_user(cpumask, &argp->cpumask);
	spin_lock(&update_lock);
	for (i = 0; i < MAX_CORES_PER_CLUSTER; i++, cpumask >>= 1) {
		if (!(cpumask & 0x01))
			continue;