]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
drm/amdgpu: replace DRM_ERROR with DRM_WARN in ras_reserve_bad_pages
authorTao Zhou <tao.zhou1@amd.com>
Thu, 12 Sep 2019 10:57:23 +0000 (18:57 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Thu, 3 Oct 2019 14:10:59 +0000 (09:10 -0500)
There are two cases of reserve error should be ignored:
1) a ras bad page has been allocated (used by someone);
2) a ras bad page has been reserved (duplicate error injection for one page);

DRM_ERROR is unnecessary for the failure of bad page reserve

Signed-off-by: Tao Zhou <tao.zhou1@amd.com>
Reviewed-by: Guchun Chen <guchun.chen@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c

index 76a0c9917eeb1050a0e47aad18f14a15dc413fef..a36df02b61ea48b0f0318d6a0a76f956732544c1 100644 (file)
@@ -1411,10 +1411,15 @@ int amdgpu_ras_reserve_bad_pages(struct amdgpu_device *adev)
        for (i = data->last_reserved; i < data->count; i++) {
                bp = data->bps[i].retired_page;
 
+               /* There are two cases of reserve error should be ignored:
+                * 1) a ras bad page has been allocated (used by someone);
+                * 2) a ras bad page has been reserved (duplicate error injection
+                *    for one page);
+                */
                if (amdgpu_bo_create_kernel_at(adev, bp << PAGE_SHIFT, PAGE_SIZE,
                                               AMDGPU_GEM_DOMAIN_VRAM,
                                               &bo, NULL))
-                       DRM_ERROR("RAS ERROR: reserve vram %llx fail\n", bp);
+                       DRM_WARN("RAS WARN: reserve vram for retired page %llx fail\n", bp);
 
                data->bps_bo[i] = bo;
                data->last_reserved = i + 1;