public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Ingo Molnar <mingo@elte.hu>
To: Mahesh Salgaonkar <mahesh@linux.vnet.ibm.com>
Cc: Linux Kernel <linux-kernel@vger.kernel.org>,
	Suresh B Siddha <suresh.b.siddha@intel.com>,
	Venkatesh Pallipadi <venkatesh.pallipadi@intel.com>,
	Peter Zijlstra <a.p.zijlstra@chello.nl>
Subject: Re: [PATCH] Don't export sched_mc_power_savings in laptops
Date: Sun, 30 Nov 2008 18:40:34 +0100	[thread overview]
Message-ID: <20081130174034.GA28614@elte.hu> (raw)
In-Reply-To: <1227957612-7000-1-git-send-email-mahesh@linux.vnet.ibm.com>


* Mahesh Salgaonkar <mahesh@linux.vnet.ibm.com> wrote:

>         Fix to prevent sched_mc_power_saving from being exported through sysfs
>         for multicore single socket (Laptop).
>     
>         CPU core map of the boot cpu should be equal to possible number
>         of cpus for single socket system.
>     
>         This fix has been developed at FOSS.in kernel workout.
>     
>         Signed-off-by: Mahesh Salgaonkar <mahesh@linux.vnet.ibm.com>
> 
> diff --git a/arch/x86/include/asm/topology.h b/arch/x86/include/asm/topology.h
> index 4850e4b..4adc830 100644
> --- a/arch/x86/include/asm/topology.h
> +++ b/arch/x86/include/asm/topology.h
> @@ -239,7 +239,7 @@ struct pci_bus;
>  void set_pci_bus_resources_arch_default(struct pci_bus *b);
>  
>  #ifdef CONFIG_SMP
> -#define mc_capable()			(boot_cpu_data.x86_max_cores > 1)
> +#define mc_capable()	(cpus_weight(per_cpu(cpu_core_map,0)) != nr_cpu_ids)

hm, dunno. sched_mc_power_savings should have no effect on single-socket 
systems, right? So the knob should have no effect.

	Ingo

  parent reply	other threads:[~2008-11-30 17:41 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-11-29 11:20 [PATCH] Don't export sched_mc_power_savings in laptops Mahesh Salgaonkar
2008-11-29 11:30 ` Mahesh Jagannath Salgaonkar
2008-11-30 17:40 ` Ingo Molnar [this message]
2008-12-01  6:50   ` Mahesh Jagannath Salgaonkar
2008-12-01  7:44     ` Ingo Molnar

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=20081130174034.GA28614@elte.hu \
    --to=mingo@elte.hu \
    --cc=a.p.zijlstra@chello.nl \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mahesh@linux.vnet.ibm.com \
    --cc=suresh.b.siddha@intel.com \
    --cc=venkatesh.pallipadi@intel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox