aboutsummaryrefslogtreecommitdiffstats
path: root/arch/i386/kernel/cpu/cpufreq/cpufreq-nforce2.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/i386/kernel/cpu/cpufreq/cpufreq-nforce2.c')
-rw-r--r--arch/i386/kernel/cpu/cpufreq/cpufreq-nforce2.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/arch/i386/kernel/cpu/cpufreq/cpufreq-nforce2.c b/arch/i386/kernel/cpu/cpufreq/cpufreq-nforce2.c
index f275e0d4aee5..0d49d73d1b71 100644
--- a/arch/i386/kernel/cpu/cpufreq/cpufreq-nforce2.c
+++ b/arch/i386/kernel/cpu/cpufreq/cpufreq-nforce2.c
@@ -1,5 +1,5 @@
1/* 1/*
2 * (C) 2004 Sebastian Witt <se.witt@gmx.net> 2 * (C) 2004-2006 Sebastian Witt <se.witt@gmx.net>
3 * 3 *
4 * Licensed under the terms of the GNU GPL License version 2. 4 * Licensed under the terms of the GNU GPL License version 2.
5 * Based upon reverse engineered information 5 * Based upon reverse engineered information
@@ -90,7 +90,7 @@ static int nforce2_calc_pll(unsigned int fsb)
90 90
91 /* Try to calculate multiplier and divider up to 4 times */ 91 /* Try to calculate multiplier and divider up to 4 times */
92 while (((mul == 0) || (div == 0)) && (tried <= 3)) { 92 while (((mul == 0) || (div == 0)) && (tried <= 3)) {
93 for (xdiv = 1; xdiv <= 0x80; xdiv++) 93 for (xdiv = 2; xdiv <= 0x80; xdiv++)
94 for (xmul = 1; xmul <= 0xfe; xmul++) 94 for (xmul = 1; xmul <= 0xfe; xmul++)
95 if (nforce2_calc_fsb(NFORCE2_PLL(xmul, xdiv)) == 95 if (nforce2_calc_fsb(NFORCE2_PLL(xmul, xdiv)) ==
96 fsb + tried) { 96 fsb + tried) {
@@ -117,8 +117,7 @@ static void nforce2_write_pll(int pll)
117 int temp; 117 int temp;
118 118
119 /* Set the pll addr. to 0x00 */ 119 /* Set the pll addr. to 0x00 */
120 temp = 0x00; 120 pci_write_config_dword(nforce2_chipset_dev, NFORCE2_PLLADR, 0);
121 pci_write_config_dword(nforce2_chipset_dev, NFORCE2_PLLADR, temp);
122 121
123 /* Now write the value in all 64 registers */ 122 /* Now write the value in all 64 registers */
124 for (temp = 0; temp <= 0x3f; temp++) 123 for (temp = 0; temp <= 0x3f; temp++)
@@ -266,7 +265,7 @@ static int nforce2_target(struct cpufreq_policy *policy,
266 if (freqs.old == freqs.new) 265 if (freqs.old == freqs.new)
267 return 0; 266 return 0;
268 267
269 dprintk(KERN_INFO "cpufreq: Old CPU frequency %d kHz, new %d kHz\n", 268 dprintk("Old CPU frequency %d kHz, new %d kHz\n",
270 freqs.old, freqs.new); 269 freqs.old, freqs.new);
271 270
272 cpufreq_notify_transition(&freqs, CPUFREQ_PRECHANGE); 271 cpufreq_notify_transition(&freqs, CPUFREQ_PRECHANGE);
@@ -278,7 +277,7 @@ static int nforce2_target(struct cpufreq_policy *policy,
278 printk(KERN_ERR "cpufreq: Changing FSB to %d failed\n", 277 printk(KERN_ERR "cpufreq: Changing FSB to %d failed\n",
279 target_fsb); 278 target_fsb);
280 else 279 else
281 dprintk(KERN_INFO "cpufreq: Changed FSB successfully to %d\n", 280 dprintk("Changed FSB successfully to %d\n",
282 target_fsb); 281 target_fsb);
283 282
284 /* Enable IRQs */ 283 /* Enable IRQs */