]> www.infradead.org Git - users/jedix/linux-maple.git/commit
drm/i915/gt/uc: Evaluate GuC priority within locks
authorAndi Shyti <andi.shyti@linux.intel.com>
Thu, 13 Jun 2024 22:24:02 +0000 (00:24 +0200)
committerAndi Shyti <andi.shyti@linux.intel.com>
Sat, 15 Jun 2024 11:58:18 +0000 (13:58 +0200)
commitae45f07cade1a5853ff6fd745bbd86a64cc82643
treec527274de3faf3a667e0e6f53e2b8b6cde6366e3
parent45ebbbbeaa33da4a6dbc532ebc57d20de4b60a82
drm/i915/gt/uc: Evaluate GuC priority within locks

The ce->guc_state.lock was made to protect guc_prio, which
indicates the GuC priority level.

But at the begnning of the function we perform some sanity check
of guc_prio outside its protected section. Move them within the
locked region.

Use this occasion to expand the if statement to make it clearer.

Signed-off-by: Andi Shyti <andi.shyti@linux.intel.com>
Cc: Matthew Brost <matthew.brost@intel.com>
Reviewed-by: Matthew Brost <matthew.brost@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20240613222402.551625-2-andi.shyti@linux.intel.com
drivers/gpu/drm/i915/gt/uc/intel_guc_submission.c