commit 19fea16d2b3934d1ba621278f1e3ba62cea86d76
Author: Jan Rękorajski <[email protected]>
Date:   Sat Mar 4 02:04:05 2017 +0100

    - do not disable cpufreq on pstate cpus, see 
https://www.kernel.org/doc/Documentation/cpu-freq/intel-pstate.txt

 cpufreq-pstate.patch   | 14 ++++++++++++++
 laptop-mode-tools.spec |  2 ++
 2 files changed, 16 insertions(+)
---
diff --git a/laptop-mode-tools.spec b/laptop-mode-tools.spec
index f37e7d2..38626ae 100644
--- a/laptop-mode-tools.spec
+++ b/laptop-mode-tools.spec
@@ -25,6 +25,7 @@ Source0:      
https://github.com/rickysarraf/laptop-mode-tools/archive/%{version}/%{n
 # Source0-md5: 8b9a2d9db7dd9d0a99b635a1185f292c
 Source1:       %{name}.init
 Patch0:                no-exec-redirection.patch
+Patch1:                cpufreq-pstate.patch
 URL:           https://github.com/rickysarraf/laptop-mode-tools
 BuildRequires: rpm-pythonprov
 BuildRequires: rpmbuild(macros) >= 1.714
@@ -102,6 +103,7 @@ GUI dla narzędzi do trybu laptopowego.
 %prep
 %setup -q
 %patch0 -p1
+%patch1 -p1
 
 %{__sed} -i -e 's|/usr/bin/env python2|/usr/bin/python|' gui/LMT.py
 
diff --git a/cpufreq-pstate.patch b/cpufreq-pstate.patch
new file mode 100644
index 0000000..bf4a15c
--- /dev/null
+++ b/cpufreq-pstate.patch
@@ -0,0 +1,14 @@
+--- laptop-mode-tools-1.71/usr/share/laptop-mode-tools/modules/cpufreq.orig    
2017-03-04 02:02:25.558983334 +0100
++++ laptop-mode-tools-1.71/usr/share/laptop-mode-tools/modules/cpufreq 
2017-03-04 02:03:04.729972792 +0100
+@@ -45,11 +45,6 @@
+               CPU_IGNORE_NICE_LOAD="$BATT_CPU_IGNORE_NICE_LOAD"
+       fi
+       for THISCPU in /sys/devices/system/cpu/* ; do
+-              if [ -f "$THISCPU/cpufreq/scaling_driver" ] &&
+-                 [ "$(cat $THISCPU/cpufreq/scaling_driver)" = "intel_pstate" ]
+-              then
+-                      continue # intel_pstate is a bit different - so it 
should be handled by its own module
+-              fi
+               if [ -e $THISCPU/cpufreq/cpuinfo_min_freq ]; then
+                       THIS_CPU_MAXFREQ="$CPU_MAXFREQ"
+                       THIS_CPU_MINFREQ="$CPU_MINFREQ"
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/laptop-mode-tools.git/commitdiff/19fea16d2b3934d1ba621278f1e3ba62cea86d76

_______________________________________________
pld-cvs-commit mailing list
[email protected]
http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit

Reply via email to