Skip to content

Commit

Permalink
drm/xe: Add GuC state asserts to deregister_exec_queue
Browse files Browse the repository at this point in the history
Will help catch bugs in GuC state machine.

Signed-off-by: Matthew Brost <matthew.brost@intel.com>
Reviewed-by: Jonathan Cavitt <jonathan.cavitt@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20240611144053.2805091-9-matthew.brost@intel.com
  • Loading branch information
Matthew Brost committed Jun 13, 2024
1 parent 7f4f492 commit 716ce58
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions drivers/gpu/drm/xe/xe_guc_submit.c
Original file line number Diff line number Diff line change
Expand Up @@ -1587,6 +1587,11 @@ static void deregister_exec_queue(struct xe_guc *guc, struct xe_exec_queue *q)
q->guc->id,
};

xe_gt_assert(guc_to_gt(guc), exec_queue_destroyed(q));
xe_gt_assert(guc_to_gt(guc), exec_queue_registered(q));
xe_gt_assert(guc_to_gt(guc), !exec_queue_pending_disable(q));
xe_gt_assert(guc_to_gt(guc), !exec_queue_pending_enable(q));

trace_xe_exec_queue_deregister(q);

xe_guc_ct_send_g2h_handler(&guc->ct, action, ARRAY_SIZE(action));
Expand Down

0 comments on commit 716ce58

Please sign in to comment.