* [tip:sched/locking] sched: Move wq_worker_waking to the correct site
@ 2011-04-14 8:32 tip-bot for Peter Zijlstra
2011-04-14 9:14 ` Peter Zijlstra
0 siblings, 1 reply; 3+ messages in thread
From: tip-bot for Peter Zijlstra @ 2011-04-14 8:32 UTC (permalink / raw)
To: linux-tip-commits; +Cc: linux-kernel, hpa, mingo, a.p.zijlstra, tj, tglx, mingo
Commit-ID: c2f7115e2e52a6c187b8c1f54f0e4970bb677be0
Gitweb: http://git.kernel.org/tip/c2f7115e2e52a6c187b8c1f54f0e4970bb677be0
Author: Peter Zijlstra <a.p.zijlstra@chello.nl>
AuthorDate: Wed, 13 Apr 2011 13:28:56 +0200
Committer: Ingo Molnar <mingo@elte.hu>
CommitDate: Thu, 14 Apr 2011 08:52:33 +0200
sched: Move wq_worker_waking to the correct site
wq_worker_waking_up() needs to match wq_worker_sleeping(), since the
latter is only called on deactivate, move the former near activate.
Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Tejun Heo <tj@kernel.org>
Link: http://lkml.kernel.org/n/top-t3m7n70n9frmv4pv2n5fwmov@git.kernel.org
Signed-off-by: Ingo Molnar <mingo@elte.hu>
---
kernel/sched.c | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/kernel/sched.c b/kernel/sched.c
index 55cc503..81ab58e 100644
--- a/kernel/sched.c
+++ b/kernel/sched.c
@@ -2421,6 +2421,10 @@ static inline void ttwu_activate(struct task_struct *p, struct rq *rq,
schedstat_inc(p, se.statistics.nr_wakeups_remote);
activate_task(rq, p, en_flags);
+
+ /* if a worker is waking up, notify workqueue */
+ if (p->flags & PF_WQ_WORKER)
+ wq_worker_waking_up(p, cpu_of(rq));
}
static inline void ttwu_post_activation(struct task_struct *p, struct rq *rq,
@@ -2445,9 +2449,6 @@ static inline void ttwu_post_activation(struct task_struct *p, struct rq *rq,
rq->idle_stamp = 0;
}
#endif
- /* if a worker is waking up, notify workqueue */
- if ((p->flags & PF_WQ_WORKER) && success)
- wq_worker_waking_up(p, cpu_of(rq));
}
/**
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [tip:sched/locking] sched: Move wq_worker_waking to the correct site
2011-04-14 8:32 [tip:sched/locking] sched: Move wq_worker_waking to the correct site tip-bot for Peter Zijlstra
@ 2011-04-14 9:14 ` Peter Zijlstra
2011-04-14 9:15 ` Peter Zijlstra
0 siblings, 1 reply; 3+ messages in thread
From: Peter Zijlstra @ 2011-04-14 9:14 UTC (permalink / raw)
To: mingo, hpa, linux-kernel, tj, tglx, mingo; +Cc: linux-tip-commits
On Thu, 2011-04-14 at 08:32 +0000, tip-bot for Peter Zijlstra wrote:
> Message-ID: <tip-c2f7115e2e52a6c187b8c1f54f0e4970bb677be0@git.kernel.org>
> Link: http://lkml.kernel.org/n/top-t3m7n70n9frmv4pv2n5fwmov@git.kernel.org
hpa, that Link: magic doesn't appear to have done the trick..
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [tip:sched/locking] sched: Move wq_worker_waking to the correct site
2011-04-14 9:14 ` Peter Zijlstra
@ 2011-04-14 9:15 ` Peter Zijlstra
0 siblings, 0 replies; 3+ messages in thread
From: Peter Zijlstra @ 2011-04-14 9:15 UTC (permalink / raw)
To: mingo; +Cc: hpa, linux-kernel, tj, tglx, mingo, linux-tip-commits
On Thu, 2011-04-14 at 11:14 +0200, Peter Zijlstra wrote:
>
> > Link:
> http://lkml.kernel.org/n/top-t3m7n70n9frmv4pv2n5fwmov@git.kernel.org
>
> hpa, that Link: magic doesn't appear to have done the trick..
Damn, I fat fingered things.. I wrote n/top-
/me goes fix
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2011-04-14 9:16 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-04-14 8:32 [tip:sched/locking] sched: Move wq_worker_waking to the correct site tip-bot for Peter Zijlstra
2011-04-14 9:14 ` Peter Zijlstra
2011-04-14 9:15 ` Peter Zijlstra
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.