SHA256
1
0
forked from pool/cpupower

- Rename SandyBridge monitor to IvyBridge if CPU is an IvyBridge

OBS-URL: https://build.opensuse.org/package/show/hardware/cpupower?expand=0&rev=19
This commit is contained in:
Thomas Renninger 2012-11-13 11:27:12 +00:00 committed by Git OBS Bridge
parent 7a121c9194
commit ae4dd354e3
3 changed files with 22 additions and 10 deletions

View File

@ -7,10 +7,15 @@ Git-repo: gitolite@ra.kernel.org:/pub/scm/linux/kernel/git/trenn/cpupower
Signed-off-by: Thomas Renninger <trenn@suse.de>
diff --git a/utils/helpers/cpuid.c b/utils/helpers/cpuid.c
index 906895d..93b0aa7 100644
--- a/utils/helpers/cpuid.c
+++ b/utils/helpers/cpuid.c
---
utils/helpers/cpuid.c | 2 ++
utils/idle_monitor/snb_idle.c | 13 +++++++++++--
2 files changed, 13 insertions(+), 2 deletions(-)
Index: cpupower-3.4.rc6/utils/helpers/cpuid.c
===================================================================
--- cpupower-3.4.rc6.orig/utils/helpers/cpuid.c
+++ cpupower-3.4.rc6/utils/helpers/cpuid.c
@@ -158,6 +158,8 @@ out:
cpu_info->caps |= CPUPOWER_CAP_HAS_TURBO_RATIO;
case 0x2A: /* SNB */
@ -20,11 +25,11 @@ index 906895d..93b0aa7 100644
cpu_info->caps |= CPUPOWER_CAP_HAS_TURBO_RATIO;
cpu_info->caps |= CPUPOWER_CAP_IS_SNB;
break;
diff --git a/utils/idle_monitor/snb_idle.c b/utils/idle_monitor/snb_idle.c
index a1bc07c..a99b43b 100644
--- a/utils/idle_monitor/snb_idle.c
+++ b/utils/idle_monitor/snb_idle.c
@@ -150,9 +150,15 @@ static struct cpuidle_monitor *snb_register(void)
Index: cpupower-3.4.rc6/utils/idle_monitor/snb_idle.c
===================================================================
--- cpupower-3.4.rc6.orig/utils/idle_monitor/snb_idle.c
+++ cpupower-3.4.rc6/utils/idle_monitor/snb_idle.c
@@ -150,9 +150,18 @@ static struct cpuidle_monitor *snb_regis
|| cpupower_cpu_info.family != 6)
return NULL;
@ -33,8 +38,11 @@ index a1bc07c..a99b43b 100644
+ switch (cpupower_cpu_info.model) {
+ case 0x2A: /* SNB */
+ case 0x2D: /* SNB Xeon */
+ /* Monitor named SandyBridge by default */
+ break;
+ case 0x3A: /* IVB */
+ case 0x3E: /* IVB Xeon */
+ strcpy(intel_snb_monitor.name, "IvyBridge");
+ break;
+ default:
return NULL;

View File

@ -1,3 +1,8 @@
-------------------------------------------------------------------
Tue Nov 13 11:26:27 UTC 2012 - trenn@suse.de
- Rename SandyBridge monitor to IvyBridge if CPU is an IvyBridge
-------------------------------------------------------------------
Tue Nov 13 11:08:12 UTC 2012 - trenn@suse.de

View File

@ -17,7 +17,6 @@
#
Name: cpupower
Url: http://www.kernel.org/pub/linux/utils/kernel/cpufreq/cpufrequtils.html
# Use this as version when things are in mainline kernel