summaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorRex Zhu <Rex.Zhu@amd.com>2016-06-17 18:21:01 +0800
committerAlex Deucher <alexander.deucher@amd.com>2016-06-21 10:22:29 -0400
commit1d7b84d12af8312b52316029f1fa0fa4eac3c9e4 (patch)
treeadb18b3842d9c9e82cfa06c4462aacd010c35654 /drivers
parent29b9c528b8c295911e8b1e515273e89a2b7fa2d8 (diff)
downloadlinux-stable-1d7b84d12af8312b52316029f1fa0fa4eac3c9e4.tar.gz
linux-stable-1d7b84d12af8312b52316029f1fa0fa4eac3c9e4.tar.bz2
linux-stable-1d7b84d12af8312b52316029f1fa0fa4eac3c9e4.zip
drm/amd/powerplay: fix logic error.
the error lead powerplay can't get display info in DGPU case. store_cc6_data just implement in APU. Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Cc: stable@vger.kernel.org
Diffstat (limited to 'drivers')
-rw-r--r--drivers/gpu/drm/amd/powerplay/hwmgr/hardwaremanager.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/drivers/gpu/drm/amd/powerplay/hwmgr/hardwaremanager.c b/drivers/gpu/drm/amd/powerplay/hwmgr/hardwaremanager.c
index fa208ada6892..efb77eda7508 100644
--- a/drivers/gpu/drm/amd/powerplay/hwmgr/hardwaremanager.c
+++ b/drivers/gpu/drm/amd/powerplay/hwmgr/hardwaremanager.c
@@ -306,10 +306,14 @@ int phm_store_dal_configuration_data(struct pp_hwmgr *hwmgr,
{
PHM_FUNC_CHECK(hwmgr);
- if (hwmgr->hwmgr_func->store_cc6_data == NULL)
+ if (display_config == NULL)
return -EINVAL;
hwmgr->display_config = *display_config;
+
+ if (hwmgr->hwmgr_func->store_cc6_data == NULL)
+ return -EINVAL;
+
/* to do pass other display configuration in furture */
if (hwmgr->hwmgr_func->store_cc6_data)