drm/amd/pm: only poweron/off vcn/jpeg when they are valid.
authorYifan Zhang <yifan1.zhang@amd.com>
Thu, 31 Aug 2023 03:17:35 +0000 (11:17 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 6 Sep 2023 18:31:44 +0000 (14:31 -0400)
commit2e3b2cb9b8e00e1ed5e51b93946d78b21f48e3ea
treee47e6db91c537b396e3367f2c9d7bf14fe368d43
parent813ba1ff8484e801d2ef155e0e5388b8a7691788
drm/amd/pm: only poweron/off vcn/jpeg when they are valid.

If vcn is disabled in kernel parameters, don't touch vcn,
otherwise it may cause vcn hang.

v2: delete unnecessary logs
v3: move "is_vcn_enabled" check to smu_dpm_setvcn/jpeg_enable (Evan)

Signed-off-by: Yifan Zhang <yifan1.zhang@amd.com>
Reviewed-by: Evan Quan <evan.quan@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c