From: Darren Hart <dvhltc@us.ibm.com>
To: Peter Zijlstra <peterz@infradead.org>
Cc: Ingo Molnar <mingo@elte.hu>, "lkml, " <linux-kernel@vger.kernel.org>
Subject: Dynamically determine if kernel includes CFS Scheduler
Date: Fri, 06 Mar 2009 12:44:30 -0800 [thread overview]
Message-ID: <49B18B2E.606@us.ibm.com> (raw)
I've received an internal request for a means to determine at run-time
if the CFS scheduler is included in the running kernel. Looking through
the git commit log and the /proc/sys/kernel filesystem, I think I see
two approaches:
1) stat("/proc/sys/kernel/sched_compat_yield")
This confirms 2.6.23-rc7 kernel or later which definitely has the CFS
scheduler and this functionality is of interest anyway.
2) Test if the kernel version is >= 2.6.22 which is where I believe CFS
landed.
Any guesses as to how robust/future-proof approach #1 would be?
--
Darren Hart
IBM Linux Technology Center
Real-Time Linux Team
next reply other threads:[~2009-03-06 20:44 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-03-06 20:44 Darren Hart [this message]
2009-03-06 21:01 ` Dynamically determine if kernel includes CFS Scheduler Peter Zijlstra
2009-03-06 22:53 ` Sitsofe Wheeler
2009-03-06 23:01 ` Darren Hart
2009-03-06 23:08 ` Sitsofe Wheeler
2009-03-07 0:17 ` Darren Hart
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=49B18B2E.606@us.ibm.com \
--to=dvhltc@us.ibm.com \
--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 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.