Patch "drm/amdgpu: Set no_hw_access when VF request full GPU fails" has been added to the 6.6-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    drm/amdgpu: Set no_hw_access when VF request full GPU fails

to the 6.6-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     drm-amdgpu-set-no_hw_access-when-vf-request-full-gpu.patch
and it can be found in the queue-6.6 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit 3695024ed8ad1176d0b9460b7cbca8e37bdef1d4
Author: Yifan Zha <Yifan.Zha@xxxxxxx>
Date:   Thu Jun 27 15:06:23 2024 +0800

    drm/amdgpu: Set no_hw_access when VF request full GPU fails
    
    [ Upstream commit 33f23fc3155b13c4a96d94a0a22dc26db767440b ]
    
    [Why]
    If VF request full GPU access and the request failed,
    the VF driver can get stuck accessing registers for an extended period during
    the unload of KMS.
    
    [How]
    Set no_hw_access flag when VF request for full GPU access fails
    This prevents further hardware access attempts, avoiding the prolonged
    stuck state.
    
    Signed-off-by: Yifan Zha <Yifan.Zha@xxxxxxx>
    Acked-by: Alex Deucher <alexander.deucher@xxxxxxx>
    Signed-off-by: Alex Deucher <alexander.deucher@xxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_virt.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_virt.c
index d9dc675b46ae..22575422ca7e 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_virt.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_virt.c
@@ -137,8 +137,10 @@ int amdgpu_virt_request_full_gpu(struct amdgpu_device *adev, bool init)
 
 	if (virt->ops && virt->ops->req_full_gpu) {
 		r = virt->ops->req_full_gpu(adev, init);
-		if (r)
+		if (r) {
+			adev->no_hw_access = true;
 			return r;
+		}
 
 		adev->virt.caps &= ~AMDGPU_SRIOV_CAPS_RUNTIME;
 	}




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux