[Intel-xe] [RFC v2 0/2] drm/xe/pvc: Enable fixed CCS mode

Summers, Stuart stuart.summers at intel.com
Fri Nov 3 15:38:56 UTC 2023


On Thu, 2023-11-02 at 22:09 -0700, Niranjana Vishwanathapura wrote:
> On Thu, Nov 02, 2023 at 11:41:34AM -0700, Summers, Stuart wrote:
> > On Wed, 2023-11-01 at 16:57 -0700, Niranjana Vishwanathapura wrote:
> > > Allow static assignment of compute slices to a user selected
> > > number of compute engines. Add a per-tile 'ccs_mode' sysfs
> > > interface for user selection. By default assign all compute
> > > resources to the first available compute engine. User must
> > > ensure the tile is idle while changing the ccs mode as this
> > > causes a tile reset. User must also ensure that there are no
> > 
> > How will the user know that the device is idle when the KMD/GuC are
> > responsible for submission management between processes? This is
> > the
> > reason we went through the context creation interface in i915
> > rather
> > than having a user-specific interface like sysfs or ioctl.
> > 
> 
> I think UMD handling it is the simpler approach without complicating
> things in KMD. As writing to sysfs needs admin access, and admin
> will have some control over whats running. The patch #2 handles this
> case by returning -EBUSY if user tries to change ccs_mode if any
> exec_queue is open (as they are are associated with engines).
> There is also a suggestion to only allow ccs_mode change only
> when there are no drm clients, may be that is an overkill, but
> I guess more simpler the better as ccs_mode is not exected to change

This is not true. This is tuned per workload. Of course if a workload
is running and another starts up, that second workload will need to use
whatever that first one was using. But if we have one workload run,
then another sequentially, both workloads can and will use different
modes to get the best performance. This is also the reason I don't
think we can just leave this to the sysadmin since this affects
individual workload performance.

-Stuart

> that often.
> 
> Niranjana
> 
> > Thanks,
> > Stuart
> > 
> > > open exec queues while changing the ccs mode. Also, error will
> > > be returned for exec queue creation with disabled ccs engines.
> > > 
> > > Support this mode for PVC which can be extended to other
> > > platforms in future.
> > > 
> > > IGT: https://patchwork.freedesktop.org/series/125873/
> > > 
> > > v2: Fixed issue with HW config, ensure no exec queue is created
> > >     with disabled CCS engines.
> > > 
> > > Signed-off-by: Niranjana Vishwanathapura
> > > <niranjana.vishwanathapura at intel.com>
> > > 
> > > Niranjana Vishwanathapura (2):
> > >   drm/xe: Enable Fixed CCS mode setting
> > >   drm/xe: Prevent exec_queues creation on diabled CCS engines
> > > 
> > >  drivers/gpu/drm/xe/Makefile          |  1 +
> > >  drivers/gpu/drm/xe/regs/xe_gt_regs.h | 14 +++++
> > >  drivers/gpu/drm/xe/xe_device.c       |  1 +
> > >  drivers/gpu/drm/xe/xe_device_types.h |  9 ++++
> > >  drivers/gpu/drm/xe/xe_exec_queue.c   | 45 +++++++++++++++-
> > >  drivers/gpu/drm/xe/xe_gt.c           | 27 ++++++++--
> > >  drivers/gpu/drm/xe/xe_gt.h           |  2 +
> > >  drivers/gpu/drm/xe/xe_gt_ccs_mode.c  | 79
> > > ++++++++++++++++++++++++++++
> > >  drivers/gpu/drm/xe/xe_gt_ccs_mode.h  | 22 ++++++++
> > >  drivers/gpu/drm/xe/xe_gt_types.h     | 16 ++++++
> > >  drivers/gpu/drm/xe/xe_guc_ads.c      |  3 ++
> > >  drivers/gpu/drm/xe/xe_hw_engine.c    | 14 +++++
> > >  drivers/gpu/drm/xe/xe_tile_sysfs.c   | 62 ++++++++++++++++++++++
> > >  13 files changed, 288 insertions(+), 7 deletions(-)
> > >  create mode 100644 drivers/gpu/drm/xe/xe_gt_ccs_mode.c
> > >  create mode 100644 drivers/gpu/drm/xe/xe_gt_ccs_mode.h
> > > 
> > 



More information about the Intel-xe mailing list