|
@@ -1851,6 +1851,8 @@ void set_task_cpu(struct task_struct *p, unsigned int new_cpu)
|
|
|
|
|
|
clock_offset = old_rq->clock - new_rq->clock;
|
|
|
|
|
|
+ trace_sched_migrate_task(p, task_cpu(p), new_cpu);
|
|
|
+
|
|
|
#ifdef CONFIG_SCHEDSTATS
|
|
|
if (p->se.wait_start)
|
|
|
p->se.wait_start -= clock_offset;
|
|
@@ -2868,7 +2870,6 @@ static void sched_migrate_task(struct task_struct *p, int dest_cpu)
|
|
|
|| unlikely(!cpu_active(dest_cpu)))
|
|
|
goto out;
|
|
|
|
|
|
- trace_sched_migrate_task(rq, p, dest_cpu);
|
|
|
/* force the process onto the specified CPU */
|
|
|
if (migrate_task(p, dest_cpu, &req)) {
|
|
|
/* Need to wait for migration thread (might exit: take ref). */
|