aboutsummaryrefslogtreecommitdiffstats
path: root/meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.14.71/3058-drm-amd-powerplay-remove-unused-parameter-of-phm_sta.patch
diff options
context:
space:
mode:
Diffstat (limited to 'meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.14.71/3058-drm-amd-powerplay-remove-unused-parameter-of-phm_sta.patch')
-rw-r--r--meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.14.71/3058-drm-amd-powerplay-remove-unused-parameter-of-phm_sta.patch81
1 files changed, 81 insertions, 0 deletions
diff --git a/meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.14.71/3058-drm-amd-powerplay-remove-unused-parameter-of-phm_sta.patch b/meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.14.71/3058-drm-amd-powerplay-remove-unused-parameter-of-phm_sta.patch
new file mode 100644
index 00000000..5e4a8a6b
--- /dev/null
+++ b/meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.14.71/3058-drm-amd-powerplay-remove-unused-parameter-of-phm_sta.patch
@@ -0,0 +1,81 @@
+From 1055d844b273cee0be6bd712e250e4f11dc4b1ce Mon Sep 17 00:00:00 2001
+From: Evan Quan <evan.quan@amd.com>
+Date: Thu, 28 Dec 2017 14:18:15 +0800
+Subject: [PATCH 3058/4131] drm/amd/powerplay: remove unused parameter of
+ phm_start_thermal_controller
+
+Change-Id: Id6039cb50b73bdf8a6df37e5383f4bea4ae737ed
+Signed-off-by: Evan Quan <evan.quan@amd.com>
+Acked-by: Alex Deucher <alexander.deucher@amd.com>
+---
+ drivers/gpu/drm/amd/powerplay/hwmgr/hardwaremanager.c | 14 +++-----------
+ drivers/gpu/drm/amd/powerplay/hwmgr/hwmgr.c | 4 ++--
+ drivers/gpu/drm/amd/powerplay/inc/hardwaremanager.h | 2 +-
+ 3 files changed, 6 insertions(+), 14 deletions(-)
+
+diff --git a/drivers/gpu/drm/amd/powerplay/hwmgr/hardwaremanager.c b/drivers/gpu/drm/amd/powerplay/hwmgr/hardwaremanager.c
+index 2b0c53f..297ec0d 100644
+--- a/drivers/gpu/drm/amd/powerplay/hwmgr/hardwaremanager.c
++++ b/drivers/gpu/drm/amd/powerplay/hwmgr/hardwaremanager.c
+@@ -223,20 +223,12 @@ int phm_register_thermal_interrupt(struct pp_hwmgr *hwmgr, const void *info)
+ * Initializes the thermal controller subsystem.
+ *
+ * @param pHwMgr the address of the powerplay hardware manager.
+-* @param pTemperatureRange the address of the structure holding the temperature range.
+ * @exception PP_Result_Failed if any of the paramters is NULL, otherwise the return value from the dispatcher.
+ */
+-int phm_start_thermal_controller(struct pp_hwmgr *hwmgr, struct PP_TemperatureRange *temperature_range)
++int phm_start_thermal_controller(struct pp_hwmgr *hwmgr)
+ {
+- struct PP_TemperatureRange range;
+-
+- if (temperature_range == NULL) {
+- range.max = TEMP_RANGE_MAX;
+- range.min = TEMP_RANGE_MIN;
+- } else {
+- range.max = temperature_range->max;
+- range.min = temperature_range->min;
+- }
++ struct PP_TemperatureRange range = {{TEMP_RANGE_MIN, TEMP_RANGE_MAX}};
++
+ if (phm_cap_enabled(hwmgr->platform_descriptor.platformCaps,
+ PHM_PlatformCaps_ThermalController)
+ && hwmgr->hwmgr_func->start_thermal_controller != NULL)
+diff --git a/drivers/gpu/drm/amd/powerplay/hwmgr/hwmgr.c b/drivers/gpu/drm/amd/powerplay/hwmgr/hwmgr.c
+index 0229f77..ec3cdf5 100644
+--- a/drivers/gpu/drm/amd/powerplay/hwmgr/hwmgr.c
++++ b/drivers/gpu/drm/amd/powerplay/hwmgr/hwmgr.c
+@@ -261,7 +261,7 @@ int hwmgr_hw_init(struct pp_instance *handle)
+ ret = phm_enable_dynamic_state_management(hwmgr);
+ if (ret)
+ goto err2;
+- ret = phm_start_thermal_controller(hwmgr, NULL);
++ ret = phm_start_thermal_controller(hwmgr);
+ ret |= psm_set_performance_states(hwmgr);
+ if (ret)
+ goto err2;
+@@ -341,7 +341,7 @@ int hwmgr_hw_resume(struct pp_instance *handle)
+ ret = phm_enable_dynamic_state_management(hwmgr);
+ if (ret)
+ return ret;
+- ret = phm_start_thermal_controller(hwmgr, NULL);
++ ret = phm_start_thermal_controller(hwmgr);
+ if (ret)
+ return ret;
+
+diff --git a/drivers/gpu/drm/amd/powerplay/inc/hardwaremanager.h b/drivers/gpu/drm/amd/powerplay/inc/hardwaremanager.h
+index 5716b93..f919301 100644
+--- a/drivers/gpu/drm/amd/powerplay/inc/hardwaremanager.h
++++ b/drivers/gpu/drm/amd/powerplay/inc/hardwaremanager.h
+@@ -393,7 +393,7 @@ extern int phm_force_dpm_levels(struct pp_hwmgr *hwmgr, enum amd_dpm_forced_leve
+ extern int phm_display_configuration_changed(struct pp_hwmgr *hwmgr);
+ extern int phm_notify_smc_display_config_after_ps_adjustment(struct pp_hwmgr *hwmgr);
+ extern int phm_register_thermal_interrupt(struct pp_hwmgr *hwmgr, const void *info);
+-extern int phm_start_thermal_controller(struct pp_hwmgr *hwmgr, struct PP_TemperatureRange *temperature_range);
++extern int phm_start_thermal_controller(struct pp_hwmgr *hwmgr);
+ extern int phm_stop_thermal_controller(struct pp_hwmgr *hwmgr);
+ extern bool phm_check_smc_update_required_for_display_configuration(struct pp_hwmgr *hwmgr);
+
+--
+2.7.4
+