Comment 24 for bug 1656528

Revision history for this message
Colin Ian King (colin-king) wrote :

FYI, I've updated the thermald package in the PPA to a version 1.5.3-5~2, this contains a proposed change as suggested by Srinivas (see below). I'd be interested to see how this works for you.

..to get the updated thermald please run:

sudo apt-get update && sudo apt-get upgrade

diff --git a/src/thd_sys_fs.cpp b/src/thd_sys_fs.cpp
index 044c8f0..055fc28 100644
--- a/src/thd_sys_fs.cpp
+++ b/src/thd_sys_fs.cpp
@@ -30,13 +30,13 @@ int csys_fs::write(const std::string &path, const
std::string &buf) {
        std::string p = base_path + path;
        int fd = ::open(p.c_str(), O_WRONLY);
        if (fd < 0) {
- thd_log_warn("sysfs write failed %s\n", p.c_str());
+ thd_log_debug("sysfs write failed %s\n", p.c_str());
                return -errno;
        }
        int ret = ::write(fd, buf.c_str(), buf.size());
        if (ret < 0) {
                ret = -errno;
- thd_log_warn("sysfs write failed %s\n", p.c_str());
+ thd_log_debug("sysfs write failed %s\n", p.c_str());
        }
        close(fd);

@@ -48,17 +48,17 @@ long long data) {
        std::string p = base_path + path;
        int fd = ::open(p.c_str(), O_WRONLY);
        if (fd < 0) {
- thd_log_warn("sysfs write failed %s\n", p.c_str());
+ thd_log_debug("sysfs write failed %s\n", p.c_str());
                return -errno;
        }
        if (::lseek(fd, position, SEEK_CUR) == -1) {
- thd_log_warn("sysfs write failed %s\n", p.c_str());
+ thd_log_debug("sysfs write failed %s\n", p.c_str());
                close(fd);
                return -errno;
        }
        int ret = ::write(fd, &data, sizeof(data));
        if (ret < 0)
- thd_log_warn("sysfs write failed %s\n", p.c_str());
+ thd_log_debug("sysfs write failed %s\n", p.c_str());
        close(fd);

        return ret;