* p4_clockmod broken in 2.6.16-rc? kernels
@ 2006-03-09 6:11 Mike Galbraith
0 siblings, 0 replies; 6+ messages in thread
From: Mike Galbraith @ 2006-03-09 6:11 UTC (permalink / raw)
To: cpufreq; +Cc: davej
Greetings,
As subject says, it appears to be broken for at least one single P4 HT
system, namely mine. 2.6.15 works fine.
With a UP compiled kernel, it fails completely, due to CPU0 failure to
initialize. With an SMP compiled kernel, CPU0 fails, but the sibling
initializes. Nothing good happens afterward though. See debug
(cpufreq.debug=7) output below.
Cheers,
-Mike
cpufreq-core: trying to register driver p4-clockmod
cpufreq-core: adding CPU 0
p4-clockmod: has errata -- disabling frequencies lower than 2ghz
speedstep-lib: x86: f, model: 2
speedstep-lib: ebx value is 9, x86_mask is 9
speedstep-lib: P4 - MSR_EBC_FREQUENCY_ID: 0xf12000f 0x0
speedstep-lib: P4 - FSB 200000 kHz; Multiplier 15; Speed 3000000 kHz
freq-table: setting show_table for cpu 0 to c14bd800
freq-table: table entry 0 is invalid, skipping
freq-table: table entry 1 is invalid, skipping
freq-table: table entry 2 is invalid, skipping
freq-table: table entry 3 is invalid, skipping
freq-table: table entry 4 is invalid, skipping
freq-table: table entry 5 is invalid, skipping
freq-table: table entry 6 is invalid, skipping
freq-table: table entry 7 is invalid, skipping
freq-table: table entry 8 is invalid, skipping
cpufreq-core: initialization failed
cpufreq-core: adding CPU 1
p4-clockmod: has errata -- disabling frequencies lower than 2ghz
speedstep-lib: x86: f, model: 2
speedstep-lib: ebx value is 9, x86_mask is 9
speedstep-lib: P4 - MSR_EBC_FREQUENCY_ID: 0xf12000f 0x0
speedstep-lib: P4 - FSB 200000 kHz; Multiplier 15; Speed 3000000 kHz
freq-table: setting show_table for cpu 1 to c14bd800
freq-table: table entry 0 is invalid, skipping
freq-table: table entry 1: 375000 kHz, 1 index
freq-table: table entry 2: 750000 kHz, 2 index
freq-table: table entry 3: 1125000 kHz, 3 index
freq-table: table entry 4: 1500000 kHz, 4 index
freq-table: table entry 5: 1875000 kHz, 5 index
freq-table: table entry 6: 2250000 kHz, 6 index
freq-table: table entry 7: 2625000 kHz, 7 index
freq-table: table entry 8: 3000000 kHz, 8 index
cpufreq-core: setting new policy for CPU 1: 375000 - 3000000 kHz
freq-table: request for verification of policy (375000 - 3000000 kHz) for cpu 1
freq-table: verification lead to (375000 - 3000000 kHz) for cpu 1
freq-table: request for verification of policy (375000 - 3000000 kHz) for cpu 1
freq-table: verification lead to (375000 - 3000000 kHz) for cpu 1
cpufreq-core: new min and max freqs are 375000 - 3000000 kHz
cpufreq-core: governor switch
cpufreq-core: __cpufreq_governor for CPU 1, event 1
performance: setting to 3000000 kHz because of event 1
cpufreq-core: target for CPU 1: 3000000 kHz, relation 1
freq-table: request for target 3000000 kHz (relation: 1) for cpu 1
freq-table: target is 8 (3000000 kHz, 8)
cpufreq-core: governor: change or update limits
cpufreq-core: __cpufreq_governor for CPU 1, event 3
performance: setting to 3000000 kHz because of event 3
cpufreq-core: target for CPU 1: 3000000 kHz, relation 1
freq-table: request for target 3000000 kHz (relation: 1) for cpu 1
freq-table: target is 8 (3000000 kHz, 8)
cpufreq-core: initialization complete
cpufreq-core: driver p4-clockmod up and running
p4-clockmod: P4/Xeon(TM) CPU On-Demand Clock Modulation available
[lack of events]
^ permalink raw reply [flat|nested] 6+ messages in thread
* RE: p4_clockmod broken in 2.6.16-rc? kernels
@ 2006-03-09 13:53 Pallipadi, Venkatesh
2006-03-10 3:25 ` Mike Galbraith
0 siblings, 1 reply; 6+ messages in thread
From: Pallipadi, Venkatesh @ 2006-03-09 13:53 UTC (permalink / raw)
To: Mike Galbraith, cpufreq; +Cc: davej
[-- Attachment #1: Type: text/plain, Size: 3936 bytes --]
Please try the attached patch and let me know whether that helps.
Thanks,
Venki
>-----Original Message-----
>From: cpufreq-bounces@lists.linux.org.uk
>[mailto:cpufreq-bounces@lists.linux.org.uk] On Behalf Of Mike Galbraith
>Sent: Wednesday, March 08, 2006 10:12 PM
>To: cpufreq@lists.linux.org.uk
>Cc: davej@codemonkey.org.uk
>Subject: p4_clockmod broken in 2.6.16-rc? kernels
>
>Greetings,
>
>As subject says, it appears to be broken for at least one single P4 HT
>system, namely mine. 2.6.15 works fine.
>
>With a UP compiled kernel, it fails completely, due to CPU0 failure to
>initialize. With an SMP compiled kernel, CPU0 fails, but the sibling
>initializes. Nothing good happens afterward though. See debug
>(cpufreq.debug=7) output below.
>
> Cheers,
>
> -Mike
>
>cpufreq-core: trying to register driver p4-clockmod
>cpufreq-core: adding CPU 0
>p4-clockmod: has errata -- disabling frequencies lower than 2ghz
>speedstep-lib: x86: f, model: 2
>speedstep-lib: ebx value is 9, x86_mask is 9
>speedstep-lib: P4 - MSR_EBC_FREQUENCY_ID: 0xf12000f 0x0
>speedstep-lib: P4 - FSB 200000 kHz; Multiplier 15; Speed 3000000 kHz
>freq-table: setting show_table for cpu 0 to c14bd800
>freq-table: table entry 0 is invalid, skipping
>freq-table: table entry 1 is invalid, skipping
>freq-table: table entry 2 is invalid, skipping
>freq-table: table entry 3 is invalid, skipping
>freq-table: table entry 4 is invalid, skipping
>freq-table: table entry 5 is invalid, skipping
>freq-table: table entry 6 is invalid, skipping
>freq-table: table entry 7 is invalid, skipping
>freq-table: table entry 8 is invalid, skipping
>cpufreq-core: initialization failed
>cpufreq-core: adding CPU 1
>p4-clockmod: has errata -- disabling frequencies lower than 2ghz
>speedstep-lib: x86: f, model: 2
>speedstep-lib: ebx value is 9, x86_mask is 9
>speedstep-lib: P4 - MSR_EBC_FREQUENCY_ID: 0xf12000f 0x0
>speedstep-lib: P4 - FSB 200000 kHz; Multiplier 15; Speed 3000000 kHz
>freq-table: setting show_table for cpu 1 to c14bd800
>freq-table: table entry 0 is invalid, skipping
>freq-table: table entry 1: 375000 kHz, 1 index
>freq-table: table entry 2: 750000 kHz, 2 index
>freq-table: table entry 3: 1125000 kHz, 3 index
>freq-table: table entry 4: 1500000 kHz, 4 index
>freq-table: table entry 5: 1875000 kHz, 5 index
>freq-table: table entry 6: 2250000 kHz, 6 index
>freq-table: table entry 7: 2625000 kHz, 7 index
>freq-table: table entry 8: 3000000 kHz, 8 index
>cpufreq-core: setting new policy for CPU 1: 375000 - 3000000 kHz
>freq-table: request for verification of policy (375000 -
>3000000 kHz) for cpu 1
>freq-table: verification lead to (375000 - 3000000 kHz) for cpu 1
>freq-table: request for verification of policy (375000 -
>3000000 kHz) for cpu 1
>freq-table: verification lead to (375000 - 3000000 kHz) for cpu 1
>cpufreq-core: new min and max freqs are 375000 - 3000000 kHz
>cpufreq-core: governor switch
>cpufreq-core: __cpufreq_governor for CPU 1, event 1
>performance: setting to 3000000 kHz because of event 1
>cpufreq-core: target for CPU 1: 3000000 kHz, relation 1
>freq-table: request for target 3000000 kHz (relation: 1) for cpu 1
>freq-table: target is 8 (3000000 kHz, 8)
>cpufreq-core: governor: change or update limits
>cpufreq-core: __cpufreq_governor for CPU 1, event 3
>performance: setting to 3000000 kHz because of event 3
>cpufreq-core: target for CPU 1: 3000000 kHz, relation 1
>freq-table: request for target 3000000 kHz (relation: 1) for cpu 1
>freq-table: target is 8 (3000000 kHz, 8)
>cpufreq-core: initialization complete
>cpufreq-core: driver p4-clockmod up and running
>p4-clockmod: P4/Xeon(TM) CPU On-Demand Clock Modulation available
>
>[lack of events]
>
>
>
>_______________________________________________
>Cpufreq mailing list
>Cpufreq@lists.linux.org.uk
>http://lists.linux.org.uk/mailman/listinfo/cpufreq
>
[-- Attachment #2: p4clockmod.patch --]
[-- Type: application/octet-stream, Size: 916 bytes --]
Fix the code to disable freqs less than 2GHz in N44 017 errata.
Signed-off-by: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com>
Index: linux-2.6.15/arch/i386/kernel/cpu/cpufreq/p4-clockmod.c
===================================================================
--- linux-2.6.15.orig/arch/i386/kernel/cpu/cpufreq/p4-clockmod.c
+++ linux-2.6.15/arch/i386/kernel/cpu/cpufreq/p4-clockmod.c
@@ -244,7 +244,7 @@ static int cpufreq_p4_cpu_init(struct cp
for (i=1; (p4clockmod_table[i].frequency != CPUFREQ_TABLE_END); i++) {
if ((i<2) && (has_N44_O17_errata[policy->cpu]))
p4clockmod_table[i].frequency = CPUFREQ_ENTRY_INVALID;
- else if (has_N60_errata[policy->cpu] && p4clockmod_table[i].frequency < 2000000)
+ else if (has_N60_errata[policy->cpu] && ((stock_freq * i)/8) < 2000000)
p4clockmod_table[i].frequency = CPUFREQ_ENTRY_INVALID;
else
p4clockmod_table[i].frequency = (stock_freq * i)/8;
[-- Attachment #3: Type: text/plain, Size: 147 bytes --]
_______________________________________________
Cpufreq mailing list
Cpufreq@lists.linux.org.uk
http://lists.linux.org.uk/mailman/listinfo/cpufreq
^ permalink raw reply [flat|nested] 6+ messages in thread
* RE: p4_clockmod broken in 2.6.16-rc? kernels
2006-03-09 13:53 Pallipadi, Venkatesh
@ 2006-03-10 3:25 ` Mike Galbraith
0 siblings, 0 replies; 6+ messages in thread
From: Mike Galbraith @ 2006-03-10 3:25 UTC (permalink / raw)
To: Pallipadi, Venkatesh; +Cc: cpufreq, davej
On Thu, 2006-03-09 at 05:53 -0800, Pallipadi, Venkatesh wrote:
> Please try the attached patch and let me know whether that helps.
Sorry for the late response. I'm the father of an 18 year old chip off
the old block-head... 'nuff said.
Yes, this fixes it for both SMP and UP. Thanks for the quick response.
-Mike
(Now to go patch my kernel. 2250 Mhz my south 40.. buy cpu for $$ get
bonus defects for free.. mutter mutter gripe bitch whine complain;)
^ permalink raw reply [flat|nested] 6+ messages in thread
* RE: p4_clockmod broken in 2.6.16-rc? kernels
@ 2006-03-10 4:07 Pallipadi, Venkatesh
2006-03-10 5:47 ` Dave Jones
0 siblings, 1 reply; 6+ messages in thread
From: Pallipadi, Venkatesh @ 2006-03-10 4:07 UTC (permalink / raw)
To: Mike Galbraith; +Cc: cpufreq, davej
[-- Attachment #1: Type: text/plain, Size: 983 bytes --]
Great to hear that the patch helped. I had a typo in the patch header
and attaching an updated patch.
Dave: Please push this patch towards base. This was a bug in one of the
recent changes in p4-clockmod.c
Thanks,
Venki
>-----Original Message-----
>From: Mike Galbraith [mailto:efault@gmx.de]
>Sent: Thursday, March 09, 2006 7:26 PM
>To: Pallipadi, Venkatesh
>Cc: cpufreq@lists.linux.org.uk; davej@codemonkey.org.uk
>Subject: RE: p4_clockmod broken in 2.6.16-rc? kernels
>
>On Thu, 2006-03-09 at 05:53 -0800, Pallipadi, Venkatesh wrote:
>> Please try the attached patch and let me know whether that helps.
>
>Sorry for the late response. I'm the father of an 18 year old chip off
>the old block-head... 'nuff said.
>
>Yes, this fixes it for both SMP and UP. Thanks for the quick response.
>
> -Mike
>
>(Now to go patch my kernel. 2250 Mhz my south 40.. buy cpu for $$ get
>bonus defects for free.. mutter mutter gripe bitch whine complain;)
>
[-- Attachment #2: p4clockmod.patch --]
[-- Type: application/octet-stream, Size: 912 bytes --]
Fix the code to disable freqs less than 2GHz in N60 errata.
Signed-off-by: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com>
Index: linux-2.6.15/arch/i386/kernel/cpu/cpufreq/p4-clockmod.c
===================================================================
--- linux-2.6.15.orig/arch/i386/kernel/cpu/cpufreq/p4-clockmod.c
+++ linux-2.6.15/arch/i386/kernel/cpu/cpufreq/p4-clockmod.c
@@ -244,7 +244,7 @@ static int cpufreq_p4_cpu_init(struct cp
for (i=1; (p4clockmod_table[i].frequency != CPUFREQ_TABLE_END); i++) {
if ((i<2) && (has_N44_O17_errata[policy->cpu]))
p4clockmod_table[i].frequency = CPUFREQ_ENTRY_INVALID;
- else if (has_N60_errata[policy->cpu] && p4clockmod_table[i].frequency < 2000000)
+ else if (has_N60_errata[policy->cpu] && ((stock_freq * i)/8) < 2000000)
p4clockmod_table[i].frequency = CPUFREQ_ENTRY_INVALID;
else
p4clockmod_table[i].frequency = (stock_freq * i)/8;
[-- Attachment #3: Type: text/plain, Size: 147 bytes --]
_______________________________________________
Cpufreq mailing list
Cpufreq@lists.linux.org.uk
http://lists.linux.org.uk/mailman/listinfo/cpufreq
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: p4_clockmod broken in 2.6.16-rc? kernels
2006-03-10 4:07 p4_clockmod broken in 2.6.16-rc? kernels Pallipadi, Venkatesh
@ 2006-03-10 5:47 ` Dave Jones
2006-03-14 17:55 ` Venkatesh Pallipadi
0 siblings, 1 reply; 6+ messages in thread
From: Dave Jones @ 2006-03-10 5:47 UTC (permalink / raw)
To: Pallipadi, Venkatesh; +Cc: cpufreq, Mike Galbraith
On Thu, Mar 09, 2006 at 08:07:44PM -0800, Pallipadi, Venkatesh wrote:
>
> Great to hear that the patch helped. I had a typo in the patch header
> and attaching an updated patch.
>
> Dave: Please push this patch towards base. This was a bug in one of the
> recent changes in p4-clockmod.c
Applied, thanks. I fixed this one up by hand, but next time can you
inline the patch instead of attaching it ?
git doesn't grok MIME, so I end up having to save it seperately,
and munge it back into your mail in an editor before I can feed it to
git, turning 'a few seconds' into a 'a minute or two' to apply a patch.[1]
btw, should acpi-cpufreq/speedstep-ich also have those errata workarounds?
Thanks.
Dave
[1] Actually this was even longer. Due to me missing chopping a MIME
mailheader, it still confused git-apply, and I scratched my head
for some time until Linus clued me in. MIME- just say no!
--
http://www.codemonkey.org.uk
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: p4_clockmod broken in 2.6.16-rc? kernels
2006-03-10 5:47 ` Dave Jones
@ 2006-03-14 17:55 ` Venkatesh Pallipadi
0 siblings, 0 replies; 6+ messages in thread
From: Venkatesh Pallipadi @ 2006-03-14 17:55 UTC (permalink / raw)
To: Dave Jones; +Cc: cpufreq, Mike Galbraith
On Fri, Mar 10, 2006 at 12:47:23AM -0500, Dave Jones wrote:
> On Thu, Mar 09, 2006 at 08:07:44PM -0800, Pallipadi, Venkatesh wrote:
> >
> > Great to hear that the patch helped. I had a typo in the patch header
> > and attaching an updated patch.
> >
> > Dave: Please push this patch towards base. This was a bug in one of the
> > recent changes in p4-clockmod.c
>
> Applied, thanks. I fixed this one up by hand, but next time can you
> inline the patch instead of attaching it ?
Sorry for all the hassle. I wanted to send that patch out quick, before 2.6.16.
And hence ended up sending it as an attachment using the dump mail client.
> btw, should acpi-cpufreq/speedstep-ich also have those errata workarounds?
No. These two errats seem specific to clock modulation and not speedstep. So,
no changes required for speedstep.
Looking at the workarounds in p4-clockmod.c again...
Seems like some more work is needed on this. The current workaround doesn't
seem to cover all the affected steppings and also it is using int [NR_CPUS]
array to store a single bit (whether error is present or not). I will send a
follow-on cleanup patch, which I think can wait until 2.6.16.
Thanks,
Venki
>
> Thanks.
>
> Dave
>
> [1] Actually this was even longer. Due to me missing chopping a MIME
> mailheader, it still confused git-apply, and I scratched my head
> for some time until Linus clued me in. MIME- just say no!
>
> --
> http://www.codemonkey.org.uk
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2006-03-14 17:55 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-03-10 4:07 p4_clockmod broken in 2.6.16-rc? kernels Pallipadi, Venkatesh
2006-03-10 5:47 ` Dave Jones
2006-03-14 17:55 ` Venkatesh Pallipadi
-- strict thread matches above, loose matches on Subject: below --
2006-03-09 13:53 Pallipadi, Venkatesh
2006-03-10 3:25 ` Mike Galbraith
2006-03-09 6:11 Mike Galbraith
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.