thermal: add sensor logging in thermalWatcherCallbackFunc
authorTeYuan Wang <kamewang@google.com>
Wed, 18 Mar 2020 14:12:16 +0000 (22:12 +0800)
committerFrancescodario Cuzzocrea <bosconovic@gmail.com>
Tue, 22 Dec 2020 10:37:19 +0000 (11:37 +0100)
Bug: 151818536
Test: Log can be printed as below:
      I/android.hardware.thermal@2.0-service.pixel(  889): skin-therm-monitor: 50

Change-Id: Iefd24ff48ead9c2da55640742abcb158e9b181c2
Signed-off-by: TeYuan Wang <kamewang@google.com>
hidl/thermal/thermal-helper.cpp

index 269b1de7ee1b249031b44d0a2a5ecb840147b3c0..b84b1a9aabd3d490ea152e7287080a2904853b5d 100644 (file)
@@ -605,6 +605,7 @@ bool ThermalHelper::thermalWatcherCallbackFunc(const std::set<std::string> &ueve
         }
         if (sensor_status.severity != ThrottlingSeverity::NONE) {
             thermal_triggered = true;
+            LOG(INFO) << temp.name << ": " << temp.value;
         }
     }
     if (!temps.empty() && cb_) {