drm/amdgpu/vcn2.0: add cancel_delayed_work_sync before power gate
authorJames Zhu <James.Zhu@amd.com>
Wed, 19 May 2021 15:26:32 +0000 (11:26 -0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 3 Jun 2021 07:00:31 +0000 (09:00 +0200)
commitefd47c9d586d5a1e5818fc263b06188e49b5dc9f
treed47d244376c92c6a8b569faa067fa27870851b52
parent01abf69154d0dd3d92b375b3a4db230844ba7c74
drm/amdgpu/vcn2.0: add cancel_delayed_work_sync before power gate

commit 0c6013377b4027e69d8f3e63b6bf556b6cb87802 upstream.

Add cancel_delayed_work_sync before set power gating state
to avoid race condition issue when power gating.

Signed-off-by: James Zhu <James.Zhu@amd.com>
Reviewed-by: Leo Liu <leo.liu@amd.com>
Acked-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Cc: stable@vger.kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/gpu/drm/amd/amdgpu/vcn_v2_0.c