Intel-XE Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] drm/xe/gsc: Check for possible err in forcewake GT
@ 2024-03-12 14:24 Tejas Upadhyay
  2024-03-12 15:01 ` ✓ CI.Patch_applied: success for " Patchwork
                   ` (7 more replies)
  0 siblings, 8 replies; 9+ messages in thread
From: Tejas Upadhyay @ 2024-03-12 14:24 UTC (permalink / raw)
  To: intel-xe; +Cc: Daniele Ceraolo Spurio, Tejas Upadhyay

GT Forcewake can fail, check for success before
moving forward

Signed-off-by: Tejas Upadhyay <tejas.upadhyay@intel.com>
---
 drivers/gpu/drm/xe/xe_gsc.c | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/xe/xe_gsc.c b/drivers/gpu/drm/xe/xe_gsc.c
index d9aa815a5bc2..a5ee1b39f4a7 100644
--- a/drivers/gpu/drm/xe/xe_gsc.c
+++ b/drivers/gpu/drm/xe/xe_gsc.c
@@ -287,7 +287,11 @@ static void gsc_work(struct work_struct *work)
 	spin_unlock_irq(&gsc->lock);
 
 	xe_pm_runtime_get(xe);
-	xe_force_wake_get(gt_to_fw(gt), XE_FW_GSC);
+	ret = xe_force_wake_get(gt_to_fw(gt), XE_FW_GSC);
+	if (ret) {
+		xe_pm_runtime_put(xe);
+		return;
+	}
 
 	if (actions & GSC_ACTION_FW_LOAD) {
 		ret = gsc_upload_and_init(gsc);
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2024-03-12 16:05 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-03-12 14:24 [PATCH] drm/xe/gsc: Check for possible err in forcewake GT Tejas Upadhyay
2024-03-12 15:01 ` ✓ CI.Patch_applied: success for " Patchwork
2024-03-12 15:01 ` ✓ CI.checkpatch: " Patchwork
2024-03-12 15:02 ` ✓ CI.KUnit: " Patchwork
2024-03-12 15:12 ` ✓ CI.Build: " Patchwork
2024-03-12 15:15 ` ✓ CI.Hooks: " Patchwork
2024-03-12 15:16 ` ✓ CI.checksparse: " Patchwork
2024-03-12 15:36 ` ✓ CI.BAT: " Patchwork
2024-03-12 16:04 ` [PATCH] " Daniele Ceraolo Spurio

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox