[Intel-gfx] [PATCH] drm/i915/execlists: Use vfunc to check engine submission mode
Michal Wajdeczko
michal.wajdeczko at intel.com
Mon Oct 28 14:22:29 UTC 2019
On Mon, 28 Oct 2019 14:09:05 +0100, Chris Wilson
<chris at chris-wilson.co.uk> wrote:
> Quoting Michal Wajdeczko (2019-10-28 12:57:03)
>> diff --git a/drivers/gpu/drm/i915/gt/intel_lrc.h
>> b/drivers/gpu/drm/i915/gt/intel_lrc.h
>> index 99dc576a4e25..23dde9083349 100644
>> --- a/drivers/gpu/drm/i915/gt/intel_lrc.h
>> +++ b/drivers/gpu/drm/i915/gt/intel_lrc.h
>> @@ -145,4 +145,6 @@ struct intel_engine_cs *
>> intel_virtual_engine_get_sibling(struct intel_engine_cs *engine,
>> unsigned int sibling);
>>
>> +bool intel_engine_in_execlists_submission_mode(struct intel_engine_cs
>> *engine);
>
> Planning to use it outside?
Yes, there are few places where global USES_GUC_SUBMISSION(i915) is used,
and some of them can be replaced by in_execlists_submission_mode(e) right
away (i915_perf.c).
And for others we can use same approach and provide twin in_guc_mode(e) and
then use it as a base for improved uses_guc_submission(i915) if still
needed.
All above will help us review current usages of USES_GUC_SUBMISSION macro
as it looks it's meaning is no longer immutable as it used to be.
> Should we have a dedicated flag for the
> submission mode?
Potential problem with dedicated flag is that someone needs to maintain it.
Use of set_default_submission vfunc, assuming it is different for different
submission mode (and this is true today), gives us at least some confidence
that we report correct submission mode as taken directly from engine setup.
Michal
More information about the Intel-gfx
mailing list