rpms/cpuspeed/F-8 cpuspeed-1.2.1-make-gcc43-happy.patch, NONE, 1.1 cpuspeed-1.2.1-multicore-workaround.patch, NONE, 1.1 cpuspeed.init, 1.35, 1.36 cpuspeed.spec, 1.61, 1.62
Jarod Wilson (jwilson)
fedora-extras-commits at redhat.com
Thu Feb 14 22:44:00 UTC 2008
- Previous message (by thread): rpms/kernel/devel config-x86-generic, 1.27, 1.28 config-x86_64-generic, 1.24, 1.25 kernel.spec, 1.428, 1.429
- Next message (by thread): rpms/cpuspeed/F-7 cpuspeed-1.2.1-make-gcc43-happy.patch, NONE, 1.1 cpuspeed-1.2.1-multicore-workaround.patch, NONE, 1.1 cpuspeed.init, 1.35, 1.36 cpuspeed.spec, 1.60, 1.61
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Author: jwilson
Update of /cvs/pkgs/rpms/cpuspeed/F-8
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv27431
Modified Files:
cpuspeed.init cpuspeed.spec
Added Files:
cpuspeed-1.2.1-make-gcc43-happy.patch
cpuspeed-1.2.1-multicore-workaround.patch
Log Message:
* Thu Feb 14 2008 Jarod Wilson <jwilson at redhat.com> 1.2.1-5
- Support for powernow-k8 as a kernel module
cpuspeed-1.2.1-make-gcc43-happy.patch:
--- NEW FILE cpuspeed-1.2.1-make-gcc43-happy.patch ---
diff -Naurp cpuspeed-1.2.1.orig/cpuspeed.cc cpuspeed-1.2.1/cpuspeed.cc
--- cpuspeed-1.2.1.orig/cpuspeed.cc 2008-02-12 12:10:29.000000000 -0500
+++ cpuspeed-1.2.1/cpuspeed.cc 2008-02-12 12:40:59.000000000 -0500
@@ -568,7 +568,7 @@ dup_cpu_str(const char *s)
}
int
-main(unsigned argc, char * argv[])
+main(int argc, char * argv[])
{
const char * const NAME = basename(strdup(argv[0]));
@@ -584,7 +584,7 @@ main(unsigned argc, char * argv[])
#endif
// parse argv
- for(unsigned i = 1; i < argc; i++)
+ for(int i = 1; i < argc; i++)
{
if(!strcmp(argv[i], "-d"))
daemonize = true;
cpuspeed-1.2.1-multicore-workaround.patch:
--- NEW FILE cpuspeed-1.2.1-multicore-workaround.patch ---
diff -Naurp cpuspeed-1.2.1.orig/cpuspeed.cc cpuspeed-1.2.1/cpuspeed.cc
--- cpuspeed-1.2.1.orig/cpuspeed.cc 2008-02-12 13:00:20.000000000 -0500
+++ cpuspeed-1.2.1/cpuspeed.cc 2008-02-12 13:35:59.000000000 -0500
@@ -239,7 +239,7 @@ get_supported_speeds()
min = MAX(min, min_speed);
max = MIN(max, max_speed);
- unsigned step;
+ unsigned step, real, retries;
const unsigned MAX_STEP = MIN_STEP << 8;
for (step = MIN_STEP; step <= MAX_STEP; step *= 2)
{
@@ -259,9 +259,15 @@ get_supported_speeds()
current_speed = 0;
for (unsigned current = max - step; current > min - step; current -= step)
{
+ retries = 0;
current = MAX(current, min);
- set_speed(current);
- unsigned real = get_speed();
+ while (retries < 3) {
+ set_speed(current);
+ real = get_speed();
+ if (real == current || real == speeds[current_speed].khz)
+ break;
+ retries++;
+ }
if (real != speeds[current_speed].khz)
{
speeds[++current_speed].khz = real;
Index: cpuspeed.init
===================================================================
RCS file: /cvs/pkgs/rpms/cpuspeed/F-8/cpuspeed.init,v
retrieving revision 1.35
retrieving revision 1.36
diff -u -r1.35 -r1.36
--- cpuspeed.init 7 Jul 2007 20:15:25 -0000 1.35
+++ cpuspeed.init 14 Feb 2008 22:43:24 -0000 1.36
@@ -112,10 +112,20 @@
start() {
if [ ! -f $lockfile ] && [ ! -d "$xendir" ]; then
if ! some_file_exist $testpat ; then
+ cpu_vendor=$(grep vendor_id /proc/cpuinfo | awk '{print $3}' | tail -n 1)
+ cpu_family=$(grep "cpu family" /proc/cpuinfo | awk '{print $4}' | tail -n 1)
# Attempt to load scaling_driver if not loaded
# but it is configured
if [ -n "$DRIVER" ]; then
/sbin/modprobe "$DRIVER"
+ elif [ "$cpu_vendor" == AuthenticAMD ] && [ "$cpu_family" -ge 7 ]; then
+ # Try loading powernow-k8 if this is an AMD processor,
+ # family 7 or greater (Athlon XP/MP was family 6)
+ pk8m=$(/sbin/modinfo powernow-k8 2>&1 > /dev/null)
+ if [ "$?" -eq 0 ]; then
+ /sbin/modprobe powernow-k8 2> /dev/null
+ [ -d ${cpu0freqd} ] || /sbin/modprobe -r powernow-k8 2> /dev/null
+ fi
else
if [ -d /proc/acpi ]; then
# use ACPI as a fallback
Index: cpuspeed.spec
===================================================================
RCS file: /cvs/pkgs/rpms/cpuspeed/F-8/cpuspeed.spec,v
retrieving revision 1.61
retrieving revision 1.62
diff -u -r1.61 -r1.62
--- cpuspeed.spec 29 Aug 2007 19:04:12 -0000 1.61
+++ cpuspeed.spec 14 Feb 2008 22:43:24 -0000 1.62
@@ -1,7 +1,7 @@
Summary: CPU frequency adjusting daemon
Name: cpuspeed
Version: 1.2.1
-Release: 3%{?dist}
+Release: 5%{?dist}
Epoch: 1
Group: System Environment/Base
License: GPL
@@ -23,6 +23,8 @@
Patch1: warning.diff
Patch2: idlenice.diff
Patch3: cpuspeed-1.2.1-make.patch
+Patch4: cpuspeed-1.2.1-make-gcc43-happy.patch
+Patch5: cpuspeed-1.2.1-multicore-workaround.patch
%description
cpuspeed is a daemon that dynamically changes the speed
@@ -42,6 +44,8 @@
%patch1 -p1 -b .warn
%patch2 -p1 -b .idle
%patch3 -p1 -b .make
+%patch4 -p1 -b .gcc43
+%patch5 -p1 -b .multicore
%build
rm -rf $RPM_BUILD_ROOT
@@ -85,6 +89,13 @@
exit 0
%changelog
+* Thu Feb 14 2008 Jarod Wilson <jwilson at redhat.com> 1.2.1-5
+- Support for powernow-k8 as a kernel module
+
+* Tue Feb 12 2008 Jarod Wilson <jwilson at redhat.com> 1.2.1-4
+- Fix up for gcc 4.3
+- Work around multi-core step detection problems (#392781)
+
* Wed Aug 29 2007 Jarod Wilson <jwilson at redhat.com> 1.2.1-3
- Bump and rebuild, due to busted ppc32
- Previous message (by thread): rpms/kernel/devel config-x86-generic, 1.27, 1.28 config-x86_64-generic, 1.24, 1.25 kernel.spec, 1.428, 1.429
- Next message (by thread): rpms/cpuspeed/F-7 cpuspeed-1.2.1-make-gcc43-happy.patch, NONE, 1.1 cpuspeed-1.2.1-multicore-workaround.patch, NONE, 1.1 cpuspeed.init, 1.35, 1.36 cpuspeed.spec, 1.60, 1.61
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the fedora-extras-commits
mailing list