From: jsg Date: Thu, 12 Sep 2024 23:39:51 +0000 (+0000) Subject: drm/amdgpu: Set no_hw_access when VF request full GPU fails X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=e9b266a0d797ad5239c6b06d300df1acd89edd40;p=openbsd drm/amdgpu: Set no_hw_access when VF request full GPU fails From Yifan Zha 077c7e5fee4b4b3fea29fd3a951a6b01f2802d9e in linux-6.6.y/6.6.51 33f23fc3155b13c4a96d94a0a22dc26db767440b in mainline linux --- diff --git a/sys/dev/pci/drm/amd/amdgpu/amdgpu_virt.c b/sys/dev/pci/drm/amd/amdgpu/amdgpu_virt.c index 6852de86b43..f5292c6cbd6 100644 --- a/sys/dev/pci/drm/amd/amdgpu/amdgpu_virt.c +++ b/sys/dev/pci/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; }