drm/amdgpu/virt: skip VM fault handler for VF (v2)
Subsystems (2)
PATCH 1/1 drm/amdgpu/virt: skip VM fault handler for VF (v2)
VF uses KIQ to access registers. When VM fault occurs, the driver can't get back the fence of KIQ submission and runs into CPU soft lockup.
v2: print IV entry info
--- drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c | 7 +++++++ 1 file changed, 7 insertions(+)
drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c +7 -0
@@ -1237,6 +1237,13 @@ static int gmc_v8_0_process_interrupt(struct amdgpu_device *adev, {u32 addr, status, mc_client; +if (amdgpu_sriov_vf (adev)) { +dev_err (adev->dev,"GPU fault detected: %d 0x%08x\n" , + entry->src_id, entry->src_data); +dev_err (adev->dev," Can't decode VM fault info here on SRIOV VF\n" ); +return 0 ; + } + addr =RREG32 (mmVM_CONTEXT1_PROTECTION_FAULT_ADDR); status =RREG32 (mmVM_CONTEXT1_PROTECTION_FAULT_STATUS); mc_client =RREG32 (mmVM_CONTEXT1_PROTECTION_FAULT_MCCLIENT);
Signature · 6 lines
2.7.4 _______________________________________________ amd-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/amd-gfx
A message that is not in the archive (sent off-list or not yet received): 1486447619-22549-1-git-send-email-Pixel.Ding-5C7GfCeVMHo@public.gmane.org
Zhang, Jerry
Reviewed-by Junwei ZhangIf that info is enough for vf.
Regards,
Jerry (Junwei Zhang)
Linux Base Graphics
SRDC Software Development
_____________________________________
Quoted 36 lines
-----Original Message-----
From: Pixel Ding [mailto:[email protected]]
Sent: Tuesday, February 07, 2017 14:07
To: Zhou, David(ChunMing); Koenig, Christian; Zhang, Jerry
Cc: [email protected]; Ding, Pixel
Subject: [PATCH] drm/amdgpu/virt: skip VM fault handler for VF (v2)VF uses KIQ to access registers. When VM fault occurs, the driver can't get back the fence of KIQ submission and runs into CPU soft lockup.
v2: print IV entry info
Signed-off-by Pixel Ding <[email protected]>--- drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c | 7 +++++++ 1 file changed, 7 insertions(+)drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c +7
-0@@ -1237,6 +1237,13 @@ static int gmc_v8_0_process_interrupt(struct amdgpu_device *adev, {u32 addr, status, mc_client; +if (amdgpu_sriov_vf (adev)) { +dev_err (adev->dev,"GPU fault detected: %d 0x%08x\n" , + entry->src_id, entry->src_data); +dev_err (adev->dev," Can't decode VM fault info here on SRIOV VF\n"); +return 0 ; + } + addr =RREG32 (mmVM_CONTEXT1_PROTECTION_FAULT_ADDR); status =RREG32 (mmVM_CONTEXT1_PROTECTION_FAULT_STATUS);
Quoted 4 lines
mc_client=RREG32(mmVM_CONTEXT1_PROTECTION_FAULT_MCCLIENT);
--
2.7.4
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
A message that is not in the archive (sent off-list or not yet received): DM5PR12MB18183F0066F10FD5AF0041DFFF430-2J9CzHegvk+QhrfEZJlvtAdYzm3356FpvxpqHgZTriW3zl9H0oFU5g@public.gmane.org
Thank you, Jerry. You can find more detailed discussion in previous thread. —
Sincerely Yours,
Pixel
Quoted 37 lines · Jerry
If that info is enough for vf.
Reviewed-by Junwei Zhang <[email protected]>Regards,
Jerry (Junwei Zhang)Linux Base Graphics
SRDC Software Development
_____________________________________Quoted 26 lines
-----Original Message-----
From: Pixel Ding [mailto:[email protected]]
Sent: Tuesday, February 07, 2017 14:07
To: Zhou, David(ChunMing); Koenig, Christian; Zhang, Jerry
Cc: [email protected]; Ding, Pixel
Subject: [PATCH] drm/amdgpu/virt: skip VM fault handler for VF (v2)VF uses KIQ to access registers. When VM fault occurs, the driver can't get back the fence of KIQ submission and runs into CPU soft lockup.
v2: print IV entry info
Signed-off-by Pixel Ding <[email protected]>--- drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c | 7 +++++++ 1 file changed, 7 insertions(+)drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c +0
-0@@ -1237,6 +1237,13 @@ static int gmc_v8_0_process_interrupt(struct amdgpu_device *adev, {u32 addr, status, mc_client;
Quoted 15 lines
Quoted 10 lines
drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c +7
-0+if (amdgpu_sriov_vf (adev)) { +dev_err (adev->dev,"GPU fault detected: %d 0x%08x\n" , + entry->src_id, entry->src_data); +dev_err (adev->dev," Can't decode VM fault info here on SRIOV VF\n"); +return 0 ; + } + addr =RREG32 (mmVM_CONTEXT1_PROTECTION_FAULT_ADDR); status =RREG32 (mmVM_CONTEXT1_PROTECTION_FAULT_STATUS);Quoted 4 lines
mc_client=RREG32(mmVM_CONTEXT1_PROTECTION_FAULT_MCCLIENT);
--
2.7.4
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Yeah, the src_data is unfortunately not completed (you simply can't have all the bits of a 40bit address+flags in a 32bit dw).
But it's the best we can do, so the patch is Reviewed-by: Christian König <[email protected]> as well.
Regards,
Christian.
Am 07.02.2017 um 08:03 schrieb Zhang, Jerry:
Quoted 47 lines
If that info is enough for vf.
Reviewed-by Junwei Zhang <[email protected]>Regards,
Jerry (Junwei Zhang)Linux Base Graphics
SRDC Software Development
_____________________________________Quoted 36 lines
-----Original Message-----
From: Pixel Ding [mailto:[email protected]]
Sent: Tuesday, February 07, 2017 14:07
To: Zhou, David(ChunMing); Koenig, Christian; Zhang, Jerry
Cc: [email protected]; Ding, Pixel
Subject: [PATCH] drm/amdgpu/virt: skip VM fault handler for VF (v2)VF uses KIQ to access registers. When VM fault occurs, the driver can't get back the fence of KIQ submission and runs into CPU soft lockup.
v2: print IV entry info
Signed-off-by Pixel Ding <[email protected]>--- drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c | 7 +++++++ 1 file changed, 7 insertions(+)drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c +7
-0@@ -1237,6 +1237,13 @@ static int gmc_v8_0_process_interrupt(struct amdgpu_device *adev, {u32 addr, status, mc_client; +if (amdgpu_sriov_vf (adev)) { +dev_err (adev->dev,"GPU fault detected: %d 0x%08x\n" , + entry->src_id, entry->src_data); +dev_err (adev->dev," Can't decode VM fault info here on SRIOV VF\n"); +return 0 ; + } + addr =RREG32 (mmVM_CONTEXT1_PROTECTION_FAULT_ADDR); status =RREG32 (mmVM_CONTEXT1_PROTECTION_FAULT_STATUS);
Quoted 8 lines
Quoted 4 lines
mc_client=RREG32(mmVM_CONTEXT1_PROTECTION_FAULT_MCCLIENT);
--
2.7.4_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx