[PATCH 2/2] drm/i915/gt: Set default CCS mode '1'

Andi Shyti andi.shyti at linux.intel.com
Tue Feb 20 11:21:51 UTC 2024


On Tue, Feb 20, 2024 at 11:15:05AM +0000, Tvrtko Ursulin wrote:
> On 20/02/2024 10:11, Andi Shyti wrote:
> > On Mon, Feb 19, 2024 at 12:51:44PM +0000, Tvrtko Ursulin wrote:
> > > On 19/02/2024 11:16, Tvrtko Ursulin wrote:
> > > > On 15/02/2024 13:59, Andi Shyti wrote:
> > 
> > ...
> > 
> > > > > +/*
> > > > > + * Exclude unavailable engines.
> > > > > + *
> > > > > + * Only the first CCS engine is utilized due to the disabling of
> > > > > CCS auto load
> > > > > + * balancing. As a result, all CCS engines operate collectively,
> > > > > functioning
> > > > > + * essentially as a single CCS engine, hence the count of active
> > > > > CCS engines is
> > > > > + * considered '1'.
> > > > > + * Currently, this applies to platforms with more than one CCS engine,
> > > > > + * specifically DG2.
> > > > > + */
> > > > > +#define for_each_available_uabi_engine(engine__, i915__) \
> > > > > +    for_each_uabi_engine(engine__, i915__) \
> > > > > +        if ((IS_DG2(i915__)) && \
> > > > > +            ((engine__)->uabi_class == I915_ENGINE_CLASS_COMPUTE) && \
> > > > > +            ((engine__)->uabi_instance)) { } \
> > > > > +        else
> > > > > +
> > > > 
> > > > If you don't want userspace to see some engines, just don't add them to
> > > > the uabi list in intel_engines_driver_register or thereabouts?
> > 
> > It will be dynamic. In next series I am preparing the user will
> > be able to increase the number of CCS engines he wants to use.
> 
> Oh tricky and new. Does it need to be at runtime or could be boot time?

At boot time the CCS mode has to be set to '1', i.e. only one CCS
will be visible to the user. Then, during the normal execution of
the driver, the user can decide to change the mode and therefore
we would need to expose more than one CCS engine.

> If you are aiming to make the static single CCS only into the 6.9 release,
> and you feel running out of time, you could always do a simple solution for
> now. The one I mentioned of simply not registering on the uabi list. Then
> you can refine more leisurely for the next release.

Thanks. I started working on a dynamic rebuilt of the
uabi_engines, but in this series it wouldn't fit.

I will add the limitation during the list creation.

Thanks a lot,
Andi


More information about the Intel-gfx mailing list