drm/amdgpu: Rework amdgpu_device_lock_adev
authorAndrey Grodzovsky <andrey.grodzovsky@amd.com>
Tue, 25 Jan 2022 16:32:47 +0000 (11:32 -0500)
committerAndrey Grodzovsky <andrey.grodzovsky@amd.com>
Wed, 9 Feb 2022 17:18:39 +0000 (12:18 -0500)
commite923be9934a9c54a94e443f9e77bda5b9fbd1ce5
tree575b0a1d0a6467d1771c5994092fef714b28515f
parent89a7a87093d67e2c633e1ed400ba00ffd15bdae5
drm/amdgpu: Rework amdgpu_device_lock_adev

This functions needs to be split into 2 parts where
one is called only once for locking single instance of
reset_domain's sem and reset flag and the other part
which handles MP1 states should still be called for
each device in XGMI hive.

Signed-off-by: Andrey Grodzovsky <andrey.grodzovsky@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Link: https://www.spinics.net/lists/amd-gfx/msg74118.html
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
drivers/gpu/drm/amd/amdgpu/amdgpu_reset.c
drivers/gpu/drm/amd/amdgpu/amdgpu_reset.h