1b843c749SSergey Zigachev /*
2b843c749SSergey Zigachev  * Copyright 2017 Advanced Micro Devices, Inc.
3b843c749SSergey Zigachev  *
4b843c749SSergey Zigachev  * Permission is hereby granted, free of charge, to any person obtaining a
5b843c749SSergey Zigachev  * copy of this software and associated documentation files (the "Software"),
6b843c749SSergey Zigachev  * to deal in the Software without restriction, including without limitation
7b843c749SSergey Zigachev  * the rights to use, copy, modify, merge, publish, distribute, sublicense,
8b843c749SSergey Zigachev  * and/or sell copies of the Software, and to permit persons to whom the
9b843c749SSergey Zigachev  * Software is furnished to do so, subject to the following conditions:
10b843c749SSergey Zigachev  *
11b843c749SSergey Zigachev  * The above copyright notice and this permission notice shall be included in
12b843c749SSergey Zigachev  * all copies or substantial portions of the Software.
13b843c749SSergey Zigachev  *
14b843c749SSergey Zigachev  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15b843c749SSergey Zigachev  * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16b843c749SSergey Zigachev  * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
17b843c749SSergey Zigachev  * THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR
18b843c749SSergey Zigachev  * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
19b843c749SSergey Zigachev  * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
20b843c749SSergey Zigachev  * OTHER DEALINGS IN THE SOFTWARE.
21b843c749SSergey Zigachev  *
22b843c749SSergey Zigachev  */
23b843c749SSergey Zigachev 
24b843c749SSergey Zigachev #include "vega12_thermal.h"
25b843c749SSergey Zigachev #include "vega12_hwmgr.h"
26b843c749SSergey Zigachev #include "vega12_smumgr.h"
27b843c749SSergey Zigachev #include "vega12_ppsmc.h"
28b843c749SSergey Zigachev #include "vega12_inc.h"
29b843c749SSergey Zigachev #include "soc15_common.h"
30b843c749SSergey Zigachev #include "pp_debug.h"
31b843c749SSergey Zigachev 
vega12_get_current_rpm(struct pp_hwmgr * hwmgr,uint32_t * current_rpm)32b843c749SSergey Zigachev static int vega12_get_current_rpm(struct pp_hwmgr *hwmgr, uint32_t *current_rpm)
33b843c749SSergey Zigachev {
34b843c749SSergey Zigachev 	PP_ASSERT_WITH_CODE(!smum_send_msg_to_smc(hwmgr,
35b843c749SSergey Zigachev 				PPSMC_MSG_GetCurrentRpm),
36b843c749SSergey Zigachev 			"Attempt to get current RPM from SMC Failed!",
37b843c749SSergey Zigachev 			return -EINVAL);
38b843c749SSergey Zigachev 	*current_rpm = smum_get_argument(hwmgr);
39b843c749SSergey Zigachev 
40b843c749SSergey Zigachev 	return 0;
41b843c749SSergey Zigachev }
42b843c749SSergey Zigachev 
vega12_fan_ctrl_get_fan_speed_info(struct pp_hwmgr * hwmgr,struct phm_fan_speed_info * fan_speed_info)43b843c749SSergey Zigachev int vega12_fan_ctrl_get_fan_speed_info(struct pp_hwmgr *hwmgr,
44b843c749SSergey Zigachev 		struct phm_fan_speed_info *fan_speed_info)
45b843c749SSergey Zigachev {
46b843c749SSergey Zigachev 	memset(fan_speed_info, 0, sizeof(*fan_speed_info));
47b843c749SSergey Zigachev 	fan_speed_info->supports_percent_read = false;
48b843c749SSergey Zigachev 	fan_speed_info->supports_percent_write = false;
49b843c749SSergey Zigachev 	fan_speed_info->supports_rpm_read = true;
50b843c749SSergey Zigachev 	fan_speed_info->supports_rpm_write = true;
51b843c749SSergey Zigachev 
52b843c749SSergey Zigachev 	return 0;
53b843c749SSergey Zigachev }
54b843c749SSergey Zigachev 
vega12_fan_ctrl_get_fan_speed_rpm(struct pp_hwmgr * hwmgr,uint32_t * speed)55b843c749SSergey Zigachev int vega12_fan_ctrl_get_fan_speed_rpm(struct pp_hwmgr *hwmgr, uint32_t *speed)
56b843c749SSergey Zigachev {
57b843c749SSergey Zigachev 	*speed = 0;
58b843c749SSergey Zigachev 
59b843c749SSergey Zigachev 	return vega12_get_current_rpm(hwmgr, speed);
60b843c749SSergey Zigachev }
61b843c749SSergey Zigachev 
62b843c749SSergey Zigachev /**
63b843c749SSergey Zigachev  * @fn vega12_enable_fan_control_feature
64b843c749SSergey Zigachev  * @brief Enables the SMC Fan Control Feature.
65b843c749SSergey Zigachev  *
66b843c749SSergey Zigachev  * @param    hwmgr - the address of the powerplay hardware manager.
67b843c749SSergey Zigachev  * @return   0 on success. -1 otherwise.
68b843c749SSergey Zigachev  */
vega12_enable_fan_control_feature(struct pp_hwmgr * hwmgr)69b843c749SSergey Zigachev static int vega12_enable_fan_control_feature(struct pp_hwmgr *hwmgr)
70b843c749SSergey Zigachev {
71b843c749SSergey Zigachev #if 0
72b843c749SSergey Zigachev 	struct vega12_hwmgr *data = (struct vega12_hwmgr *)(hwmgr->backend);
73b843c749SSergey Zigachev 
74b843c749SSergey Zigachev 	if (data->smu_features[GNLD_FAN_CONTROL].supported) {
75b843c749SSergey Zigachev 		PP_ASSERT_WITH_CODE(!vega12_enable_smc_features(
76b843c749SSergey Zigachev 				hwmgr, true,
77b843c749SSergey Zigachev 				data->smu_features[GNLD_FAN_CONTROL].
78b843c749SSergey Zigachev 				smu_feature_bitmap),
79b843c749SSergey Zigachev 				"Attempt to Enable FAN CONTROL feature Failed!",
80b843c749SSergey Zigachev 				return -1);
81b843c749SSergey Zigachev 		data->smu_features[GNLD_FAN_CONTROL].enabled = true;
82b843c749SSergey Zigachev 	}
83b843c749SSergey Zigachev #endif
84b843c749SSergey Zigachev 	return 0;
85b843c749SSergey Zigachev }
86b843c749SSergey Zigachev 
vega12_disable_fan_control_feature(struct pp_hwmgr * hwmgr)87b843c749SSergey Zigachev static int vega12_disable_fan_control_feature(struct pp_hwmgr *hwmgr)
88b843c749SSergey Zigachev {
89b843c749SSergey Zigachev #if 0
90b843c749SSergey Zigachev 	struct vega12_hwmgr *data = (struct vega12_hwmgr *)(hwmgr->backend);
91b843c749SSergey Zigachev 
92b843c749SSergey Zigachev 	if (data->smu_features[GNLD_FAN_CONTROL].supported) {
93b843c749SSergey Zigachev 		PP_ASSERT_WITH_CODE(!vega12_enable_smc_features(
94b843c749SSergey Zigachev 				hwmgr, false,
95b843c749SSergey Zigachev 				data->smu_features[GNLD_FAN_CONTROL].
96b843c749SSergey Zigachev 				smu_feature_bitmap),
97b843c749SSergey Zigachev 				"Attempt to Enable FAN CONTROL feature Failed!",
98b843c749SSergey Zigachev 				return -1);
99b843c749SSergey Zigachev 		data->smu_features[GNLD_FAN_CONTROL].enabled = false;
100b843c749SSergey Zigachev 	}
101b843c749SSergey Zigachev #endif
102b843c749SSergey Zigachev 	return 0;
103b843c749SSergey Zigachev }
104b843c749SSergey Zigachev 
vega12_fan_ctrl_start_smc_fan_control(struct pp_hwmgr * hwmgr)105b843c749SSergey Zigachev int vega12_fan_ctrl_start_smc_fan_control(struct pp_hwmgr *hwmgr)
106b843c749SSergey Zigachev {
107b843c749SSergey Zigachev 	struct vega12_hwmgr *data = (struct vega12_hwmgr *)(hwmgr->backend);
108b843c749SSergey Zigachev 
109b843c749SSergey Zigachev 	if (data->smu_features[GNLD_FAN_CONTROL].supported)
110b843c749SSergey Zigachev 		PP_ASSERT_WITH_CODE(
111b843c749SSergey Zigachev 				!vega12_enable_fan_control_feature(hwmgr),
112b843c749SSergey Zigachev 				"Attempt to Enable SMC FAN CONTROL Feature Failed!",
113b843c749SSergey Zigachev 				return -1);
114b843c749SSergey Zigachev 
115b843c749SSergey Zigachev 	return 0;
116b843c749SSergey Zigachev }
117b843c749SSergey Zigachev 
118b843c749SSergey Zigachev 
vega12_fan_ctrl_stop_smc_fan_control(struct pp_hwmgr * hwmgr)119b843c749SSergey Zigachev int vega12_fan_ctrl_stop_smc_fan_control(struct pp_hwmgr *hwmgr)
120b843c749SSergey Zigachev {
121b843c749SSergey Zigachev 	struct vega12_hwmgr *data = (struct vega12_hwmgr *)(hwmgr->backend);
122b843c749SSergey Zigachev 
123b843c749SSergey Zigachev 	if (data->smu_features[GNLD_FAN_CONTROL].supported)
124b843c749SSergey Zigachev 		PP_ASSERT_WITH_CODE(!vega12_disable_fan_control_feature(hwmgr),
125b843c749SSergey Zigachev 				"Attempt to Disable SMC FAN CONTROL Feature Failed!",
126b843c749SSergey Zigachev 				return -1);
127b843c749SSergey Zigachev 
128b843c749SSergey Zigachev 	return 0;
129b843c749SSergey Zigachev }
130b843c749SSergey Zigachev 
131b843c749SSergey Zigachev /**
132b843c749SSergey Zigachev * Reset Fan Speed to default.
133b843c749SSergey Zigachev * @param    hwmgr  the address of the powerplay hardware manager.
134b843c749SSergey Zigachev * @exception Always succeeds.
135b843c749SSergey Zigachev */
vega12_fan_ctrl_reset_fan_speed_to_default(struct pp_hwmgr * hwmgr)136b843c749SSergey Zigachev int vega12_fan_ctrl_reset_fan_speed_to_default(struct pp_hwmgr *hwmgr)
137b843c749SSergey Zigachev {
138b843c749SSergey Zigachev 	return vega12_fan_ctrl_start_smc_fan_control(hwmgr);
139b843c749SSergey Zigachev }
140b843c749SSergey Zigachev 
141b843c749SSergey Zigachev /**
142b843c749SSergey Zigachev * Reads the remote temperature from the SIslands thermal controller.
143b843c749SSergey Zigachev *
144b843c749SSergey Zigachev * @param    hwmgr The address of the hardware manager.
145b843c749SSergey Zigachev */
vega12_thermal_get_temperature(struct pp_hwmgr * hwmgr)146b843c749SSergey Zigachev int vega12_thermal_get_temperature(struct pp_hwmgr *hwmgr)
147b843c749SSergey Zigachev {
148b843c749SSergey Zigachev 	struct amdgpu_device *adev = hwmgr->adev;
149b843c749SSergey Zigachev 	int temp = 0;
150b843c749SSergey Zigachev 
151b843c749SSergey Zigachev 	temp = RREG32_SOC15(THM, 0, mmCG_MULT_THERMAL_STATUS);
152b843c749SSergey Zigachev 
153b843c749SSergey Zigachev 	temp = (temp & CG_MULT_THERMAL_STATUS__CTF_TEMP_MASK) >>
154b843c749SSergey Zigachev 			CG_MULT_THERMAL_STATUS__CTF_TEMP__SHIFT;
155b843c749SSergey Zigachev 
156b843c749SSergey Zigachev 	temp = temp & 0x1ff;
157b843c749SSergey Zigachev 
158b843c749SSergey Zigachev 	temp *= PP_TEMPERATURE_UNITS_PER_CENTIGRADES;
159b843c749SSergey Zigachev 	return temp;
160b843c749SSergey Zigachev }
161b843c749SSergey Zigachev 
162b843c749SSergey Zigachev /**
163b843c749SSergey Zigachev * Set the requested temperature range for high and low alert signals
164b843c749SSergey Zigachev *
165b843c749SSergey Zigachev * @param    hwmgr The address of the hardware manager.
166b843c749SSergey Zigachev * @param    range Temperature range to be programmed for
167b843c749SSergey Zigachev *           high and low alert signals
168b843c749SSergey Zigachev * @exception PP_Result_BadInput if the input data is not valid.
169b843c749SSergey Zigachev */
vega12_thermal_set_temperature_range(struct pp_hwmgr * hwmgr,struct PP_TemperatureRange * range)170b843c749SSergey Zigachev static int vega12_thermal_set_temperature_range(struct pp_hwmgr *hwmgr,
171b843c749SSergey Zigachev 		struct PP_TemperatureRange *range)
172b843c749SSergey Zigachev {
173b843c749SSergey Zigachev 	struct phm_ppt_v3_information *pptable_information =
174b843c749SSergey Zigachev 		(struct phm_ppt_v3_information *)hwmgr->pptable;
175b843c749SSergey Zigachev 	struct amdgpu_device *adev = hwmgr->adev;
176b843c749SSergey Zigachev 	int low = VEGA12_THERMAL_MINIMUM_ALERT_TEMP *
177b843c749SSergey Zigachev 			PP_TEMPERATURE_UNITS_PER_CENTIGRADES;
178b843c749SSergey Zigachev 	int high = VEGA12_THERMAL_MAXIMUM_ALERT_TEMP *
179b843c749SSergey Zigachev 			PP_TEMPERATURE_UNITS_PER_CENTIGRADES;
180b843c749SSergey Zigachev 	uint32_t val;
181b843c749SSergey Zigachev 
182b843c749SSergey Zigachev 	if (low < range->min)
183b843c749SSergey Zigachev 		low = range->min;
184b843c749SSergey Zigachev 	if (high > pptable_information->us_software_shutdown_temp)
185b843c749SSergey Zigachev 		high = pptable_information->us_software_shutdown_temp;
186b843c749SSergey Zigachev 
187b843c749SSergey Zigachev 	if (low > high)
188b843c749SSergey Zigachev 		return -EINVAL;
189b843c749SSergey Zigachev 
190b843c749SSergey Zigachev 	val = RREG32_SOC15(THM, 0, mmTHM_THERMAL_INT_CTRL);
191b843c749SSergey Zigachev 
192b843c749SSergey Zigachev 	val = REG_SET_FIELD(val, THM_THERMAL_INT_CTRL, MAX_IH_CREDIT, 5);
193b843c749SSergey Zigachev 	val = REG_SET_FIELD(val, THM_THERMAL_INT_CTRL, THERM_IH_HW_ENA, 1);
194b843c749SSergey Zigachev 	val = REG_SET_FIELD(val, THM_THERMAL_INT_CTRL, DIG_THERM_INTH, (high / PP_TEMPERATURE_UNITS_PER_CENTIGRADES));
195b843c749SSergey Zigachev 	val = REG_SET_FIELD(val, THM_THERMAL_INT_CTRL, DIG_THERM_INTL, (low / PP_TEMPERATURE_UNITS_PER_CENTIGRADES));
196b843c749SSergey Zigachev 	val = val & (~THM_THERMAL_INT_CTRL__THERM_TRIGGER_MASK_MASK);
197b843c749SSergey Zigachev 
198b843c749SSergey Zigachev 	WREG32_SOC15(THM, 0, mmTHM_THERMAL_INT_CTRL, val);
199b843c749SSergey Zigachev 
200b843c749SSergey Zigachev 	return 0;
201b843c749SSergey Zigachev }
202b843c749SSergey Zigachev 
203b843c749SSergey Zigachev /**
204b843c749SSergey Zigachev * Enable thermal alerts on the RV770 thermal controller.
205b843c749SSergey Zigachev *
206b843c749SSergey Zigachev * @param    hwmgr The address of the hardware manager.
207b843c749SSergey Zigachev */
vega12_thermal_enable_alert(struct pp_hwmgr * hwmgr)208b843c749SSergey Zigachev static int vega12_thermal_enable_alert(struct pp_hwmgr *hwmgr)
209b843c749SSergey Zigachev {
210b843c749SSergey Zigachev 	struct amdgpu_device *adev = hwmgr->adev;
211b843c749SSergey Zigachev 	uint32_t val = 0;
212b843c749SSergey Zigachev 
213b843c749SSergey Zigachev 	val |= (1 << THM_THERMAL_INT_ENA__THERM_INTH_CLR__SHIFT);
214b843c749SSergey Zigachev 	val |= (1 << THM_THERMAL_INT_ENA__THERM_INTL_CLR__SHIFT);
215b843c749SSergey Zigachev 	val |= (1 << THM_THERMAL_INT_ENA__THERM_TRIGGER_CLR__SHIFT);
216b843c749SSergey Zigachev 
217b843c749SSergey Zigachev 	WREG32_SOC15(THM, 0, mmTHM_THERMAL_INT_ENA, val);
218b843c749SSergey Zigachev 
219b843c749SSergey Zigachev 	return 0;
220b843c749SSergey Zigachev }
221b843c749SSergey Zigachev 
222b843c749SSergey Zigachev /**
223b843c749SSergey Zigachev * Disable thermal alerts on the RV770 thermal controller.
224b843c749SSergey Zigachev * @param    hwmgr The address of the hardware manager.
225b843c749SSergey Zigachev */
vega12_thermal_disable_alert(struct pp_hwmgr * hwmgr)226b843c749SSergey Zigachev int vega12_thermal_disable_alert(struct pp_hwmgr *hwmgr)
227b843c749SSergey Zigachev {
228b843c749SSergey Zigachev 	struct amdgpu_device *adev = hwmgr->adev;
229b843c749SSergey Zigachev 
230b843c749SSergey Zigachev 	WREG32_SOC15(THM, 0, mmTHM_THERMAL_INT_ENA, 0);
231b843c749SSergey Zigachev 
232b843c749SSergey Zigachev 	return 0;
233b843c749SSergey Zigachev }
234b843c749SSergey Zigachev 
235b843c749SSergey Zigachev /**
236b843c749SSergey Zigachev * Uninitialize the thermal controller.
237b843c749SSergey Zigachev * Currently just disables alerts.
238b843c749SSergey Zigachev * @param    hwmgr The address of the hardware manager.
239b843c749SSergey Zigachev */
vega12_thermal_stop_thermal_controller(struct pp_hwmgr * hwmgr)240b843c749SSergey Zigachev int vega12_thermal_stop_thermal_controller(struct pp_hwmgr *hwmgr)
241b843c749SSergey Zigachev {
242b843c749SSergey Zigachev 	int result = vega12_thermal_disable_alert(hwmgr);
243b843c749SSergey Zigachev 
244b843c749SSergey Zigachev 	return result;
245b843c749SSergey Zigachev }
246b843c749SSergey Zigachev 
247b843c749SSergey Zigachev /**
248b843c749SSergey Zigachev * Set up the fan table to control the fan using the SMC.
249b843c749SSergey Zigachev * @param    hwmgr  the address of the powerplay hardware manager.
250b843c749SSergey Zigachev * @param    pInput the pointer to input data
251b843c749SSergey Zigachev * @param    pOutput the pointer to output data
252b843c749SSergey Zigachev * @param    pStorage the pointer to temporary storage
253b843c749SSergey Zigachev * @param    Result the last failure code
254b843c749SSergey Zigachev * @return   result from set temperature range routine
255b843c749SSergey Zigachev */
256*78973132SSergey Zigachev int vega12_thermal_setup_fan_table(struct pp_hwmgr *hwmgr);
vega12_thermal_setup_fan_table(struct pp_hwmgr * hwmgr)257b843c749SSergey Zigachev int vega12_thermal_setup_fan_table(struct pp_hwmgr *hwmgr)
258b843c749SSergey Zigachev {
259b843c749SSergey Zigachev 	int ret;
260b843c749SSergey Zigachev 	struct vega12_hwmgr *data = (struct vega12_hwmgr *)(hwmgr->backend);
261b843c749SSergey Zigachev 	PPTable_t *table = &(data->smc_state_table.pp_table);
262b843c749SSergey Zigachev 
263b843c749SSergey Zigachev 	ret = smum_send_msg_to_smc_with_parameter(hwmgr,
264b843c749SSergey Zigachev 				PPSMC_MSG_SetFanTemperatureTarget,
265b843c749SSergey Zigachev 				(uint32_t)table->FanTargetTemperature);
266b843c749SSergey Zigachev 
267b843c749SSergey Zigachev 	return ret;
268b843c749SSergey Zigachev }
269b843c749SSergey Zigachev 
270b843c749SSergey Zigachev /**
271b843c749SSergey Zigachev * Start the fan control on the SMC.
272b843c749SSergey Zigachev * @param    hwmgr  the address of the powerplay hardware manager.
273b843c749SSergey Zigachev * @param    pInput the pointer to input data
274b843c749SSergey Zigachev * @param    pOutput the pointer to output data
275b843c749SSergey Zigachev * @param    pStorage the pointer to temporary storage
276b843c749SSergey Zigachev * @param    Result the last failure code
277b843c749SSergey Zigachev * @return   result from set temperature range routine
278b843c749SSergey Zigachev */
279*78973132SSergey Zigachev int vega12_thermal_start_smc_fan_control(struct pp_hwmgr *hwmgr);
vega12_thermal_start_smc_fan_control(struct pp_hwmgr * hwmgr)280b843c749SSergey Zigachev int vega12_thermal_start_smc_fan_control(struct pp_hwmgr *hwmgr)
281b843c749SSergey Zigachev {
282b843c749SSergey Zigachev 	/* If the fantable setup has failed we could have disabled
283b843c749SSergey Zigachev 	 * PHM_PlatformCaps_MicrocodeFanControl even after
284b843c749SSergey Zigachev 	 * this function was included in the table.
285b843c749SSergey Zigachev 	 * Make sure that we still think controlling the fan is OK.
286b843c749SSergey Zigachev 	 */
287b843c749SSergey Zigachev 	if (PP_CAP(PHM_PlatformCaps_MicrocodeFanControl))
288b843c749SSergey Zigachev 		vega12_fan_ctrl_start_smc_fan_control(hwmgr);
289b843c749SSergey Zigachev 
290b843c749SSergey Zigachev 	return 0;
291b843c749SSergey Zigachev }
292b843c749SSergey Zigachev 
293b843c749SSergey Zigachev 
vega12_start_thermal_controller(struct pp_hwmgr * hwmgr,struct PP_TemperatureRange * range)294b843c749SSergey Zigachev int vega12_start_thermal_controller(struct pp_hwmgr *hwmgr,
295b843c749SSergey Zigachev 				struct PP_TemperatureRange *range)
296b843c749SSergey Zigachev {
297b843c749SSergey Zigachev 	int ret = 0;
298b843c749SSergey Zigachev 
299b843c749SSergey Zigachev 	if (range == NULL)
300b843c749SSergey Zigachev 		return -EINVAL;
301b843c749SSergey Zigachev 
302b843c749SSergey Zigachev 	ret = vega12_thermal_set_temperature_range(hwmgr, range);
303b843c749SSergey Zigachev 	if (ret)
304b843c749SSergey Zigachev 		return -EINVAL;
305b843c749SSergey Zigachev 
306b843c749SSergey Zigachev 	vega12_thermal_enable_alert(hwmgr);
307b843c749SSergey Zigachev 	/* We should restrict performance levels to low before we halt the SMC.
308b843c749SSergey Zigachev 	 * On the other hand we are still in boot state when we do this
309b843c749SSergey Zigachev 	 * so it would be pointless.
310b843c749SSergey Zigachev 	 * If this assumption changes we have to revisit this table.
311b843c749SSergey Zigachev 	 */
312b843c749SSergey Zigachev 	ret = vega12_thermal_setup_fan_table(hwmgr);
313b843c749SSergey Zigachev 	if (ret)
314b843c749SSergey Zigachev 		return -EINVAL;
315b843c749SSergey Zigachev 
316b843c749SSergey Zigachev 	vega12_thermal_start_smc_fan_control(hwmgr);
317b843c749SSergey Zigachev 
318b843c749SSergey Zigachev 	return 0;
319b843c749SSergey Zigachev };
320