Skip to contentSkip to conversation

iwlwifi: add dependency of THERMAL with IWLMVM

PATCH In review Mao Wenan 3 participants 3 messages Sep 18, 2019

Subsystems (4)
lore
Share & tools
lore

Mao Wenan

author
#0 lore raw

PATCH 1/1 iwlwifi: add dependency of THERMAL with IWLMVM

If CONFIG_IWLMVM=y, CONFIG_THERMAL=n, below error can be found:
drivers/net/wireless/intel/iwlwifi/mvm/fw.o: In function `iwl_mvm_up':
fw.c:(.text+0x2c26): undefined reference to `iwl_mvm_send_temp_report_ths_cmd'
make: *** [vmlinux] Error 1

After commit 242d9c8b9a93 ("iwlwifi: mvm: use FW thermal monitoring regardless of CONFIG_THERMAL"), iwl_mvm_up() calls iwl_mvm_send_temp_report_ths_cmd(), but this function is under CONFIG_THERMAL, which is depended on CONFIG_THERMAL.

Fixes 242d9c8b9a93 ("iwlwifi: mvm: use FW thermal monitoring regardless of CONFIG_THERMAL")
---
 drivers/net/wireless/intel/iwlwifi/Kconfig | 1 +
 1 file changed, 1 insertion(+)
drivers/net/wireless/intel/iwlwifi/Kconfig +1 -0
index 7dbc0d3..801aa0f 100644
@@ -65,6 +65,7 @@ config IWLMVM
 	tristate "Intel Wireless WiFi MVM Firmware support"
 	select WANT_DEV_COREDUMP
 	depends on MAC80211
+	depends on THERMAL
 	help
 	  This is the driver that supports the MVM firmware. The list
 	  of the devices that use this firmware is available here:
Signature · 1 line
2.7.4
#1 lore raw
Quoted 5 lines · Mao Wenan

If CONFIG_IWLMVM=y, CONFIG_THERMAL=n, below error can be found:
drivers/net/wireless/intel/iwlwifi/mvm/fw.o: In function `iwl_mvm_up':
fw.c:(.text+0x2c26): undefined reference to `iwl_mvm_send_temp_report_ths_cmd'
make: *** [vmlinux] Error 1

Quoted 7 lines

After commit 242d9c8b9a93 ("iwlwifi: mvm: use FW thermal monitoring regardless of CONFIG_THERMAL"), iwl_mvm_up() calls iwl_mvm_send_temp_report_ths_cmd(), but this function is under CONFIG_THERMAL, which is depended on CONFIG_THERMAL.

Fixes 242d9c8b9a93 ("iwlwifi: mvm: use FW thermal monitoring regardless of CONFIG_THERMAL")

Luca, should I apply this directly to wireless-drivers?

Signature · 1 line
https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches
#2 lore raw
Quoted 12 lines · Kalle Valo
Quoted 10 lines · Mao Wenan

If CONFIG_IWLMVM=y, CONFIG_THERMAL=n, below error can be found:
drivers/net/wireless/intel/iwlwifi/mvm/fw.o: In function `iwl_mvm_up':
fw.c:(.text+0x2c26): undefined reference to `iwl_mvm_send_temp_report_ths_cmd'
make: *** [vmlinux] Error 1

After commit 242d9c8b9a93 ("iwlwifi: mvm: use FW thermal monitoring regardless of CONFIG_THERMAL"), iwl_mvm_up() calls iwl_mvm_send_temp_report_ths_cmd(), but this function is under CONFIG_THERMAL, which is depended on CONFIG_THERMAL.

Quoted 4 lines
Quoted 2 lines
Fixes 242d9c8b9a93 ("iwlwifi: mvm: use FW thermal monitoring regardless of CONFIG_THERMAL")

Luca, should I apply this directly to wireless-drivers?

No, this patch defeats the point of the patch it fixes.

We have a proper fix already internally, which I haven't sent out yet, that moves a couple of #ifdef's around to solve the issue. I'll send the patch in a sec.

--
Cheers,
Luca.