diff options
author | Tamizh chelvam <c_traja@qti.qualcomm.com> | 2015-10-31 10:20:32 +0100 |
---|---|---|
committer | Kalle Valo <kvalo@qca.qualcomm.com> | 2015-11-04 18:31:46 +0100 |
commit | 6dd46348b935043d8748ad39ef7e9275b0c53c47 (patch) | |
tree | 57d59aeea6b25684a6c42bc83216bac7e9738e91 | |
parent | ath10k: set peer MFP flag in peer assoc command (diff) | |
download | linux-6dd46348b935043d8748ad39ef7e9275b0c53c47.tar.xz linux-6dd46348b935043d8748ad39ef7e9275b0c53c47.zip |
ath10k: add thermal throttling support for 10.4 firmware
This patch enables thermal throttling support for 10.4 firmware.
Signed-off-by: Tamizh chelvam <c_traja@qti.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
-rw-r--r-- | drivers/net/wireless/ath/ath10k/thermal.c | 2 | ||||
-rw-r--r-- | drivers/net/wireless/ath/ath10k/wmi.c | 4 |
2 files changed, 5 insertions, 1 deletions
diff --git a/drivers/net/wireless/ath/ath10k/thermal.c b/drivers/net/wireless/ath/ath10k/thermal.c index 60fe562e3041..444b52c7e4f3 100644 --- a/drivers/net/wireless/ath/ath10k/thermal.c +++ b/drivers/net/wireless/ath/ath10k/thermal.c @@ -187,7 +187,7 @@ int ath10k_thermal_register(struct ath10k *ar) /* Do not register hwmon device when temperature reading is not * supported by firmware */ - if (ar->wmi.op_version != ATH10K_FW_WMI_OP_VERSION_10_2_4) + if (!(ar->wmi.ops->gen_pdev_get_temperature)) return 0; /* Avoid linking error on devm_hwmon_device_register_with_groups, I diff --git a/drivers/net/wireless/ath/ath10k/wmi.c b/drivers/net/wireless/ath/ath10k/wmi.c index 8cd068b5c2ad..e3ce8f09f110 100644 --- a/drivers/net/wireless/ath/ath10k/wmi.c +++ b/drivers/net/wireless/ath/ath10k/wmi.c @@ -5103,6 +5103,9 @@ static void ath10k_wmi_10_4_op_rx(struct ath10k *ar, struct sk_buff *skb) case WMI_10_4_UPDATE_STATS_EVENTID: ath10k_wmi_event_update_stats(ar, skb); break; + case WMI_10_4_PDEV_TEMPERATURE_EVENTID: + ath10k_wmi_event_temperature(ar, skb); + break; default: ath10k_warn(ar, "Unknown eventid: %d\n", id); break; @@ -7599,6 +7602,7 @@ static const struct wmi_ops wmi_10_4_ops = { /* shared with 10.2 */ .gen_peer_assoc = ath10k_wmi_10_2_op_gen_peer_assoc, .gen_request_stats = ath10k_wmi_op_gen_request_stats, + .gen_pdev_get_temperature = ath10k_wmi_10_2_op_gen_pdev_get_temperature, }; int ath10k_wmi_attach(struct ath10k *ar) |