diff options
author | Tao Zhou <tao.zhou1@amd.com> | 2019-09-18 09:26:23 +0200 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2019-10-03 16:11:02 +0200 |
commit | 0771b0bf0790295b141cc30644a1b0b3e22a331e (patch) | |
tree | dd0ad0b4f8b67f881465436b5af929e6d8951442 /drivers | |
parent | drm/amdgpu: remove ih_info parameter of gfx_ras_late_init (diff) | |
download | linux-0771b0bf0790295b141cc30644a1b0b3e22a331e.tar.xz linux-0771b0bf0790295b141cc30644a1b0b3e22a331e.zip |
drm/amdgpu: simplify the access to eeprom_control struct
simplify the code of accessing to eeprom_control struct
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>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c index 00cd01c61668..486568ded6d6 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c @@ -1386,7 +1386,7 @@ static int amdgpu_ras_save_bad_pages(struct amdgpu_device *adev) save_count = data->count - control->num_recs; /* only new entries are saved */ if (save_count > 0) - if (amdgpu_ras_eeprom_process_recods(&con->eeprom_control, + if (amdgpu_ras_eeprom_process_recods(control, &data->bps[control->num_recs], true, save_count)) { @@ -1524,11 +1524,11 @@ int amdgpu_ras_recovery_init(struct amdgpu_device *adev) atomic_set(&con->in_recovery, 0); con->adev = adev; - ret = amdgpu_ras_eeprom_init(&adev->psp.ras.ras->eeprom_control); + ret = amdgpu_ras_eeprom_init(&con->eeprom_control); if (ret) goto free; - if (adev->psp.ras.ras->eeprom_control.num_recs) { + if (con->eeprom_control.num_recs) { ret = amdgpu_ras_load_bad_pages(adev); if (ret) goto free; |