Skip to contentSkip to conversation

gx-suspmod: fix to return proper value when reading /sys/.../cpuinfo_cur_freq

PATCH New Hiroshi Miura 1 participant 1 message Jan 3, 2005

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 gx-suspmod: fix to return proper value when reading /sys/.../cpuinfo_cur_freq

This is a patch to fix to return proper value when reading /sys/.../cpuinfo_cur_freq with gx-suspmod driver for Cyrix MediaGX / AMD Geode CPUs.

The patch is generated by bkexport script.

Hiroshi Miura --- http://www.da-cha.org/ --- [email protected] NTTDATA Corp. OpenSource Software Center. --- [email protected] NTTDATA Intellilink Corp. OpenSource Engineering Dev. -- [email protected] Key fingerprint = 9117 9407 5684 FBF1 4063 15B4 401D D077 04AB 8617

#### AUTHOR [email protected]
#### COMMENT START
### Comments for ChangeSet
To fix to return a proper cpu speed on gx-suspmod CPUFreq driver when reading /sys/.../cpuinfo_cur_freq

### Comments for arch/i386/kernel/cpu/cpufreq/gx-suspmod.c
fix to return a proper cpu speed. it is caused by mistaking on and off meaning. #### COMMENT END

# This is a BitKeeper generated diff -Nru style patch. #
# ChangeSet
# 2005/01/03 16:23:37+09:00 [email protected]
# To fix to return a proper cpu speed on gx-suspmod CPUFreq driver.
#
# Signed-Off-by: Hiroshi Miura <[email protected]>
#

# arch/i386/kernel/cpu/cpufreq/gx-suspmod.c
#   2005/01/03 16:23:26+09:00 [email protected] +1 -1
#   fix to return a proper cpu speed. it is caused by mistaking on and off meaning.
# 
diff -Nru a/arch/i386/kernel/cpu/cpufreq/gx-suspmod.c b/arch/i386/kernel/cpu/cpufreq/gx-suspmod.c
--- a/arch/i386/kernel/cpu/cpufreq/gx-suspmod.c	2005-01-03 16:25:46 +09:00
+++ b/arch/i386/kernel/cpu/cpufreq/gx-suspmod.c	2005-01-03 16:25:46 +09:00
@@ -219,7 +219,7 @@
 	if ((gx_params->pci_suscfg & SUSMOD) == 0) 
 		return stock_freq;

- return (stock_freq * gx_params->on_duration)
+ return (stock_freq * gx_params->off_duration)
/ (gx_params->on_duration + gx_params->off_duration);
}

_______________________________________________
Cpufreq mailing list
[email protected]
http://www.linux.org.uk/mailman/listinfo/cpufreq