summaryrefslogtreecommitdiff
path: root/kernel
diff options
context:
space:
mode:
authorVenkatesh Pallipadi <venki@google.com>2011-02-10 10:23:27 +0100
committerGreg Kroah-Hartman <gregkh@suse.de>2011-02-17 15:37:25 -0800
commit9b511401474c4518d214a02a8064b67e038a8e38 (patch)
tree91b23e0250c94d41fd74f1c5660c5d575e41e532 /kernel
parent82f7e90e5e68fdaa3c72f3522444f020fd62d7a7 (diff)
sched: Add a PF flag for ksoftirqd identification
Commit: 6cdd5199daf0cb7b0fcc8dca941af08492612887 upstream To account softirq time cleanly in scheduler, we need to identify whether softirq is invoked in ksoftirqd context or softirq at hardirq tail context. Add PF_KSOFTIRQD for that purpose. As all PF flag bits are currently taken, create space by moving one of the infrequently used bits (PF_THREAD_BOUND) down in task_struct to be along with some other state fields. Signed-off-by: Venkatesh Pallipadi <venki@google.com> Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl> LKML-Reference: <1286237003-12406-4-git-send-email-venki@google.com> Signed-off-by: Ingo Molnar <mingo@elte.hu> Signed-off-by: Mike Galbraith <efault@gmx.de> Acked-by: Peter Zijlstra <a.p.zijlstra@chello.nl> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'kernel')
-rw-r--r--kernel/softirq.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/kernel/softirq.c b/kernel/softirq.c
index 0ed83430b077..0a617de20434 100644
--- a/kernel/softirq.c
+++ b/kernel/softirq.c
@@ -718,6 +718,7 @@ static int ksoftirqd(void * __bind_cpu)
{
set_current_state(TASK_INTERRUPTIBLE);
+ current->flags |= PF_KSOFTIRQD;
while (!kthread_should_stop()) {
preempt_disable();
if (!local_softirq_pending()) {