aboutsummaryrefslogtreecommitdiffstats
path: root/meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.19.8/4633-drm-amd-powerplay-Remove-unneeded-variable-result-in.patch
diff options
context:
space:
mode:
Diffstat (limited to 'meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.19.8/4633-drm-amd-powerplay-Remove-unneeded-variable-result-in.patch')
-rw-r--r--meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.19.8/4633-drm-amd-powerplay-Remove-unneeded-variable-result-in.patch38
1 files changed, 38 insertions, 0 deletions
diff --git a/meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.19.8/4633-drm-amd-powerplay-Remove-unneeded-variable-result-in.patch b/meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.19.8/4633-drm-amd-powerplay-Remove-unneeded-variable-result-in.patch
new file mode 100644
index 00000000..6e78bf97
--- /dev/null
+++ b/meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.19.8/4633-drm-amd-powerplay-Remove-unneeded-variable-result-in.patch
@@ -0,0 +1,38 @@
+From 1464891b5a6c0e9ea6ff2320a78285b2220b35f9 Mon Sep 17 00:00:00 2001
+From: zhengbin <zhengbin13@huawei.com>
+Date: Wed, 27 Nov 2019 17:33:38 +0800
+Subject: [PATCH 4633/4736] drm/amd/powerplay: Remove unneeded variable
+ 'result' in smu10_hwmgr.c
+
+Fixes coccicheck warning:
+
+drivers/gpu/drm/amd/powerplay/hwmgr/smu10_hwmgr.c:1154:5-11: Unneeded variable: "result". Return "0" on line 1159
+
+Reported-by: Hulk Robot <hulkci@huawei.com>
+Signed-off-by: zhengbin <zhengbin13@huawei.com>
+Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
+---
+ drivers/gpu/drm/amd/powerplay/hwmgr/smu10_hwmgr.c | 3 +--
+ 1 file changed, 1 insertion(+), 2 deletions(-)
+
+diff --git a/drivers/gpu/drm/amd/powerplay/hwmgr/smu10_hwmgr.c b/drivers/gpu/drm/amd/powerplay/hwmgr/smu10_hwmgr.c
+index 1115761982a7..4e8ab139bb3b 100644
+--- a/drivers/gpu/drm/amd/powerplay/hwmgr/smu10_hwmgr.c
++++ b/drivers/gpu/drm/amd/powerplay/hwmgr/smu10_hwmgr.c
+@@ -1151,12 +1151,11 @@ static int smu10_set_watermarks_for_clocks_ranges(struct pp_hwmgr *hwmgr,
+ struct smu10_hwmgr *data = hwmgr->backend;
+ struct dm_pp_wm_sets_with_clock_ranges_soc15 *wm_with_clock_ranges = clock_ranges;
+ Watermarks_t *table = &(data->water_marks_table);
+- int result = 0;
+
+ smu_set_watermarks_for_clocks_ranges(table,wm_with_clock_ranges);
+ smum_smc_table_manager(hwmgr, (uint8_t *)table, (uint16_t)SMU10_WMTABLE, false);
+ data->water_marks_exist = true;
+- return result;
++ return 0;
+ }
+
+ static int smu10_smus_notify_pwe(struct pp_hwmgr *hwmgr)
+--
+2.17.1
+