diff options
author | Andrey Grodzovsky <andrey.grodzovsky@amd.com> | 2017-12-13 14:36:53 -0500 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2017-12-15 17:15:00 -0500 |
commit | 8854695add1eaaeafae728850c905c4727e56f35 (patch) | |
tree | bfb113240282734d3401b1ed2cb4c34e2e10c085 /drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | |
parent | dcebf026e6f69fb79e7f88d10681faf4f8a985ba (diff) |
drm/amdgpu: Simplify amdgpu_lockup_timeout usage.
With introduction of amdgpu_gpu_recovery we don't need any more
to rely on amdgpu_lockup_timeout == 0 for disabling GPU reset.
Signed-off-by: Andrey Grodzovsky <andrey.grodzovsky@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_device.c')
-rw-r--r-- | drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c index 3f63f5ca4fa7..79869827985f 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | |||
@@ -1229,6 +1229,11 @@ static void amdgpu_check_arguments(struct amdgpu_device *adev) | |||
1229 | amdgpu_vram_page_split); | 1229 | amdgpu_vram_page_split); |
1230 | amdgpu_vram_page_split = 1024; | 1230 | amdgpu_vram_page_split = 1024; |
1231 | } | 1231 | } |
1232 | |||
1233 | if (amdgpu_lockup_timeout == 0) { | ||
1234 | dev_warn(adev->dev, "lockup_timeout msut be > 0, adjusting to 10000\n"); | ||
1235 | amdgpu_lockup_timeout = 10000; | ||
1236 | } | ||
1232 | } | 1237 | } |
1233 | 1238 | ||
1234 | /** | 1239 | /** |
@@ -2827,7 +2832,7 @@ bool amdgpu_need_backup(struct amdgpu_device *adev) | |||
2827 | if (adev->flags & AMD_IS_APU) | 2832 | if (adev->flags & AMD_IS_APU) |
2828 | return false; | 2833 | return false; |
2829 | 2834 | ||
2830 | return amdgpu_lockup_timeout > 0 ? true : false; | 2835 | return amdgpu_gpu_recovery; |
2831 | } | 2836 | } |
2832 | 2837 | ||
2833 | static int amdgpu_recover_vram_from_shadow(struct amdgpu_device *adev, | 2838 | static int amdgpu_recover_vram_from_shadow(struct amdgpu_device *adev, |