]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
drm/xe/debugfs: Add missing xe_pm_runtime_put in wedge_mode_set
authorShuicheng Lin <shuicheng.lin@intel.com>
Thu, 13 Feb 2025 23:03:22 +0000 (23:03 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 29 May 2025 09:13:23 +0000 (11:13 +0200)
[ Upstream commit b31e668d3111b100d16fd7db8db335328ce8c6d5 ]

xe_pm_runtime_put is missed in the failure path.

Cc: Rodrigo Vivi <rodrigo.vivi@intel.com>
Signed-off-by: Shuicheng Lin <shuicheng.lin@intel.com>
Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20250213230322.1180621-1-shuicheng.lin@intel.com
Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/gpu/drm/xe/xe_debugfs.c

index 6bfdd3a9913fd66ae47b876404213b3fe30fbfed..92e6fa8fe3a17c85959739b28d7ca51de0b8baf5 100644 (file)
@@ -175,6 +175,7 @@ static ssize_t wedged_mode_set(struct file *f, const char __user *ubuf,
                ret = xe_guc_ads_scheduler_policy_toggle_reset(&gt->uc.guc.ads);
                if (ret) {
                        xe_gt_err(gt, "Failed to update GuC ADS scheduler policy. GuC may still cause engine reset even with wedged_mode=2\n");
+                       xe_pm_runtime_put(xe);
                        return -EIO;
                }
        }