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

Commit 256be6b2 authored by Pavankumar Kondeti's avatar Pavankumar Kondeti
Browse files

sched: Remove unnecessary calls to cpufreq_update_util()



The cpufreq update util calls after update_task_ravg() are
no longer needed. This is taken care in WALT when a window is
rolled over. Besides these calls were ineffectual since
SCHED_CPUFREQ_WALT wasn't passed in the flag parameter.

Change-Id: I28ac40b33662584ec9f8fff116e66a6f33a8d010
Signed-off-by: default avatarPavankumar Kondeti <pkondeti@codeaurora.org>
parent 7fa1540f
Loading
Loading
Loading
Loading
+0 −4
Original line number Diff line number Diff line
@@ -2174,7 +2174,6 @@ try_to_wake_up(struct task_struct *p, unsigned int state, int wake_flags)
	wallclock = ktime_get_ns();
	update_task_ravg(rq->curr, rq, TASK_UPDATE, wallclock, 0);
	update_task_ravg(p, rq, TASK_WAKE, wallclock, 0);
	cpufreq_update_util(rq, 0);
	raw_spin_unlock(&rq->lock);

	rcu_read_lock();
@@ -2263,7 +2262,6 @@ static void try_to_wake_up_local(struct task_struct *p, struct pin_cookie cookie

		update_task_ravg(rq->curr, rq, TASK_UPDATE, wallclock, 0);
		update_task_ravg(p, rq, TASK_WAKE, wallclock, 0);
		cpufreq_update_util(rq, 0);
		ttwu_activate(rq, p, ENQUEUE_WAKEUP);
		note_task_waking(p, wallclock);
	}
@@ -3636,7 +3634,6 @@ static void __sched notrace __schedule(bool preempt)

		update_task_ravg(prev, rq, PUT_PREV_TASK, wallclock, 0);
		update_task_ravg(next, rq, PICK_NEXT_TASK, wallclock, 0);
		cpufreq_update_util(rq, 0);
		rq->nr_switches++;
		rq->curr = next;
		++*switch_count;
@@ -3645,7 +3642,6 @@ static void __sched notrace __schedule(bool preempt)
		rq = context_switch(rq, prev, next, cookie); /* unlocks the rq */
	} else {
		update_task_ravg(prev, rq, TASK_UPDATE, wallclock, 0);
		cpufreq_update_util(rq, 0);
		lockdep_unpin_lock(&rq->lock, cookie);
		raw_spin_unlock_irq(&rq->lock);
	}