[PATCH v1] drm/xe/guc: Allow GuC CT for wedged device

Raag Jadav <[email protected]>
Newsgroups org.freedesktop.lists.intel-xe
Message-ID <[email protected]>
Commit 50fa9acac26f ("drm/xe/guc: distinguish wedged from recoverable
cancellation") introduced distinguishable error codes for g2h failure
cases, but also blocked GuC CT for wedged device. This is problematic
in cases where we want to prevent user from accessing the device but
also keep GuC CT functioning on temporarily wedged device. First user
of such requirement is PCIe FLR handling where we require uC firmware
loading while the device is temporarily wedged.

Fixes: 50fa9acac26f ("drm/xe/guc: distinguish wedged from recoverable cancellation")
Signed-off-by: Raag Jadav <[email protected]>
---
 drivers/gpu/drm/xe/xe_guc_ct.c | 8 --------
 1 file changed, 8 deletions(-)

diff --git a/drivers/gpu/drm/xe/xe_guc_ct.c b/drivers/gpu/drm/xe/xe_guc_ct.c
index 5c4733da385c..97e38147effd 100644
--- a/drivers/gpu/drm/xe/xe_guc_ct.c
+++ b/drivers/gpu/drm/xe/xe_guc_ct.c
@@ -1062,11 +1062,6 @@ static int __guc_ct_send_locked(struct xe_guc_ct *ct, const u32 *action,
 	xe_gt_assert(gt, g2h_len || !num_g2h);
 	lockdep_assert_held(&ct->lock);
 
-	if (xe_device_wedged(ct_to_xe(ct))) {
-		ret = -ENOTRECOVERABLE;
-		goto out;
-	}
-
 	if (unlikely(ct->ctbs.h2g.info.broken)) {
 		ret = -EPIPE;
 		goto out;
@@ -1813,9 +1808,6 @@ static int g2h_read(struct xe_guc_ct *ct, u32 *msg, bool fast_path)
 	xe_gt_assert(gt, xe_guc_ct_initialized(ct));
 	lockdep_assert_held(&ct->fast_lock);
 
-	if (xe_device_wedged(xe))
-		return -ENOTRECOVERABLE;
-
 	if (ct->state == XE_GUC_CT_STATE_DISABLED)
 		return -ENODEV;
 
-- 
2.43.0
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.