diff options
author | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2024-02-07 20:09:15 +0100 |
---|---|---|
committer | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2024-02-08 14:54:55 +0100 |
commit | 2e171a57c312cb732d633c5ccc51551588b7a855 (patch) | |
tree | bc596aa82d921824c8a189a0799b998fe38b8efd /drivers/net/wireless/intel/iwlwifi/mvm/tt.c | |
parent | b377252eeec91f347cd538011f956a4fe73794b3 (diff) |
iwlwifi: mvm: Drop unused fw_trips_index[] from iwl_mvm_thermal_device
The fw_trips_index[] array in struct iwl_mvm_thermal_device is only
populated, but never read, so drop it.
Note that the iwl_mvm_send_temp_report_ths_cmd() code populating
fw_trips_index[] is questionable, because it accesses a trips table
of a thermal zone directly, which is not guaranteed to work in the
future.
No functional impact.
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Acked-by: Miri Korenblit <Miriam.rachel.korenblit@intel.com>
Diffstat (limited to 'drivers/net/wireless/intel/iwlwifi/mvm/tt.c')
-rw-r--r-- | drivers/net/wireless/intel/iwlwifi/mvm/tt.c | 13 |
1 files changed, 1 insertions, 12 deletions
diff --git a/drivers/net/wireless/intel/iwlwifi/mvm/tt.c b/drivers/net/wireless/intel/iwlwifi/mvm/tt.c index dee9c367dcd3..a2f921a1f5bd 100644 --- a/drivers/net/wireless/intel/iwlwifi/mvm/tt.c +++ b/drivers/net/wireless/intel/iwlwifi/mvm/tt.c @@ -562,7 +562,7 @@ int iwl_mvm_send_temp_report_ths_cmd(struct iwl_mvm *mvm) struct temp_report_ths_cmd cmd = {0}; int ret; #ifdef CONFIG_THERMAL - int i, j, idx = 0; + int i, idx = 0; lockdep_assert_held(&mvm->mutex); @@ -588,17 +588,6 @@ int iwl_mvm_send_temp_report_ths_cmd(struct iwl_mvm *mvm) /*sort cmd array*/ sort(cmd.thresholds, idx, sizeof(s16), compare_temps, NULL); - /* we should save the indexes of trips because we sort - * and compress the orginal array - */ - for (i = 0; i < idx; i++) { - for (j = 0; j < IWL_MAX_DTS_TRIPS; j++) { - if ((int)(le16_to_cpu(cmd.thresholds[i]) * 1000) == - mvm->tz_device.trips[j].temperature) - mvm->tz_device.fw_trips_index[i] = j; - } - } - send: #endif ret = iwl_mvm_send_cmd_pdu(mvm, WIDE_ID(PHY_OPS_GROUP, |