]> git.baikalelectronics.ru Git - kernel.git/commit
drm/amd/powerplay: avoid using pm_en before it is initialized
authorTiecheng Zhou <Tiecheng.Zhou@amd.com>
Thu, 2 Apr 2020 08:49:36 +0000 (16:49 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Fri, 3 Apr 2020 21:22:44 +0000 (17:22 -0400)
commit8f583d05c13bf8d6f19420dc17d1b0f11108c517
tree46d666864379d25a9270becfe11e7d96d7cf083b
parent393d031e6b59aa174095b65b9201c47ddff5daf8
drm/amd/powerplay: avoid using pm_en before it is initialized

hwmgr->pm_en is initialized at hwmgr_hw_init.
during amdgpu_device_init, there is amdgpu_asic_reset that calls to
pp_get_asic_baco_capability, while hwmgr->pm_en has not yet been initialized.

so avoid using pm_en in pp_get_asic_baco_capability.

Reviewed-by: Emily Deng <Emily.Deng@amd.com>
Signed-off-by: Tiecheng Zhou <Tiecheng.Zhou@amd.com>
Signed-off-by: Yintian Tao <yttao@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/powerplay/amd_powerplay.c