mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Yong Zhang <yong.zhang0@gmail.com>
To: linux-kernel@vger.kernel.org
Cc: Ingo Molnar <mingo@elte.hu>,
	Peter Zijlstra <peterz@infradead.org>,
	Mike Galbraith <efault@gmx.de>
Subject: [PATCH 2/5] sched: hide cfs_rq of autogroup if autogroup is disabled
Date: Sun, 20 Feb 2011 15:08:13 +0800	[thread overview]
Message-ID: <1298185696-4403-3-git-send-email-yong.zhang0@gmail.com> (raw)
In-Reply-To: <1298185696-4403-1-git-send-email-yong.zhang0@gmail.com>

When autogroup is disabled, sched_debug will show
all of the cfs_rq of autogroup by name "cfs_rq[0]:"
Actually that doesn't make sense and not necessary
to be showed.

Signed-off-by: Yong Zhang <yong.zhang0@gmail.com>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Mike Galbraith <efault@gmx.de>
---
 kernel/sched_debug.c |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/kernel/sched_debug.c b/kernel/sched_debug.c
index eb6cb8e..121e2a2 100644
--- a/kernel/sched_debug.c
+++ b/kernel/sched_debug.c
@@ -169,6 +169,12 @@ void print_cfs_rq(struct seq_file *m, int cpu, struct cfs_rq *cfs_rq)
 	struct sched_entity *last;
 	unsigned long flags;
 
+#ifdef CONFIG_SCHED_AUTOGROUP
+	int enabled = ACCESS_ONCE(sysctl_sched_autogroup_enabled);
+
+	if (task_group_is_autogroup(cfs_rq->tg) && !enabled)
+		return;
+#endif
 #ifdef CONFIG_FAIR_GROUP_SCHED
 	SEQ_printf(m, "\ncfs_rq[%d]:%s\n", cpu, task_group_path(cfs_rq->tg));
 #else
-- 
1.7.1


  parent reply	other threads:[~2011-02-20  7:08 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-02-20  7:08 [PATCH 0/5] autogroup runtime enable/disable tuning fix Yong Zhang
2011-02-20  7:08 ` [PATCH 1/5] sched, autogroup, sysctl: use proc_dointvec_minmax instead Yong Zhang
2011-02-23 12:05   ` [tip:sched/core] sched, autogroup, sysctl: Use proc_dointvec_minmax() instead tip-bot for Yong Zhang
2011-02-20  7:08 ` Yong Zhang [this message]
2011-02-20  7:08 ` [PATCH 3/5] sched, autogroup: stop going ahead if autogroup is disabled Yong Zhang
2011-02-23 12:05   ` [tip:sched/core] sched, autogroup: Stop " tip-bot for Yong Zhang
2011-02-20  7:08 ` [PATCH 4/5] sched: refactor task_group() Yong Zhang
2011-02-20  7:08 ` [PATCH 5/5] sched, autogroup: runtime enable/disable tuning fix Yong Zhang
2011-02-20 13:09   ` Mike Galbraith
2011-02-20 14:10     ` Yong Zhang
2011-02-20 17:22       ` Mike Galbraith
2011-02-21  3:13         ` Mike Galbraith
2011-02-21  9:05           ` Yong Zhang
2011-02-21 16:36         ` Peter Zijlstra
2011-02-21 21:12           ` Ingo Molnar
2011-02-22  3:13           ` Yong Zhang
2011-02-22  9:56             ` Peter Zijlstra
2011-02-22 12:10               ` [PATCH V2] sched, autogroup: always show autogroup name in sched_debug Yong Zhang
2011-02-22 14:02                 ` Mike Galbraith
2011-02-22 14:32                   ` Yong Zhang
2011-02-23 12:06                   ` [tip:sched/core] sched, autogroup: Stop claiming ownership of the root task group tip-bot for Mike Galbraith

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1298185696-4403-3-git-send-email-yong.zhang0@gmail.com \
    --to=yong.zhang0@gmail.com \
    --cc=efault@gmx.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=peterz@infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®