drm/amdgpu: Add ras supported check for register_ras_block
Add ras supported check for register_ras_block. Signed-off-by: yipechai <YiPeng.Chai@amd.com> Reviewed-by: Tao Zhou <tao.zhou1@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
parent
c4381d0ee8
commit
df01fe73ee
@ -2756,6 +2756,9 @@ int amdgpu_ras_register_ras_block(struct amdgpu_device *adev,
|
||||
if (!adev || !ras_block_obj)
|
||||
return -EINVAL;
|
||||
|
||||
if (!amdgpu_ras_asic_supported(adev))
|
||||
return 0;
|
||||
|
||||
INIT_LIST_HEAD(&ras_block_obj->node);
|
||||
list_add_tail(&ras_block_obj->node, &adev->ras_list);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user