* static freq table support for Pentium M Dothan
@ 2004-08-17 2:51 Michael Clark
2004-08-17 22:04 ` Oliver Antwerpen
` (2 more replies)
0 siblings, 3 replies; 14+ messages in thread
From: Michael Clark @ 2004-08-17 2:51 UTC (permalink / raw)
To: cpufreq; +Cc: michael
Hi All,
I sent this patch privately to Dave but he suggested it needed some
discussion on the list.
It adds Dothan frequency/voltage tables for processors 715, 725, 735,
745, 755 to support frequency scaling when ACPI is not enabled. It
should apply to current BitKeeper (on top of centrino ACPI table support).
I personally need this patch as I don't use ACPI so can't use the
experimental ACPI freq/voltage tables support as ACPI doesn't work well
enough for me on my Thinkpad T42.
It currently lists the B0 steppings only, a line or 2 may need to be added
for A1 steppings although in my googling I haven't seen any /proc/cpuinfo
output for these, all i've seen are B0 steppings for which i've seen
examples of 1.5GHz through 1.8GHz.
The Dothan processor datasheet 30218903.pdf defines 4 voltages for
each frequency (VID#A through VID#D) whereas Banias only suggests a
typical voltage and no min or max for each freq so i've used the OP
macro to allow definition of all voltages (A through D) but the macro
currently just uses VID#A at compile time.
Having all of the voltages in the code (VID#A through VID#D) is really
more for the purposes of completeness. The VID#A voltages after some
thought are the most conservative setting (also same as seen in the ACPI
tables of my Thinkpad), as the max voltage of the Dothans is 1.6, having
the higher voltage will allow for greater power supply tolerance.
~mc
--- linux-2.6.8-rc3-mm1/arch/i386/kernel/cpu/cpufreq/speedstep-centrino.c.orig 2004-08-06 18:42:15.000000000 +0800
+++ linux-2.6.8-rc3-mm1/arch/i386/kernel/cpu/cpufreq/speedstep-centrino.c 2004-08-06 18:44:28.000000000 +0800
@@ -195,6 +195,82 @@
OP(1700, 1484),
{ .frequency = CPUFREQ_TABLE_END }
};
+
+#undef OP
+
+/* Dothan processor datasheet 30218903.pdf defines 4 voltages for each
+ frequency (VID#A through VID#D) - this macro allows us to define all
+ of these but we only use the VID#A voltages at compile time - this may
+ need some work if we want to select the voltage profile at runtime. */
+
+#define OP(mhz, mva, mvb, mvc, mvd) \
+ { \
+ .frequency = (mhz) * 1000, \
+ .index = (((mhz)/100) << 8) | ((mva - 700) / 16) \
+ }
+
+/* Intel Pentium M processor 715 / 1.50GHz (Dothan) */
+static struct cpufreq_frequency_table dothan_1500[] =
+{
+ OP( 600, 988, 988, 988, 988),
+ OP( 800, 1068, 1068, 1068, 1052),
+ OP(1000, 1148, 1148, 1132, 1116),
+ OP(1200, 1228, 1212, 1212, 1180),
+ OP(1500, 1340, 1324, 1308, 1276),
+ { .frequency = CPUFREQ_TABLE_END }
+};
+
+/* Intel Pentium M processor 725 / 1.60GHz (Dothan) */
+static struct cpufreq_frequency_table dothan_1600[] =
+{
+ OP( 600, 988, 988, 988, 988),
+ OP( 800, 1068, 1068, 1052, 1052),
+ OP(1000, 1132, 1132, 1116, 1116),
+ OP(1200, 1212, 1196, 1180, 1164),
+ OP(1400, 1276, 1260, 1244, 1228),
+ OP(1600, 1340, 1324, 1308, 1276),
+ { .frequency = CPUFREQ_TABLE_END }
+};
+
+/* Intel Pentium M processor 735 / 1.70GHz (Dothan) */
+static struct cpufreq_frequency_table dothan_1700[] =
+{
+ OP( 600, 988, 988, 988, 988),
+ OP( 800, 1052, 1052, 1052, 1052),
+ OP(1000, 1116, 1116, 1116, 1100),
+ OP(1200, 1180, 1180, 1164, 1148),
+ OP(1400, 1244, 1244, 1228, 1212),
+ OP(1700, 1340, 1324, 1308, 1276),
+ { .frequency = CPUFREQ_TABLE_END }
+};
+
+/* Intel Pentium M processor 745 / 1.80GHz (Dothan) */
+static struct cpufreq_frequency_table dothan_1800[] =
+{
+ OP( 600, 988, 988, 988, 988),
+ OP( 800, 1052, 1052, 1052, 1036),
+ OP(1000, 1116, 1100, 1100, 1084),
+ OP(1200, 1164, 1164, 1148, 1132),
+ OP(1400, 1228, 1212, 1212, 1180),
+ OP(1600, 1292, 1276, 1260, 1228),
+ OP(1800, 1340, 1324, 1308, 1276),
+ { .frequency = CPUFREQ_TABLE_END }
+};
+
+/* Intel Pentium M processor 755 / 2.00GHz (Dothan) */
+static struct cpufreq_frequency_table dothan_2000[] =
+{
+ OP( 600, 988, 988, 988, 988),
+ OP( 800, 1052, 1036, 1036, 1036),
+ OP(1000, 1100, 1084, 1084, 1084),
+ OP(1200, 1148, 1132, 1132, 1116),
+ OP(1400, 1196, 1180, 1180, 1164),
+ OP(1600, 1244, 1228, 1228, 1196),
+ OP(1800, 1292, 1276, 1276, 1244),
+ OP(2000, 1340, 1324, 1308, 1276),
+ { .frequency = CPUFREQ_TABLE_END }
+};
+
#undef OP
#define _BANIAS(cpuid, max, name) \
@@ -205,6 +281,13 @@
}
#define BANIAS(max) _BANIAS(&cpu_ids[CPU_BANIAS], max, #max)
+#define DOTHAN(cpuid, max, name) \
+{ .cpu_id = cpuid, \
+ .model_name = "Intel(R) Pentium(R) M processor " name "GHz", \
+ .max_freq = (max)*1000, \
+ .op_points = dothan_##max, \
+}
+
/* CPU models, their operating frequency range, and freq/voltage
operating points */
static struct cpu_model models[] =
@@ -218,6 +301,11 @@
BANIAS(1500),
BANIAS(1600),
BANIAS(1700),
+ DOTHAN(&cpu_ids[CPU_DOTHAN_B0], 1500, "1.50"),
+ DOTHAN(&cpu_ids[CPU_DOTHAN_B0], 1600, "1.60"),
+ DOTHAN(&cpu_ids[CPU_DOTHAN_B0], 1700, "1.70"),
+ DOTHAN(&cpu_ids[CPU_DOTHAN_B0], 1800, "1.80"),
+ DOTHAN(&cpu_ids[CPU_DOTHAN_B0], 2000, "2.00"),
/* NULL model_name is a wildcard */
{ &cpu_ids[CPU_DOTHAN_A1], NULL, 0, NULL },
@@ -227,6 +315,7 @@
};
#undef _BANIAS
#undef BANIAS
+#undef DOTHAN
static int centrino_cpu_init_table(struct cpufreq_policy *policy)
{
^ permalink raw reply [flat|nested] 14+ messages in thread* Re: static freq table support for Pentium M Dothan
2004-08-17 2:51 static freq table support for Pentium M Dothan Michael Clark
@ 2004-08-17 22:04 ` Oliver Antwerpen
2004-08-18 9:44 ` Bruno Ducrot
2004-08-18 22:45 ` Jeremy Fitzhardinge
2004-09-08 19:59 ` Stefan Tomanek
2 siblings, 1 reply; 14+ messages in thread
From: Oliver Antwerpen @ 2004-08-17 22:04 UTC (permalink / raw)
To: cpufreq
Hi,
Michael Clark wrote:
> Hi All,
>
> It adds Dothan frequency/voltage tables for processors 715, 725, 735,
> 745, 755 to support frequency scaling when ACPI is not enabled. It
> should apply to current BitKeeper (on top of centrino ACPI table support).
I applied the patch to 2.6.8.1-mm1 successfully.
> I personally need this patch as I don't use ACPI so can't use the
> experimental ACPI freq/voltage tables support as ACPI doesn't work well
> enough for me on my Thinkpad T42.
I was using the acpi since now. I'll now give speedstep-centrino a try
and see, if the finer granulated frequencies affect my system.
> It currently lists the B0 steppings only, a line or 2 may need to be added
> for A1 steppings although in my googling I haven't seen any /proc/cpuinfo
> output for these, all i've seen are B0 steppings for which i've seen
> examples of 1.5GHz through 1.8GHz.
I am another example of B0 (using intel 735 1.7GHz/2MB)
I don't really know what to do. Do I have any advantages using
speedstep-centrino instead of acpi?
Olli
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: static freq table support for Pentium M Dothan
2004-08-17 22:04 ` Oliver Antwerpen
@ 2004-08-18 9:44 ` Bruno Ducrot
0 siblings, 0 replies; 14+ messages in thread
From: Bruno Ducrot @ 2004-08-18 9:44 UTC (permalink / raw)
To: Oliver Antwerpen; +Cc: cpufreq
Hi,
On Tue, Aug 17, 2004 at 10:04:32PM +0000, Oliver Antwerpen wrote:
> I don't really know what to do. Do I have any advantages using
> speedstep-centrino instead of acpi?
You may want BOTH actually. acpi for a more aware power saving idle
loop (you can gather some statistics from /proc/acpi/processor/*/power)
and you may want speedstep-centrino in order to lower voltage (and as a
consequence the frequency of the processor). You should'nt use the acpi
performance stuff because it's achieve the exact same thing than the
speedstep-centrino, but via a call to the BIOS instead to talk directly
to the hardware (in this case, via known MSRs).
Cheers,
--
Bruno Ducrot
-- Which is worse: ignorance or apathy?
-- Don't know. Don't care.
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: static freq table support for Pentium M Dothan
2004-08-17 2:51 static freq table support for Pentium M Dothan Michael Clark
2004-08-17 22:04 ` Oliver Antwerpen
@ 2004-08-18 22:45 ` Jeremy Fitzhardinge
2004-09-08 19:59 ` Stefan Tomanek
2 siblings, 0 replies; 14+ messages in thread
From: Jeremy Fitzhardinge @ 2004-08-18 22:45 UTC (permalink / raw)
To: Michael Clark; +Cc: michael, cpufreq list
On Tue, 2004-08-17 at 10:51 +0800, Michael Clark wrote:
> Having all of the voltages in the code (VID#A through VID#D) is really
> more for the purposes of completeness. The VID#A voltages after some
> thought are the most conservative setting (also same as seen in the ACPI
> tables of my Thinkpad), as the max voltage of the Dothans is 1.6, having
> the higher voltage will allow for greater power supply tolerance.
I was considering this approach, but I got concerned because the voltage
ranges of VID#A and VID#D don't overlap - so by using VID#A voltages on
a #D CPU, you'd be driving it out of spec.
J
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: static freq table support for Pentium M Dothan
2004-08-17 2:51 static freq table support for Pentium M Dothan Michael Clark
2004-08-17 22:04 ` Oliver Antwerpen
2004-08-18 22:45 ` Jeremy Fitzhardinge
@ 2004-09-08 19:59 ` Stefan Tomanek
2004-09-08 21:31 ` Dominik Brodowski
2 siblings, 1 reply; 14+ messages in thread
From: Stefan Tomanek @ 2004-09-08 19:59 UTC (permalink / raw)
To: cpufreq
Michael Clark <mclark <at> metaparadigm.com> writes:
> I personally need this patch as I don't use ACPI so can't use the
> experimental ACPI freq/voltage tables support as ACPI doesn't work well
> enough for me on my Thinkpad T42.
This patch is great, ACPI only reports two frequencies on my Travelmate 292
(Dothan 1.5), 600 and 1500 Mhz. With this patch I can use all available
frequencies. Will it be integrated into the official speedstep-centrino module?
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: static freq table support for Pentium M Dothan
2004-09-08 19:59 ` Stefan Tomanek
@ 2004-09-08 21:31 ` Dominik Brodowski
2004-09-08 21:43 ` Stefan Tomanek
0 siblings, 1 reply; 14+ messages in thread
From: Dominik Brodowski @ 2004-09-08 21:31 UTC (permalink / raw)
To: Stefan Tomanek; +Cc: cpufreq
On Wed, Sep 08, 2004 at 07:59:30PM +0000, Stefan Tomanek wrote:
> Michael Clark <mclark <at> metaparadigm.com> writes:
>
> > I personally need this patch as I don't use ACPI so can't use the
> > experimental ACPI freq/voltage tables support as ACPI doesn't work well
> > enough for me on my Thinkpad T42.
>
> This patch is great, ACPI only reports two frequencies on my Travelmate 292
> (Dothan 1.5), 600 and 1500 Mhz. With this patch I can use all available
> frequencies. Will it be integrated into the official speedstep-centrino module?
No. There is no way to determine which of four possible frequencies is the
valid one for a given Pentium M Dothan processor.
Dominik
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: static freq table support for Pentium M Dothan
2004-09-08 21:31 ` Dominik Brodowski
@ 2004-09-08 21:43 ` Stefan Tomanek
2004-09-08 22:01 ` Dominik Brodowski
0 siblings, 1 reply; 14+ messages in thread
From: Stefan Tomanek @ 2004-09-08 21:43 UTC (permalink / raw)
To: cpufreq
Dominik Brodowski <linux <at> dominikbrodowski.de> writes:
> No. There is no way to determine which of four possible frequencies is the
> valid one for a given Pentium M Dothan processor.
Hm, I'm new to this whole speedstepping thing, so I'm kind of confused: what
exactly do you mean by "valid frequency"?
As I said, using ACPI I only get 600Mhz or 1500Mhz, all or nothing, with that
patch I additionally have 800, 1000, 1200, and those levels work fine according
to /proc/cpuinfo or the gkrellm cpu plugin.
Thanks in advance for some enlightnment :-)
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: static freq table support for Pentium M Dothan
2004-09-08 21:43 ` Stefan Tomanek
@ 2004-09-08 22:01 ` Dominik Brodowski
2004-09-08 23:07 ` Stefan Tomanek
0 siblings, 1 reply; 14+ messages in thread
From: Dominik Brodowski @ 2004-09-08 22:01 UTC (permalink / raw)
To: Stefan Tomanek; +Cc: cpufreq
On Wed, Sep 08, 2004 at 09:43:03PM +0000, Stefan Tomanek wrote:
> Dominik Brodowski <linux <at> dominikbrodowski.de> writes:
>
> > No. There is no way to determine which of four possible frequencies is the
> > valid one for a given Pentium M Dothan processor.
>
> Hm, I'm new to this whole speedstepping thing, so I'm kind of confused: what
> exactly do you mean by "valid frequency"?
... it means that I need to get some sleep. I wanted to say "four possible
voltages" for each of the frequencies allowed.
> As I said, using ACPI I only get 600Mhz or 1500Mhz, all or nothing, with that
> patch I additionally have 800, 1000, 1200, and those levels work fine according
> to /proc/cpuinfo or the gkrellm cpu plugin.
However, you don't _know_ the proper voltages for 800, 1000, 1200 MHz.
Complain to your notebook vendor about this broken support, which most
likely is the same in other OSes.
Dominik
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: static freq table support for Pentium M Dothan
2004-09-08 22:01 ` Dominik Brodowski
@ 2004-09-08 23:07 ` Stefan Tomanek
2004-09-09 7:00 ` Dominik Brodowski
2004-09-09 8:58 ` Bruno Ducrot
0 siblings, 2 replies; 14+ messages in thread
From: Stefan Tomanek @ 2004-09-08 23:07 UTC (permalink / raw)
To: cpufreq
Dominik Brodowski <linux <at> dominikbrodowski.de> writes:
> ... it means that I need to get some sleep. I wanted to say "four possible
> voltages" for each of the frequencies allowed.
Ah, that makes sense, I already thought that after browsing through the mailing
list.
> However, you don't _know_ the proper voltages for 800, 1000, 1200 MHz.
> Complain to your notebook vendor about this broken support, which most
> likely is the same in other OSes.
I'll do that, and I've already contacted other people running using the same
Notebook. I also tried that cpufreq-acpi_pdump module:
number of states: 2
acpi_pdump: P0: 1500 MHz, 0 mW, 100 uS s:0x0 c:0x83
acpi_pdump: P1: 600 MHz, 0 mW, 100 uS s:0x1 c:0x183
control_register:
130 12 1 16 0 0 178
status_register:
130 12 1 8 0 0 179
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: static freq table support for Pentium M Dothan
2004-09-08 23:07 ` Stefan Tomanek
@ 2004-09-09 7:00 ` Dominik Brodowski
2004-09-09 8:54 ` Stefan Tomanek
2004-09-09 8:58 ` Bruno Ducrot
1 sibling, 1 reply; 14+ messages in thread
From: Dominik Brodowski @ 2004-09-09 7:00 UTC (permalink / raw)
To: Stefan Tomanek; +Cc: cpufreq
On Wed, Sep 08, 2004 at 11:07:02PM +0000, Stefan Tomanek wrote:
> I'll do that, and I've already contacted other people running using the same
> Notebook. I also tried that cpufreq-acpi_pdump module:
>
> number of states: 2
> acpi_pdump: P0: 1500 MHz, 0 mW, 100 uS s:0x0 c:0x83
> acpi_pdump: P1: 600 MHz, 0 mW, 100 uS s:0x1 c:0x183
> control_register:
> 130 12 1 16 0 0 178
> status_register:
> 130 12 1 8 0 0 179
What does cpufreq-acpi_pdump with argument "pdc=1" report?
Thanks,
Dominik
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: static freq table support for Pentium M Dothan
2004-09-09 7:00 ` Dominik Brodowski
@ 2004-09-09 8:54 ` Stefan Tomanek
0 siblings, 0 replies; 14+ messages in thread
From: Stefan Tomanek @ 2004-09-09 8:54 UTC (permalink / raw)
To: cpufreq
Dominik Brodowski <linux <at> dominikbrodowski.de> writes:
> What does cpufreq-acpi_pdump with argument "pdc=1" report?
insmod arch/i386/kernel/cpu/cpufreq/cpufreq-acpi_pdump.ko pdc=1
=>
number of states: 2
acpi_pdump: P0: 1500 MHz, 0 mW, 10 uS s:0xf28 c:0xf28
acpi_pdump: P1: 600 MHz, 0 mW, 10 uS s:0x612 c:0x612
control_register:
130 12 127 0 0 0 0
status_register:
130 12 127 0 0 0 0
insmod arch/i386/kernel/cpu/cpufreq/cpufreq-acpi_pdump.ko pdc=0
=>
number of states: 2
acpi_pdump: P0: 1500 MHz, 0 mW, 100 uS s:0x0 c:0x83
acpi_pdump: P1: 600 MHz, 0 mW, 100 uS s:0x1 c:0x183
control_register:
130 12 1 16 0 0 178
status_register:
130 12 1 8 0 0 179
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: static freq table support for Pentium M Dothan
2004-09-08 23:07 ` Stefan Tomanek
2004-09-09 7:00 ` Dominik Brodowski
@ 2004-09-09 8:58 ` Bruno Ducrot
2004-09-09 15:33 ` Dominik Brodowski
2004-09-09 18:41 ` Stefan Tomanek
1 sibling, 2 replies; 14+ messages in thread
From: Bruno Ducrot @ 2004-09-09 8:58 UTC (permalink / raw)
To: cpufreq; +Cc: Stefan Tomanek
Hi,
On Wed, Sep 08, 2004 at 11:07:02PM +0000, Stefan Tomanek wrote:
> Dominik Brodowski <linux <at> dominikbrodowski.de> writes:
>
> > ... it means that I need to get some sleep. I wanted to say "four possible
> > voltages" for each of the frequencies allowed.
>
> Ah, that makes sense, I already thought that after browsing through the mailing
> list.
>
> > However, you don't _know_ the proper voltages for 800, 1000, 1200 MHz.
> > Complain to your notebook vendor about this broken support, which most
> > likely is the same in other OSes.
>
> I'll do that, and I've already contacted other people running using the same
> Notebook. I also tried that cpufreq-acpi_pdump module:
>
> number of states: 2
> acpi_pdump: P0: 1500 MHz, 0 mW, 100 uS s:0x0 c:0x83
> acpi_pdump: P1: 600 MHz, 0 mW, 100 uS s:0x1 c:0x183
> control_register:
> 130 12 1 16 0 0 178
> status_register:
> 130 12 1 8 0 0 179
It's indeed the SMM interface, not direct hardware access, with also a
broken mask (out of spec indeed) for the control register.
I guess 'the other OS' may actually use somehow the full eax before doing
the outb and then allowing somehow ancient version of speedstep to
work...
--
Bruno Ducrot
-- Which is worse: ignorance or apathy?
-- Don't know. Don't care.
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: static freq table support for Pentium M Dothan
2004-09-09 8:58 ` Bruno Ducrot
@ 2004-09-09 15:33 ` Dominik Brodowski
2004-09-09 18:41 ` Stefan Tomanek
1 sibling, 0 replies; 14+ messages in thread
From: Dominik Brodowski @ 2004-09-09 15:33 UTC (permalink / raw)
To: Bruno Ducrot; +Cc: cpufreq, Stefan Tomanek
On Thu, Sep 09, 2004 at 10:58:02AM +0200, Bruno Ducrot wrote:
> > acpi_pdump: P0: 1500 MHz, 0 mW, 100 uS s:0x0 c:0x83
> > acpi_pdump: P1: 600 MHz, 0 mW, 100 uS s:0x1 c:0x183
> > control_register:
> > 130 12 1 16 0 0 178
> > status_register:
> > 130 12 1 8 0 0 179
>
> It's indeed the SMM interface, not direct hardware access, with also a
> broken mask (out of spec indeed)
Why is it out of spec?
> I guess 'the other OS' may actually use somehow the full eax before doing
> the outb and then allowing somehow ancient version of speedstep to
> work...
Possibly. But fortunately we don't need to :)
Dominik
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: static freq table support for Pentium M Dothan
2004-09-09 8:58 ` Bruno Ducrot
2004-09-09 15:33 ` Dominik Brodowski
@ 2004-09-09 18:41 ` Stefan Tomanek
1 sibling, 0 replies; 14+ messages in thread
From: Stefan Tomanek @ 2004-09-09 18:41 UTC (permalink / raw)
To: cpufreq
Bruno Ducrot <ducrot <at> poupinou.org> writes:
> It's indeed the SMM interface, not direct hardware access, with also a
> broken mask (out of spec indeed) for the control register.
Ahh, and this is....bad I guess?
> I guess 'the other OS' may actually use somehow the full eax before doing
> the outb and then allowing somehow ancient version of speedstep to
> work...
It uses the whatwhat before doing the somethingsomething?
Please excuse my incompetence ;-)
^ permalink raw reply [flat|nested] 14+ messages in thread
end of thread, other threads:[~2004-09-09 18:41 UTC | newest]
Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-08-17 2:51 static freq table support for Pentium M Dothan Michael Clark
2004-08-17 22:04 ` Oliver Antwerpen
2004-08-18 9:44 ` Bruno Ducrot
2004-08-18 22:45 ` Jeremy Fitzhardinge
2004-09-08 19:59 ` Stefan Tomanek
2004-09-08 21:31 ` Dominik Brodowski
2004-09-08 21:43 ` Stefan Tomanek
2004-09-08 22:01 ` Dominik Brodowski
2004-09-08 23:07 ` Stefan Tomanek
2004-09-09 7:00 ` Dominik Brodowski
2004-09-09 8:54 ` Stefan Tomanek
2004-09-09 8:58 ` Bruno Ducrot
2004-09-09 15:33 ` Dominik Brodowski
2004-09-09 18:41 ` Stefan Tomanek
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.