aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/amdgpu/amdgpu_xgmi.c
diff options
context:
space:
mode:
authorAlan Liu <[email protected]>2022-10-24 06:15:30 +0000
committerAlex Deucher <[email protected]>2022-10-27 19:12:08 +0000
commit7117007edad2299f2f093cdcfa813beb646d913e (patch)
tree333ea2c96cd279ff27f86cf62694c813b6872f59 /drivers/gpu/drm/amd/amdgpu/amdgpu_xgmi.c
parentdrm/amdgpu: remove ras_error_status parameter for UMC poison handler (diff)
downloadkernel-7117007edad2299f2f093cdcfa813beb646d913e.tar.gz
kernel-7117007edad2299f2f093cdcfa813beb646d913e.zip
drm/amdgpu: Move the mutex_lock to protect the return status of securedisplay command buffer
[Why] Before we call psp_securedisplay_invoke(), we call psp_prep_securedisplay_cmd_buf() to prepare and initialize the command buffer. However, we didn't use the mutex_lock to protect the status of command buffer. So when multiple threads are using the command buffer, after thread A return from psp_securedisplay_invoke() and the command buffer status is set to SUCCESS, another thread B may call psp_prep_securedisplay_cmd_buf() and initialize the status to FAILURE again, and cause Thread A to get a failure return status. [How] Move the mutex_lock out of psp_securedisplay_invoke() to its caller to cover psp_prep_securedisplay_cmd_buf() and the code checking the return status of command buffer. Signed-off-by: Alan Liu <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_xgmi.c')
0 files changed, 0 insertions, 0 deletions