[PATCH 1/3] Revert "drm/amdgpu: fix a mistake when removing mem_info_preempt_used sysfs"
Jesse.zhang@amd.com
jesse.zhang at amd.com
Mon Nov 18 04:31:26 UTC 2024
From: "Jesse.zhang at amd.com" <Jesse.zhang at amd.com>
This reverts commit 10aec8943bcc5123288ded8c97e78312bcf17fb1.
the dev->unplugged flag will also be set to true ,
Only uninstall the driver by amdgpu_exit, not actually unplug the device.
that will cause a new issue.
Signed-off-by: Jesse Zhang <jesse.zhang at amd.com>
---
drivers/gpu/drm/amd/amdgpu/amdgpu_preempt_mgr.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_preempt_mgr.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_preempt_mgr.c
index 9a0346ed6ea4..33a714ddfbbc 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_preempt_mgr.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_preempt_mgr.c
@@ -138,7 +138,7 @@ void amdgpu_preempt_mgr_fini(struct amdgpu_device *adev)
if (ret)
return;
- if (drm_dev_enter(adev_to_drm(adev), &idx)) {
+ if (!drm_dev_enter(adev_to_drm(adev), &idx)) {
device_remove_file(adev->dev, &dev_attr_mem_info_preempt_used);
drm_dev_exit(idx);
}
--
2.25.1
More information about the amd-gfx
mailing list