diff options
author | Monk Liu <Monk.Liu@amd.com> | 2017-01-25 15:48:01 +0800 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2017-03-29 23:52:46 -0400 |
commit | 147b5983bb9b942af1f1d8d9e05d93f97cca312c (patch) | |
tree | 12c0d32e7187e3de058a9d799421b988f476cd0e /drivers/gpu/drm/amd/amdgpu/amdgpu_virt.h | |
parent | ed17c71b3a89d5ef4d8c8053a29a78fa709bb458 (diff) | |
download | blackbird-obmc-linux-147b5983bb9b942af1f1d8d9e05d93f97cca312c.tar.gz blackbird-obmc-linux-147b5983bb9b942af1f1d8d9e05d93f97cca312c.zip |
drm/amdgpu:add lock_reset for SRIOV
this lock is used for sriov_gpu_reset, only get this mutex
can run into sriov_gpu_reset.
we have couple source triggers gpu_reset for SRIOV:
1) submit timedout and trigger reset voluntarily
2) invalid instruction detected by ENGINE and trigger reset voluntarily
2) hypervisor found world switch hang and trigger flr and notify guest to
do reset.
all need take care and we need a mutex to protect the consistency of
reset routine.
Signed-off-by: Monk Liu <Monk.Liu@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_virt.h')
-rw-r--r-- | drivers/gpu/drm/amd/amdgpu/amdgpu_virt.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_virt.h b/drivers/gpu/drm/amd/amdgpu/amdgpu_virt.h index 7020ff22b9b5..4b05568bff00 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_virt.h +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_virt.h @@ -47,6 +47,7 @@ struct amdgpu_virt { bool chained_ib_support; uint32_t reg_val_offs; struct mutex lock_kiq; + struct mutex lock_reset; struct amdgpu_irq_src ack_irq; struct amdgpu_irq_src rcv_irq; struct delayed_work flr_work; |