linux-rt-users.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] sched: don't clear PF_THREAD_BOUND in select_fallback_rq
@ 2013-04-25  9:01 Qiang Huang
  2013-05-03 20:46 ` Sebastian Andrzej Siewior
                   ` (2 more replies)
  0 siblings, 3 replies; 13+ messages in thread
From: Qiang Huang @ 2013-04-25  9:01 UTC (permalink / raw)
  To: Steven Rostedt, Thomas Gleixner; +Cc: linux-rt-users, Li Zefan, zhangwei

This is revert of "sched-clear-pf-thread-bound-on-fallback-rq.patch"
(commit 0d939066acdcb in v3.4-rt),.

Select_fallback_rq() can be easilly called during system boot, because
select_task_rq_fair() just return task_cpu(p) for bounded kernel threads,
which is 0 during system boot and not in tsk_cpus_allowed, so
select_fallback_rq() is called and PF_THREAD_BOUND is cleared. In my
box, 1/3 bounded kernel threads will clear that flag after boot.

And it will cause problems, for example:
# for pid in `ps -e -o pid`; do taskset -p -c 0-15 $pid; done
this command will cause system hung.

What's more, I don't see why we need to clear this flag any more,
because "cpu/rt: Rework cpu down for PREEMPT_RT" already remove the
optimization for PF_THREAD_BOUND on migrate_disable/enable.

Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
---
 kernel/sched/core.c |    6 ------
 1 files changed, 0 insertions(+), 6 deletions(-)

diff --git a/kernel/sched/core.c b/kernel/sched/core.c
index 751ec60..8db6e3b 100644
--- a/kernel/sched/core.c
+++ b/kernel/sched/core.c
@@ -1327,12 +1327,6 @@ out:
 		}
 	}

-	/*
-	 * Clear PF_THREAD_BOUND, otherwise we wreckage
-	 * migrate_disable/enable. See optimization for
-	 * PF_THREAD_BOUND tasks there.
-	 */
-	p->flags &= ~PF_THREAD_BOUND;
 	return dest_cpu;
 }

-- 1.7.1


^ permalink raw reply related	[flat|nested] 13+ messages in thread

end of thread, other threads:[~2013-06-28 11:57 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-04-25  9:01 [PATCH] sched: don't clear PF_THREAD_BOUND in select_fallback_rq Qiang Huang
2013-05-03 20:46 ` Sebastian Andrzej Siewior
2013-05-03 22:39   ` Luis Claudio R. Goncalves
2013-05-05  6:38     ` Qiang Huang
2013-05-05 14:44       ` Sven-Thorsten Dietrich
2013-05-06  0:49         ` Li Zefan
2013-05-06 10:44         ` Qiang Huang
2013-05-14 13:08 ` Luis Claudio R. Goncalves
2013-06-21 10:48   ` Sebastian Andrzej Siewior
2013-06-07 20:50 ` Sebastian Andrzej Siewior
2013-06-07 20:59   ` Sebastian Andrzej Siewior
2013-06-22  3:27     ` Qiang Huang
2013-06-28 11:57       ` Sebastian Andrzej Siewior

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).