* Re: 2.6.16-rc6-mm2 uninitialized online_policy_cpus.bits[0]
[not found] ` <200603191209.54946.kernel@kolivas.org>
@ 2006-03-19 1:35 ` Andrew Morton
2006-03-19 2:37 ` Con Kolivas
2006-03-19 6:13 ` Venkatesh Pallipadi
0 siblings, 2 replies; 3+ messages in thread
From: Andrew Morton @ 2006-03-19 1:35 UTC (permalink / raw)
To: Con Kolivas; +Cc: linux-kernel, Venkatesh Pallipadi, Len Brown, linux-acpi
Con Kolivas <kernel@kolivas.org> wrote:
>
> Wonder if this is related to rc6's oops?
> gcc 4.0.3
>
> CC [M] arch/i386/kernel/cpu/cpufreq/speedstep-centrino.o
> arch/i386/kernel/cpu/cpufreq/speedstep-centrino.c: In function
> 'centrino_target':
> include/linux/bitmap.h:170: warning: 'online_policy_cpus.bits[0]' is used
> uninitialized in this function
> CC [M] arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.o
> arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.c: In function
> 'acpi_cpufreq_target':
> include/linux/bitmap.h:170: warning: 'online_policy_cpus.bits[0]' is used
> uninitialized in this function
Well conceivably. That warning is a consequence of my quick hack to make
the ACPI tree compile on uniprocessor.
ftp://ftp.kernel.org/pub/linux/kernel/people/akpm/patches/2.6/2.6.16-rc6/2.6.16-rc6-mm2/broken-out/git-acpi-up-fix.patch
My patch is, as the compiler points out, wrong.
I've sent that patch two or three times to the APCI maintainers, to the
ACPI mailing list and to the author of the original buggy patch. The
response thus far has been dead silence.
IOW, despite my efforts, the ACPI tree has been in a non-compiling state on
uniprocessor since February 11.
This is pathetic. People are trying to get things done here and ACPI is
getting in the way. But *need* to get the ACPI development tree out for
people to test else we'll never be able to take another ACPI update into
mainline.
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: 2.6.16-rc6-mm2 uninitialized online_policy_cpus.bits[0]
2006-03-19 1:35 ` 2.6.16-rc6-mm2 uninitialized online_policy_cpus.bits[0] Andrew Morton
@ 2006-03-19 2:37 ` Con Kolivas
2006-03-19 6:13 ` Venkatesh Pallipadi
1 sibling, 0 replies; 3+ messages in thread
From: Con Kolivas @ 2006-03-19 2:37 UTC (permalink / raw)
To: Andrew Morton; +Cc: linux-kernel, Venkatesh Pallipadi, Len Brown, linux-acpi
On Sunday 19 March 2006 12:35, Andrew Morton wrote:
> Con Kolivas <kernel@kolivas.org> wrote:
> > Wonder if this is related to rc6's oops?
> > gcc 4.0.3
> >
> > CC [M] arch/i386/kernel/cpu/cpufreq/speedstep-centrino.o
> > arch/i386/kernel/cpu/cpufreq/speedstep-centrino.c: In function
> > 'centrino_target':
> > include/linux/bitmap.h:170: warning: 'online_policy_cpus.bits[0]' is
> > used uninitialized in this function
> > CC [M] arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.o
> > arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.c: In function
> > 'acpi_cpufreq_target':
> > include/linux/bitmap.h:170: warning: 'online_policy_cpus.bits[0]' is
> > used uninitialized in this function
>
> Well conceivably. That warning is a consequence of my quick hack to make
> the ACPI tree compile on uniprocessor.
>
> ftp://ftp.kernel.org/pub/linux/kernel/people/akpm/patches/2.6/2.6.16-rc6/2.
>6.16-rc6-mm2/broken-out/git-acpi-up-fix.patch
>
> My patch is, as the compiler points out, wrong.
>
> I've sent that patch two or three times to the APCI maintainers, to the
> ACPI mailing list and to the author of the original buggy patch. The
> response thus far has been dead silence.
Well this will end up being the wrong place to do it but I needed it to work
now so this patch fixes it for me. Dunno what else it will break. Works on
a couple of configs fine.
Cheers,
Con
---
Hacky workaround for cpu_online_map not being defined
arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.c | 2 --
arch/i386/kernel/cpu/cpufreq/speedstep-centrino.c | 2 --
kernel/sched.c | 4 ++++
3 files changed, 4 insertions(+), 4 deletions(-)
Index: linux-2.6.16-rc6-mm2/arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.c
===================================================================
--- linux-2.6.16-rc6-mm2.orig/arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.c 2006-03-19 11:15:05.000000000 +1100
+++ linux-2.6.16-rc6-mm2/arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.c 2006-03-19 12:45:56.000000000 +1100
@@ -225,10 +225,8 @@ acpi_cpufreq_target (
freqs.old = data->freq_table[cur_state].frequency;
freqs.new = data->freq_table[next_state].frequency;
-#ifdef CONFIG_SMP
/* cpufreq holds the hotplug lock, so we are safe from here on */
cpus_and(online_policy_cpus, cpu_online_map, policy->cpus);
-#endif
for_each_cpu_mask(j, online_policy_cpus) {
freqs.cpu = j;
Index: linux-2.6.16-rc6-mm2/arch/i386/kernel/cpu/cpufreq/speedstep-centrino.c
===================================================================
--- linux-2.6.16-rc6-mm2.orig/arch/i386/kernel/cpu/cpufreq/speedstep-centrino.c 2006-03-19 11:15:05.000000000 +1100
+++ linux-2.6.16-rc6-mm2/arch/i386/kernel/cpu/cpufreq/speedstep-centrino.c 2006-03-19 12:45:42.000000000 +1100
@@ -652,10 +652,8 @@ static int centrino_target (struct cpufr
return -EINVAL;
}
-#ifdef CONFIG_SMP
/* cpufreq holds the hotplug lock, so we are safe from here on */
cpus_and(online_policy_cpus, cpu_online_map, policy->cpus);
-#endif
saved_mask = current->cpus_allowed;
first_cpu = 1;
Index: linux-2.6.16-rc6-mm2/kernel/sched.c
===================================================================
--- linux-2.6.16-rc6-mm2.orig/kernel/sched.c 2006-03-19 13:25:25.000000000 +1100
+++ linux-2.6.16-rc6-mm2/kernel/sched.c 2006-03-19 13:25:36.000000000 +1100
@@ -6366,6 +6366,10 @@ void __init sched_init_smp(void)
init_sched_domain_sysctl();
}
#else
+/* bitmap of online cpus */
+cpumask_t cpu_online_map __read_mostly;
+EXPORT_SYMBOL(cpu_online_map);
+
void __init sched_init_smp(void)
{
}
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: 2.6.16-rc6-mm2 uninitialized online_policy_cpus.bits[0]
2006-03-19 1:35 ` 2.6.16-rc6-mm2 uninitialized online_policy_cpus.bits[0] Andrew Morton
2006-03-19 2:37 ` Con Kolivas
@ 2006-03-19 6:13 ` Venkatesh Pallipadi
1 sibling, 0 replies; 3+ messages in thread
From: Venkatesh Pallipadi @ 2006-03-19 6:13 UTC (permalink / raw)
To: Andrew Morton
Cc: Con Kolivas, linux-kernel, Venkatesh Pallipadi, Len Brown,
linux-acpi
On Sat, Mar 18, 2006 at 05:35:12PM -0800, Andrew Morton wrote:
> Con Kolivas <kernel@kolivas.org> wrote:
> >
> > Wonder if this is related to rc6's oops?
> > gcc 4.0.3
> >
> > CC [M] arch/i386/kernel/cpu/cpufreq/speedstep-centrino.o
> > arch/i386/kernel/cpu/cpufreq/speedstep-centrino.c: In function
> > 'centrino_target':
> > include/linux/bitmap.h:170: warning: 'online_policy_cpus.bits[0]' is used
> > uninitialized in this function
> > CC [M] arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.o
> > arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.c: In function
> > 'acpi_cpufreq_target':
> > include/linux/bitmap.h:170: warning: 'online_policy_cpus.bits[0]' is used
> > uninitialized in this function
>
> Well conceivably. That warning is a consequence of my quick hack to make
> the ACPI tree compile on uniprocessor.
>
> ftp://ftp.kernel.org/pub/linux/kernel/people/akpm/patches/2.6/2.6.16-rc6/2.6.16-rc6-mm2/broken-out/git-acpi-up-fix.patch
>
> My patch is, as the compiler points out, wrong.
>
> I've sent that patch two or three times to the APCI maintainers, to the
> ACPI mailing list and to the author of the original buggy patch. The
> response thus far has been dead silence.
>
> IOW, despite my efforts, the ACPI tree has been in a non-compiling state on
> uniprocessor since February 11.
>
> This is pathetic. People are trying to get things done here and ACPI is
> getting in the way.
Oops. Sorry. It is me who dropped the ball here. I somehow assumed that
your original patch fixed the issue and didn't look at the actual code.
Here is the patch against mm.
Thanks,
Venki
Fix the UP build breakage in acpi-cpufreq and speedstep-centrino due to
previous p-state software coordination patch.
Signed-off-by: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com>
diff -purN linux-2.6.15/arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.c linux-2.6.15-new/arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.c
--- linux-2.6.15/arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.c 2006-03-18 19:41:25.000000000 -0800
+++ linux-2.6.15-new/arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.c 2006-03-18 19:48:10.000000000 -0800
@@ -225,9 +225,11 @@ acpi_cpufreq_target (
freqs.old = data->freq_table[cur_state].frequency;
freqs.new = data->freq_table[next_state].frequency;
-#ifdef CONFIG_SMP
+#ifdef CONFIG_HOTPLUG_CPU
/* cpufreq holds the hotplug lock, so we are safe from here on */
cpus_and(online_policy_cpus, cpu_online_map, policy->cpus);
+#else
+ online_policy_cpus = policy->cpus;
#endif
for_each_cpu_mask(j, online_policy_cpus) {
diff -purN linux-2.6.15/arch/i386/kernel/cpu/cpufreq/speedstep-centrino.c linux-2.6.15-new/arch/i386/kernel/cpu/cpufreq/speedstep-centrino.c
--- linux-2.6.15/arch/i386/kernel/cpu/cpufreq/speedstep-centrino.c 2006-03-18 19:41:25.000000000 -0800
+++ linux-2.6.15-new/arch/i386/kernel/cpu/cpufreq/speedstep-centrino.c 2006-03-18 19:47:46.000000000 -0800
@@ -652,9 +652,11 @@ static int centrino_target (struct cpufr
return -EINVAL;
}
-#ifdef CONFIG_SMP
+#ifdef CONFIG_HOTPLUG_CPU
/* cpufreq holds the hotplug lock, so we are safe from here on */
cpus_and(online_policy_cpus, cpu_online_map, policy->cpus);
+#else
+ online_policy_cpus = policy->cpus;
#endif
saved_mask = current->cpus_allowed;
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2006-03-19 6:13 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <20060318044056.350a2931.akpm@osdl.org>
[not found] ` <200603191209.54946.kernel@kolivas.org>
2006-03-19 1:35 ` 2.6.16-rc6-mm2 uninitialized online_policy_cpus.bits[0] Andrew Morton
2006-03-19 2:37 ` Con Kolivas
2006-03-19 6:13 ` Venkatesh Pallipadi
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox