Skip to content

Commit 23f41ee

Browse files
Peter ZijlstraIngo Molnar
authored andcommitted
sched: Rename ttwu_post_activation() to ttwu_do_wakeup()
The ttwu_post_activation() code does the core wakeup, it sets TASK_RUNNING and performs wakeup-preemption, so give is a more descriptive name. Reviewed-by: Frank Rowand <frank.rowand@am.sony.com> Cc: Mike Galbraith <efault@gmx.de> Cc: Nick Piggin <npiggin@kernel.dk> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Ingo Molnar <mingo@elte.hu> Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/20110405152729.434609705@chello.nl
1 parent b84cb5d commit 23f41ee

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

kernel/sched.c

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2456,8 +2456,11 @@ static void ttwu_activate(struct rq *rq, struct task_struct *p, int en_flags)
24562456
wq_worker_waking_up(p, cpu_of(rq));
24572457
}
24582458

2459+
/*
2460+
* Mark the task runnable and perform wakeup-preemption.
2461+
*/
24592462
static void
2460-
ttwu_post_activation(struct task_struct *p, struct rq *rq, int wake_flags)
2463+
ttwu_do_wakeup(struct rq *rq, struct task_struct *p, int wake_flags)
24612464
{
24622465
trace_sched_wakeup(p, true);
24632466
check_preempt_curr(rq, p, wake_flags);
@@ -2562,7 +2565,7 @@ try_to_wake_up(struct task_struct *p, unsigned int state, int wake_flags)
25622565

25632566
ttwu_activate(rq, p, ENQUEUE_WAKEUP | ENQUEUE_WAKING);
25642567
out_running:
2565-
ttwu_post_activation(p, rq, wake_flags);
2568+
ttwu_do_wakeup(rq, p, wake_flags);
25662569
success = 1;
25672570
__task_rq_unlock(rq);
25682571

@@ -2602,7 +2605,7 @@ static void try_to_wake_up_local(struct task_struct *p)
26022605
if (!p->on_rq)
26032606
ttwu_activate(rq, p, ENQUEUE_WAKEUP);
26042607

2605-
ttwu_post_activation(p, rq, 0);
2608+
ttwu_do_wakeup(rq, p, 0);
26062609
ttwu_stat(p, smp_processor_id(), 0);
26072610
out:
26082611
raw_spin_unlock(&p->pi_lock);

0 commit comments

Comments
 (0)