OSDN Git Service

wifi: mt76: mt7915: rework mt7915_mcu_set_thermal_throttling
authorHoward Hsu <howard-yh.hsu@mediatek.com>
Wed, 14 Dec 2022 02:28:07 +0000 (10:28 +0800)
committerFelix Fietkau <nbd@nbd.name>
Fri, 3 Feb 2023 13:47:15 +0000 (14:47 +0100)
commit5ad42d19f6596e54b091827c397fdb7c091d45f7
tree6a4ee9f9b757bd95926985cf1f408c1c030b0c93
parent7d12b38ab6f6b77198cd3a66db19587bbdd3308c
wifi: mt76: mt7915: rework mt7915_mcu_set_thermal_throttling

This patch includes 2 changes:
1. Firmware expects to disable thermal protect first before
reconfiguring.
2. Separate setting thermal_protect and setting thermal_tx_duty into
different functions. These two firmware commands do not need to send
together.

Fixes: 34b877d972be ("mt76: mt7915: add thermal cooling device support")
Reviewed-by: Ryder Lee <ryder.lee@mediatek.com>
Signed-off-by: Howard Hsu <howard-yh.hsu@mediatek.com>
Signed-off-by: Felix Fietkau <nbd@nbd.name>
drivers/net/wireless/mediatek/mt76/mt7915/init.c
drivers/net/wireless/mediatek/mt76/mt7915/main.c
drivers/net/wireless/mediatek/mt76/mt7915/mcu.c
drivers/net/wireless/mediatek/mt76/mt7915/mt7915.h