summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/xe/xe_sched_job.c
diff options
context:
space:
mode:
authorFrancois Dugast <francois.dugast@intel.com>2023-07-27 17:55:29 +0300
committerRodrigo Vivi <rodrigo.vivi@intel.com>2023-12-21 19:39:17 +0300
commit99fea6828879381405dba598627aea79fa6edd78 (patch)
tree1ae501df46eb3a5274eec4f4a5006eae1ddf08b9 /drivers/gpu/drm/xe/xe_sched_job.c
parent3207a32163cdf7b3345a44e255aae614859ea0d6 (diff)
downloadlinux-99fea6828879381405dba598627aea79fa6edd78.tar.xz
drm/xe: Prefer WARN() over BUG() to avoid crashing the kernel
Replace calls to XE_BUG_ON() with calls XE_WARN_ON() which in turn calls WARN() instead of BUG(). BUG() crashes the kernel and should only be used when it is absolutely unavoidable in case of catastrophic and unrecoverable failures, which is not the case here. Signed-off-by: Francois Dugast <francois.dugast@intel.com> Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com> Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
Diffstat (limited to 'drivers/gpu/drm/xe/xe_sched_job.c')
-rw-r--r--drivers/gpu/drm/xe/xe_sched_job.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/xe/xe_sched_job.c b/drivers/gpu/drm/xe/xe_sched_job.c
index c87f65c98b3d..85fd5980191c 100644
--- a/drivers/gpu/drm/xe/xe_sched_job.c
+++ b/drivers/gpu/drm/xe/xe_sched_job.c
@@ -142,7 +142,7 @@ struct xe_sched_job *xe_sched_job_create(struct xe_engine *e,
/* Sanity check */
for (j = 0; j < e->width; ++j)
- XE_BUG_ON(cf->base.seqno != fences[j]->seqno);
+ XE_WARN_ON(cf->base.seqno != fences[j]->seqno);
job->fence = &cf->base;
}