1 /* SPDX-License-Identifier: ISC */
3 * Copyright (c) 2014-2016 Qualcomm Atheros, Inc.
8 #define ATH10K_QUIET_PERIOD_DEFAULT 100
9 #define ATH10K_QUIET_PERIOD_MIN 25
10 #define ATH10K_QUIET_START_OFFSET 10
11 #define ATH10K_HWMON_NAME_LEN 15
12 #define ATH10K_THERMAL_SYNC_TIMEOUT_HZ (5 * HZ)
13 #define ATH10K_THERMAL_THROTTLE_MAX 100
15 struct ath10k_thermal
{
16 struct thermal_cooling_device
*cdev
;
17 struct completion wmi_sync
;
19 /* protected by conf_mutex */
22 /* temperature value in Celcius degree
23 * protected by data_lock
28 #if IS_REACHABLE(CONFIG_THERMAL)
29 int ath10k_thermal_register(struct ath10k
*ar
);
30 void ath10k_thermal_unregister(struct ath10k
*ar
);
31 void ath10k_thermal_event_temperature(struct ath10k
*ar
, int temperature
);
32 void ath10k_thermal_set_throttling(struct ath10k
*ar
);
34 static inline int ath10k_thermal_register(struct ath10k
*ar
)
39 static inline void ath10k_thermal_unregister(struct ath10k
*ar
)
43 static inline void ath10k_thermal_event_temperature(struct ath10k
*ar
,
48 static inline void ath10k_thermal_set_throttling(struct ath10k
*ar
)
53 #endif /* _THERMAL_ */