summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichal Marek <mmarek@suse.com>2015-11-26 14:48:54 +0100
committerMichal Marek <mmarek@suse.com>2015-11-26 20:53:07 +0100
commitde5315ce36463141b6d3743bec890e93443ebcb2 (patch)
tree355f47c10e26375564f5f609da69c9d289d8e6a9
parent5921be792da61a84e0b53ed64908aab8145c859d (diff)
downloadlinux-de5315ce36463141b6d3743bec890e93443ebcb2.tar.bz2
ath10k: Fix build with CONFIG_THERMAL=m
After commit cf4f21938e13 ("kbuild: Allow to specify composite modules with modname-m"), thermal.c gets included in the driver and the build fails with drivers/net/wireless/ath/ath10k/thermal.c:119:6: error: redefinition of ‘ath10k_thermal_event_temperature’ drivers/net/wireless/ath/ath10k/thermal.h:54:20: note: previous definition of ‘ath10k_thermal_event_temperature’ was here drivers/net/wireless/ath/ath10k/thermal.c:136:6: error: redefinition of ‘ath10k_thermal_set_throttling’ drivers/net/wireless/ath/ath10k/thermal.h:59:20: note: previous definition of ‘ath10k_thermal_set_throttling’ was here drivers/net/wireless/ath/ath10k/thermal.c:162:5: error: redefinition of ‘ath10k_thermal_register’ drivers/net/wireless/ath/ath10k/thermal.h:45:19: note: previous definition of ‘ath10k_thermal_register’ was here drivers/net/wireless/ath/ath10k/thermal.c:216:6: error: redefinition of ‘ath10k_thermal_unregister’ drivers/net/wireless/ath/ath10k/thermal.h:50:20: note: previous definition of ‘ath10k_thermal_unregister’ was here Change the #ifdef to reflect the new kbuild behavior. Reported-by: kbuild test robot <fengguang.wu@intel.com> Acked-by: Kalle Valo <kvalo@qca.qualcomm.com> Signed-off-by: Michal Marek <mmarek@suse.com>
-rw-r--r--drivers/net/wireless/ath/ath10k/thermal.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/wireless/ath/ath10k/thermal.h b/drivers/net/wireless/ath/ath10k/thermal.h
index b610ea5caae8..c9223e9e962f 100644
--- a/drivers/net/wireless/ath/ath10k/thermal.h
+++ b/drivers/net/wireless/ath/ath10k/thermal.h
@@ -36,7 +36,7 @@ struct ath10k_thermal {
int temperature;
};
-#ifdef CONFIG_THERMAL
+#if IS_REACHABLE(CONFIG_THERMAL)
int ath10k_thermal_register(struct ath10k *ar);
void ath10k_thermal_unregister(struct ath10k *ar);
void ath10k_thermal_event_temperature(struct ath10k *ar, int temperature);