[AMD Official Use Only - General] Reviewed-by: Mohammad Zafar Ziya <Mohammadzafar.ziya@xxxxxxx> >-----Original Message----- >From: amd-gfx <amd-gfx-bounces@xxxxxxxxxxxxxxxxxxxxx> On Behalf Of Tao >Zhou >Sent: Tuesday, May 10, 2022 12:00 PM >To: amd-gfx@xxxxxxxxxxxxxxxxxxxxx; Ziya, Mohammad zafar ><Mohammadzafar.Ziya@xxxxxxx>; Lazar, Lijo <Lijo.Lazar@xxxxxxx>; >Zhang, Hawking <Hawking.Zhang@xxxxxxx>; Yang, Stanley ><Stanley.Yang@xxxxxxx>; Chai, Thomas <YiPeng.Chai@xxxxxxx> >Cc: Zhou1, Tao <Tao.Zhou1@xxxxxxx> >Subject: [PATCH 1/2] drm/amdgpu: enable RAS IH for poison consumption > >Enable RAS IH if poison consumption handler is implemented. > >Signed-off-by: Tao Zhou <tao.zhou1@xxxxxxx> >--- > drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c | 4 +++- > 1 file changed, 3 insertions(+), 1 deletion(-) > >diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c >b/drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c >index cac56f830aed..91d9e9969b4e 100644 >--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c >+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c >@@ -2516,7 +2516,9 @@ int amdgpu_ras_block_late_init(struct >amdgpu_device *adev, > return 0; > > ras_obj = container_of(ras_block, struct amdgpu_ras_block_object, >ras_comm); >- if (ras_obj->ras_cb) { >+ if (ras_obj->ras_cb || (ras_obj->hw_ops && >+ (ras_obj->hw_ops->query_poison_status || >+ ras_obj->hw_ops->handle_poison_consumption))) { > r = amdgpu_ras_interrupt_add_handler(adev, ras_block); > if (r) > goto cleanup; >-- >2.35.1