From 632fec680d996a5dd015afd9acf0ba40f75e69e2 Mon Sep 17 00:00:00 2001 From: lvs1974 Date: Mon, 21 Feb 2022 19:32:40 +0100 Subject: [PATCH] minor cosmetic fixes --- Sensors/SMCDellSensors/SMIMonitor.cpp | 8 ++++---- Sensors/SMCDellSensors/SMIMonitor.hpp | 1 - 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/Sensors/SMCDellSensors/SMIMonitor.cpp b/Sensors/SMCDellSensors/SMIMonitor.cpp index 3ed0471..5c747df 100644 --- a/Sensors/SMCDellSensors/SMIMonitor.cpp +++ b/Sensors/SMCDellSensors/SMIMonitor.cpp @@ -407,8 +407,8 @@ bool SMIMonitor::findFanSensors() { { state.fanInfo[fanCount].index = i; state.fanInfo[fanCount].status = rc; - state.fanInfo[fanCount].minSpeed = i8k_get_fan_nominal_speed(i, 1); - state.fanInfo[fanCount].maxSpeed = i8k_get_fan_nominal_speed(i, 2); + state.fanInfo[fanCount].minSpeed = i8k_get_fan_nominal_speed(i, I8K_FAN_LOW); + state.fanInfo[fanCount].maxSpeed = i8k_get_fan_nominal_speed(i, I8K_FAN_HIGH); rc = i8k_get_fan_speed(i, true); if (rc >= 0) state.fanInfo[i].speed = rc; @@ -461,7 +461,7 @@ void SMIMonitor::staticUpdateThreadEntry(thread_call_param_t param0, thread_call } bool success = true; - while (1) { + while (true) { IOReturn result = that->bindCurrentThreadToCpu0(); if (result != KERN_SUCCESS) { @@ -509,7 +509,7 @@ void SMIMonitor::updateSensorsLoop() { i8k_set_fan_control_auto(); // force automatic control - while (1) { + while (true) { bool force_access = (--force_update_counter >= 0); diff --git a/Sensors/SMCDellSensors/SMIMonitor.hpp b/Sensors/SMCDellSensors/SMIMonitor.hpp index 1cd1ab6..68e21e3 100644 --- a/Sensors/SMCDellSensors/SMIMonitor.hpp +++ b/Sensors/SMCDellSensors/SMIMonitor.hpp @@ -295,7 +295,6 @@ class SMIMonitor : public OSObject bool i8k_get_dell_signature(); int i8k_get_temp(int sensor, bool force_access = false); int i8k_get_temp_type(int sensor); - int i8k_get_power_status(); int i8k_get_fan_speed(int fan, bool force_access = false); int i8k_get_fan_status(int fan); int i8k_get_fan_type(int fan);