~ubuntu-branches/ubuntu/utopic/thermald/utopic

« back to all changes in this revision

Viewing changes to debian/patches/0010-Fix-compenstion-using-Processor-thermal-cooling-devi.patch

  • Committer: Package Import Robot
  • Author(s): Colin King
  • Date: 2014-05-19 12:41:22 UTC
  • mfrom: (1.1.1)
  • Revision ID: package-import@ubuntu.com-20140519124122-zan11arvjxtbqcq5
Tags: 1.2-1
* Adjust for coretemp path change
* Deny non root users to send system bus dbus messages
* Remove compile warning
* Remove rpmlint warning for manual page
* Remove old patches that are now included into version 1.2
* Sync up with version 1.2

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
From a93b56fc57b517f228910355d3a0fe8ff22ebc41 Mon Sep 17 00:00:00 2001
2
 
From: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
3
 
Date: Mon, 3 Feb 2014 10:26:13 -0800
4
 
Subject: [PATCH 3/3] Fix compenstion using "Processor" thermal cooling device
5
 
 
6
 
When any of the processor state is changed, it will impact all
7
 
processors. If thermal sysfs defines different cdev trip for
8
 
each processor, if we read and apply, the next processor will
9
 
already impacted by change by previous cdev.
10
 
---
11
 
 src/thd_cdev_therm_sys_fs.cpp | 7 +++++++
12
 
 1 file changed, 7 insertions(+)
13
 
 
14
 
diff --git a/src/thd_cdev_therm_sys_fs.cpp b/src/thd_cdev_therm_sys_fs.cpp
15
 
index b7d16f8..a01d608 100644
16
 
--- a/src/thd_cdev_therm_sys_fs.cpp
17
 
+++ b/src/thd_cdev_therm_sys_fs.cpp
18
 
@@ -54,6 +54,13 @@ int cthd_sysfs_cdev::update() {
19
 
        tc_type_dev << "cooling_device" << index << "/type";
20
 
        if (cdev_sysfs.exists(tc_type_dev.str())) {
21
 
                cdev_sysfs.read(tc_type_dev.str(), type_str);
22
 
+               if (type_str.size()) {
23
 
+                       // They essentially change same ACPI object, so reading their
24
 
+                       // state from sysfs after a change to any processor will cause
25
 
+                       // double compensation
26
 
+                       if (type_str == "Processor")
27
 
+                               read_back = false;
28
 
+               }
29
 
        }
30
 
 
31
 
        thd_log_debug("cooling dev %d:%d:%d:%s\n", index, curr_state, max_state,
32
 
1.9.rc1
33