From: Ingo Molnar <mingo@kernel.org>
To: Srikar Dronamraju <srikar@linux.vnet.ibm.com>
Cc: Rik van Riel <riel@redhat.com>,
Peter Zijlstra <peterz@infradead.org>,
linux-kernel@vger.kernel.org, Mel Gorman <mgorman@suse.de>
Subject: Re: [PATCH] sched/numa: Restore sched feature NUMA to its earlier avatar.
Date: Sat, 11 Jul 2015 10:53:53 +0200 [thread overview]
Message-ID: <20150711085352.GA23597@gmail.com> (raw)
In-Reply-To: <20150710172802.GL26095@linux.vnet.ibm.com>
* Srikar Dronamraju <srikar@linux.vnet.ibm.com> wrote:
> > > > Which in itself is confusing: WTH do we have a generic switch called 'NUMA' and
> > > > then have it disabled?
> > >
> > > NUMA feature gets enabled on multi-node boxes because of
> > >
> > > start_kernel() -> numa_policy_init() -> check_numabalancing_enable() ->
> > > set_numabalancing_state() -> sched_feat_set("NUMA");
> >
> > Ugh, that is nonsensical!
> >
> > If CONFIG_SCHED_DEBUG is disabled then sched_features is a constant value:
> >
> > # define const_debug const
> >
> > ...
> >
> > extern const_debug unsigned int sysctl_sched_features;
> >
> > sched_features are _only_ meant for debugging. They turn into an unchangeable set
> > of features when SCHED_DEBUG is disabled - and that is very much by design.
> >
> > The whole set_numabalancing_state() muck needs to be fixed.
>
> Would something like the below suffice. If yes I can send out a formal
> patch for the same. Here we are moving numabalancing_enabled variable to
> common i.e for both CONFIG_SCHED_DEBUG and !CONFIG_SCHED_DEBUG.
>
> Also removing sched_feat_numa because its no more getting used.
> numabalancing_enabled is already being used similarly in task_tick_fair
> and task_numa_fault.
>
> -------------->8------------------------------------------------------8<--------------
>
> kernel/sched/core.c | 5 +++--
> kernel/sched/fair.c | 2 +-
> kernel/sched/sched.h | 6 ------
> 3 files changed, 4 insertions(+), 9 deletions(-)
>
> diff --git a/kernel/sched/core.c b/kernel/sched/core.c
> index 78b4bad10..69ccbda4 100644
> --- a/kernel/sched/core.c
> +++ b/kernel/sched/core.c
> @@ -2059,17 +2059,18 @@ static void __sched_fork(unsigned long clone_flags, struct task_struct *p)
> }
>
> #ifdef CONFIG_NUMA_BALANCING
> +__read_mostly bool numabalancing_enabled;
s/numabalancing_enabled/sched_numa_balancing
Other than that this would be OK.
Thanks,
Ingo
next prev parent reply other threads:[~2015-07-11 8:53 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-07-08 13:20 [PATCH] sched/numa: Restore sched feature NUMA to its earlier avatar Srikar Dronamraju
2015-07-08 13:50 ` Rik van Riel
2015-07-08 13:56 ` Ingo Molnar
2015-07-08 15:26 ` Rik van Riel
2015-07-09 6:29 ` Ingo Molnar
2015-07-09 6:57 ` Srikar Dronamraju
2015-07-09 8:01 ` Ingo Molnar
2015-07-10 17:28 ` Srikar Dronamraju
2015-07-11 8:53 ` Ingo Molnar [this message]
2015-07-08 16:06 ` Srikar Dronamraju
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=20150711085352.GA23597@gmail.com \
--to=mingo@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mgorman@suse.de \
--cc=peterz@infradead.org \
--cc=riel@redhat.com \
--cc=srikar@linux.vnet.ibm.com \
/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.