Sharedwww / t42 / cupfreq-speedstep-dothan-1.patchOpen in CoCalc
Author: William A. Stein
1
--- ./arch/i386/kernel/cpu/cpufreq/speedstep-centrino.c.bk-patched 2004-08-06 11:26:05.000000000 +0800
2
+++ ./arch/i386/kernel/cpu/cpufreq/speedstep-centrino.c 2004-08-06 12:42:32.000000000 +0800
3
@@ -198,6 +198,82 @@
4
OP(1700, 1484),
5
{ .frequency = CPUFREQ_TABLE_END }
6
};
7
+
8
+#undef OP
9
+
10
+/* Dothan processor datasheet 30218903.pdf defines 4 voltages for each
11
+ frequency (VID#A through VID#D) - this macro allows us to define all
12
+ of these but we only use the VID#C voltages at compile time - this may
13
+ need some work if we want to select the voltage profile at runtime. */
14
+
15
+#define OP(mhz, mva, mvb, mvc, mvd) \
16
+ { \
17
+ .frequency = (mhz) * 1000, \
18
+ .index = (((mhz)/100) << 8) | ((mvc - 700) / 16) \
19
+ }
20
+
21
+/* Intel Pentium M processor 715 / 1.50GHz (Dothan) */
22
+static struct cpufreq_frequency_table dothan_1500[] =
23
+{
24
+ OP( 600, 988, 988, 988, 988),
25
+ OP( 800, 1068, 1068, 1068, 1052),
26
+ OP(1000, 1148, 1148, 1132, 1116),
27
+ OP(1200, 1228, 1212, 1212, 1180),
28
+ OP(1500, 1340, 1324, 1308, 1276),
29
+ { .frequency = CPUFREQ_TABLE_END }
30
+};
31
+
32
+/* Intel Pentium M processor 725 / 1.60GHz (Dothan) */
33
+static struct cpufreq_frequency_table dothan_1600[] =
34
+{
35
+ OP( 600, 988, 988, 988, 988),
36
+ OP( 800, 1068, 1068, 1052, 1052),
37
+ OP(1000, 1132, 1132, 1116, 1116),
38
+ OP(1200, 1212, 1196, 1180, 1164),
39
+ OP(1400, 1276, 1260, 1244, 1228),
40
+ OP(1600, 1340, 1324, 1308, 1276),
41
+ { .frequency = CPUFREQ_TABLE_END }
42
+};
43
+
44
+/* Intel Pentium M processor 735 / 1.70GHz (Dothan) */
45
+static struct cpufreq_frequency_table dothan_1700[] =
46
+{
47
+ OP( 600, 988, 988, 988, 988),
48
+ OP( 800, 1052, 1052, 1052, 1052),
49
+ OP(1000, 1116, 1116, 1116, 1100),
50
+ OP(1200, 1180, 1180, 1164, 1148),
51
+ OP(1400, 1244, 1244, 1228, 1212),
52
+ OP(1700, 1340, 1324, 1308, 1276),
53
+ { .frequency = CPUFREQ_TABLE_END }
54
+};
55
+
56
+/* Intel Pentium M processor 745 / 1.80GHz (Dothan) */
57
+static struct cpufreq_frequency_table dothan_1800[] =
58
+{
59
+ OP( 600, 988, 988, 988, 988),
60
+ OP( 800, 1052, 1052, 1052, 1036),
61
+ OP(1000, 1116, 1100, 1100, 1084),
62
+ OP(1200, 1164, 1164, 1148, 1132),
63
+ OP(1400, 1228, 1212, 1212, 1180),
64
+ OP(1600, 1292, 1276, 1260, 1228),
65
+ OP(1800, 1340, 1324, 1308, 1276),
66
+ { .frequency = CPUFREQ_TABLE_END }
67
+};
68
+
69
+/* Intel Pentium M processor 755 / 2.00GHz (Dothan) */
70
+static struct cpufreq_frequency_table dothan_2000[] =
71
+{
72
+ OP( 600, 988, 988, 988, 988),
73
+ OP( 800, 1052, 1036, 1036, 1036),
74
+ OP(1000, 1100, 1084, 1084, 1084),
75
+ OP(1200, 1148, 1132, 1132, 1116),
76
+ OP(1400, 1196, 1180, 1180, 1164),
77
+ OP(1600, 1244, 1228, 1228, 1196),
78
+ OP(1800, 1292, 1276, 1276, 1244),
79
+ OP(2000, 1340, 1324, 1308, 1276),
80
+ { .frequency = CPUFREQ_TABLE_END }
81
+};
82
+
83
#undef OP
84
85
#define _BANIAS(cpuid, max, name) \
86
@@ -208,6 +284,13 @@
87
}
88
#define BANIAS(max) _BANIAS(&cpu_id_banias, max, #max)
89
90
+#define DOTHAN(cpuid, max, name) \
91
+{ .cpu_id = cpuid, \
92
+ .model_name = "Intel(R) Pentium(R) M processor " name "GHz", \
93
+ .max_freq = (max)*1000, \
94
+ .op_points = dothan_##max, \
95
+}
96
+
97
/* CPU models, their operating frequency range, and freq/voltage
98
operating points */
99
static struct cpu_model models[] =
100
@@ -221,6 +304,11 @@
101
BANIAS(1500),
102
BANIAS(1600),
103
BANIAS(1700),
104
+ DOTHAN(&cpu_id_dothan_b0, 1500, "1.50"), /* check stepping and name */
105
+ DOTHAN(&cpu_id_dothan_b0, 1600, "1.60"), /* check stepping and name */
106
+ DOTHAN(&cpu_id_dothan_b0, 1700, "1.70"), /* check stepping and name */
107
+ DOTHAN(&cpu_id_dothan_b0, 1800, "1.80"),
108
+ DOTHAN(&cpu_id_dothan_b0, 2000, "2.00"), /* check stepping and name */
109
{ NULL, }
110
};
111
#undef _BANIAS
112
113