Intel-XE Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v7 00/10] Enable compression handling on LNL.
@ 2023-12-11 13:43 Himal Prasad Ghimiray
  2023-12-11 13:43 ` [PATCH v7 01/10] drm/xe/xe2: Determine bios enablement for flat ccs on igfx Himal Prasad Ghimiray
                   ` (16 more replies)
  0 siblings, 17 replies; 29+ messages in thread
From: Himal Prasad Ghimiray @ 2023-12-11 13:43 UTC (permalink / raw)
  To: intel-xe; +Cc: Matt Roper

xe2 igfx platform supports compression and firmware reserves 1/512th of 
system memory for ccs pool and programs the configuration registers.
The configuration register must be read during driver initialization and 
should notify via drm_dbg if compression is disabled.

The firmware allocated ccs pool is directly inaccesible to driver and can
only be read/write using XY_CTRL_SURF_COPY_BLT commands. To support ccs
metadata handling, driver allocates extra memory in bo. 

During bo creation the ccs region needs to be cleared for security.
During the eviction (buffer movement from gpu domain to system domain) 
ccs metadata is copied from flat ccs to extra memory allocated in bo and
during restore(buffer movement from system domain to gpu domain) ccs
metadata is copied from extra pages in bo to flat ccs region.

Series enables flat ccs on xe2 igfx platforms and handles clearing and
copy of ccs metadata during bo creation and xe_bo_move respectively.

Cc: Matt Roper <matthew.d.roper@intel.com>
Cc: Thomas Hellström <thomas.hellstrom@linux.intel.com>
Signed-off-by: Himal Prasad Ghimiray <himal.prasad.ghimiray@intel.com>

Himal Prasad Ghimiray (10):
  drm/xe/xe2: Determine bios enablement for flat ccs on igfx
  drm/xe/xe2: Modify main memory to ccs memory ratio.
  drm/xe/xe2: Allocate extra pages for ccs during bo create
  drm/xe/xe2: Updates on XY_CTRL_SURF_COPY_BLT
  drm/xe/xe_migrate: Use NULL 1G PTE mapped at 255GiB VA for ccs clear
  drm/xe/xe2: Update chunk size for each iteration of ccs copy
  drm/xe/xe2: Update emit_pte to use compression enabled PAT index
  drm/xe/xe2: Handle flat ccs move for igfx.
  drm/xe/xe2: Modify xe_bo_test for system memory
  drm/xe/xe2: Support flat ccs

 drivers/gpu/drm/xe/regs/xe_gpu_commands.h |   7 +-
 drivers/gpu/drm/xe/regs/xe_gt_regs.h      |   3 +
 drivers/gpu/drm/xe/tests/xe_bo.c          |  44 +++--
 drivers/gpu/drm/xe/tests/xe_migrate.c     |   6 +-
 drivers/gpu/drm/xe/xe_bo.c                |  47 +++--
 drivers/gpu/drm/xe/xe_bo_types.h          |   4 +
 drivers/gpu/drm/xe/xe_device.c            |  32 +++-
 drivers/gpu/drm/xe/xe_migrate.c           | 202 +++++++++++-----------
 drivers/gpu/drm/xe/xe_migrate.h           |   3 +-
 drivers/gpu/drm/xe/xe_pat.c               |   1 +
 drivers/gpu/drm/xe/xe_pci.c               |   2 +-
 drivers/gpu/drm/xe/xe_pt_types.h          |   1 +
 12 files changed, 205 insertions(+), 147 deletions(-)

-- 
2.25.1


^ permalink raw reply	[flat|nested] 29+ messages in thread
* [PATCH v7 00/10] *Enable compression handling on LNL.
@ 2023-12-11 13:41 Himal Prasad Ghimiray
  2023-12-11 13:41 ` [PATCH v7 10/10] drm/xe/xe2: Support flat ccs Himal Prasad Ghimiray
  0 siblings, 1 reply; 29+ messages in thread
From: Himal Prasad Ghimiray @ 2023-12-11 13:41 UTC (permalink / raw)
  To: intel-xe; +Cc: Matt Roper

xe2 igfx platform supports compression and firmware reserves 1/512th of 
system memory for ccs pool and programs the configuration registers.
The configuration register must be read during driver initialization and 
should notify via drm_dbg if compression is disabled.

The firmware allocated ccs pool is directly inaccesible to driver and can
only be read/write using XY_CTRL_SURF_COPY_BLT commands. To support ccs
metadata handling, driver allocates extra memory in bo. 

During bo creation the ccs region needs to be cleared for security.
During the eviction (buffer movement from gpu domain to system domain) 
ccs metadata is copied from flat ccs to extra memory allocated in bo and
during restore(buffer movement from system domain to gpu domain) ccs
metadata is copied from extra pages in bo to flat ccs region.

Series enables flat ccs on xe2 igfx platforms and handles clearing and
copy of ccs metadata during bo creation and xe_bo_move respectively.

Cc: Matt Roper <matthew.d.roper@intel.com>
Cc: Thomas Hellström <thomas.hellstrom@linux.intel.com>
Signed-off-by: Himal Prasad Ghimiray <himal.prasad.ghimiray@intel.com>

Himal Prasad Ghimiray (10):
  drm/xe/xe2: Determine bios enablement for flat ccs on igfx
  drm/xe/xe2: Modify main memory to ccs memory ratio.
  drm/xe/xe2: Allocate extra pages for ccs during bo create
  drm/xe/xe2: Updates on XY_CTRL_SURF_COPY_BLT
  drm/xe/xe_migrate: Use NULL 1G PTE mapped at 255GiB VA for ccs clear
  drm/xe/xe2: Update chunk size for each iteration of ccs copy
  drm/xe/xe2: Update emit_pte to use compression enabled PAT index
  drm/xe/xe2: Handle flat ccs move for igfx.
  drm/xe/xe2: Modify xe_bo_test for system memory
  drm/xe/xe2: Support flat ccs

 drivers/gpu/drm/xe/regs/xe_gpu_commands.h |   7 +-
 drivers/gpu/drm/xe/regs/xe_gt_regs.h      |   3 +
 drivers/gpu/drm/xe/tests/xe_bo.c          |  44 +++--
 drivers/gpu/drm/xe/tests/xe_migrate.c     |   6 +-
 drivers/gpu/drm/xe/xe_bo.c                |  47 +++--
 drivers/gpu/drm/xe/xe_bo_types.h          |   4 +
 drivers/gpu/drm/xe/xe_device.c            |  32 +++-
 drivers/gpu/drm/xe/xe_migrate.c           | 202 +++++++++++-----------
 drivers/gpu/drm/xe/xe_migrate.h           |   3 +-
 drivers/gpu/drm/xe/xe_pat.c               |   1 +
 drivers/gpu/drm/xe/xe_pci.c               |   2 +-
 drivers/gpu/drm/xe/xe_pt_types.h          |   1 +
 12 files changed, 205 insertions(+), 147 deletions(-)

-- 
2.25.1


^ permalink raw reply	[flat|nested] 29+ messages in thread

end of thread, other threads:[~2023-12-12 12:33 UTC | newest]

Thread overview: 29+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-12-11 13:43 [PATCH v7 00/10] Enable compression handling on LNL Himal Prasad Ghimiray
2023-12-11 13:43 ` [PATCH v7 01/10] drm/xe/xe2: Determine bios enablement for flat ccs on igfx Himal Prasad Ghimiray
2023-12-11 23:12   ` Matt Roper
2023-12-12 12:23   ` Thomas Hellström
2023-12-11 13:43 ` [PATCH v7 02/10] drm/xe/xe2: Modify main memory to ccs memory ratio Himal Prasad Ghimiray
2023-12-11 23:15   ` Matt Roper
2023-12-11 13:43 ` [PATCH v7 03/10] drm/xe/xe2: Allocate extra pages for ccs during bo create Himal Prasad Ghimiray
2023-12-12  0:41   ` Matt Roper
2023-12-12  9:00     ` Ghimiray, Himal Prasad
2023-12-11 13:43 ` [PATCH v7 04/10] drm/xe/xe2: Updates on XY_CTRL_SURF_COPY_BLT Himal Prasad Ghimiray
2023-12-12  0:45   ` Matt Roper
2023-12-11 13:43 ` [PATCH v7 05/10] drm/xe/xe_migrate: Use NULL 1G PTE mapped at 255GiB VA for ccs clear Himal Prasad Ghimiray
2023-12-11 13:43 ` [PATCH v7 06/10] drm/xe/xe2: Update chunk size for each iteration of ccs copy Himal Prasad Ghimiray
2023-12-12 12:27   ` Thomas Hellström
2023-12-11 13:43 ` [PATCH v7 07/10] drm/xe/xe2: Update emit_pte to use compression enabled PAT index Himal Prasad Ghimiray
2023-12-12 12:28   ` Thomas Hellström
2023-12-11 13:43 ` [PATCH v7 08/10] drm/xe/xe2: Handle flat ccs move for igfx Himal Prasad Ghimiray
2023-12-12 12:31   ` Thomas Hellström
2023-12-11 13:43 ` [PATCH v7 09/10] drm/xe/xe2: Modify xe_bo_test for system memory Himal Prasad Ghimiray
2023-12-11 13:43 ` [PATCH v7 10/10] drm/xe/xe2: Support flat ccs Himal Prasad Ghimiray
2023-12-12 12:33   ` Thomas Hellström
2023-12-11 14:25 ` ✓ CI.Patch_applied: success for Enable compression handling on LNL. (rev8) Patchwork
2023-12-11 14:25 ` ✗ CI.checkpatch: warning " Patchwork
2023-12-11 14:26 ` ✓ CI.KUnit: success " Patchwork
2023-12-11 14:34 ` ✓ CI.Build: " Patchwork
2023-12-11 14:34 ` ✓ CI.Hooks: " Patchwork
2023-12-11 14:35 ` ✓ CI.checksparse: " Patchwork
2023-12-11 15:10 ` ✓ CI.BAT: " Patchwork
  -- strict thread matches above, loose matches on Subject: below --
2023-12-11 13:41 [PATCH v7 00/10] *Enable compression handling on LNL Himal Prasad Ghimiray
2023-12-11 13:41 ` [PATCH v7 10/10] drm/xe/xe2: Support flat ccs Himal Prasad Ghimiray

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox