Skip to content

Future-proof for multi-tile + multi-GT cases

Matt Roper intel-xe 4 versions – New

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v4 Latest7 patches 0 repliesNew
  2. v36 patches 11 repliesSuperseded
  3. v25 patches 3 repliesSuperseded
Earlier versions · 1
VersionPostedPatchesRepliesStatus
v15 patches4 repliesSuperseded

Changes in v4 from the cover letter

- If MTCFG makes us go back and reduce the tile count, also reduce gt_count in an equivalent manner to prune any GTs that would have belonged to the removed tiles. (PVC CI)
- Add additional patch at beginning of series to fix PMU GT check before starting refactoring. (Riana)

Patches in v4 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/7drm/xe/pmu: Fix GT sanity check in event_supported()drivers/gpu/drm/xe/xe_pmu.c+5 -20 replies
2/7drm/xe: Export xe_step_name for kunit testsdrivers/gpu/drm/xe/xe_step.c+2 -00 replies
3/7drm/xe: Track maximum GTs per tile on a per-platform basisdrivers/gpu/drm/xe/xe_device.h drivers/gpu/drm/xe/xe_device_types.h drivers/gpu/drm/xe/xe_pci.c +1 more+40 -230 replies
4/7drm/xe/tests/pci: Ensure all platforms have a valid GT/tile countdrivers/gpu/drm/xe/tests/xe_pci.c drivers/gpu/drm/xe/tests/xe_pci_test.c drivers/gpu/drm/xe/tests/xe_pci_test.h +2 more+85 -390 replies
5/7drm/xe: Assign GT IDs properly on multi-tile + multi-GT platformsdrivers/gpu/drm/xe/xe_mmio.c drivers/gpu/drm/xe/xe_pci.c+14 -160 replies
6/7drm/xe: Don't compare GT ID to GT count when determining valid GTsdrivers/gpu/drm/xe/xe_device.h drivers/gpu/drm/xe/xe_eu_stall.c drivers/gpu/drm/xe/xe_exec_queue.c +1 more+8 -90 replies
7/7drm/xe/xe_query: Use separate iterator while filling GT listdrivers/gpu/drm/xe/xe_query.c+15 -120 replies

Reviews trailers per patch

6 of 7 patches have a Reviewed-by or Acked-by.

PatchMichal WajdeczkoLucas De MarchiRavi Kumar VodapalliJonathan Cavitt
1/7
2/7R-b R-b
3/7R-b
4/7R-b
5/7R-b
6/7R-b
7/7R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 4 reviewers.

Read the v4 thread

Cover letter [PATCH v4 0/7] Future-proof for multi-tile + multi-GT cases

Today all of our platforms fall into one of three cases:
* Single tile platforms with a single (primary) GT
* Single tile platforms with two GTs (primary + media)
* Two-tile platforms with a single GT (primary) in each

Our numbering of GTs has been a bit inconsistent between platforms (e.g., GT1 is the media GT on some platforms, but the second tile's primary GT on others). In the future we'll likely have platforms that are both multi-tile and multi-GT, which will make the situation more confusing. We could also wind up with more than just two types of GTs at some point in the future.

Going forward we should standardize the way we assign uapi GT IDs to internal GT structures. Let's declare that for userspace GT ID n,

GT[n]'s tile = n / (max gt per tile)
GT[n]'s slot within tile = n % (max gt per tile)

If we allow 'max gt per tile' to vary by platform, we can support any possible future tile/GT combinations (even if new types of GTs show up) without changing any behavior of our existing platforms.

v2:
- Rebase on top of the latest xe_pci test updates from Michal. Convert the kunit test into a parameterized test that will run against each PCI ID supported by the driver.
v3:
- Rebase again
- Add an additional patch at the end of the series to ensure the GT query list is filled out properly.
v4:
- If MTCFG makes us go back and reduce the tile count, also reduce gt_count in an equivalent manner to prune any GTs that would have belonged to the removed tiles. (PVC CI)
- Add additional patch at beginning of series to fix PMU GT check before starting refactoring. (Riana)

Matt Roper (7):
drm/xe/pmu: Fix GT sanity check in event_supported() drm/xe: Export xe_step_name for kunit tests
drm/xe: Track maximum GTs per tile on a per-platform basis drm/xe/tests/pci: Ensure all platforms have a valid GT/tile count drm/xe: Assign GT IDs properly on multi-tile + multi-GT platforms drm/xe: Don't compare GT ID to GT count when determining valid GTs drm/xe/xe_query: Use separate iterator while filling GT list

 drivers/gpu/drm/xe/tests/xe_pci.c      | 31 ++++++++++++
 drivers/gpu/drm/xe/tests/xe_pci_test.c | 12 +++++
 drivers/gpu/drm/xe/tests/xe_pci_test.h |  1 +
 drivers/gpu/drm/xe/xe_device.h         | 47 ++++++++----------
 drivers/gpu/drm/xe/xe_device_types.h   |  2 +
 drivers/gpu/drm/xe/xe_eu_stall.c       |  6 ++-
 drivers/gpu/drm/xe/xe_exec_queue.c     |  2 +-
 drivers/gpu/drm/xe/xe_hw_engine.c      |  3 +-
 drivers/gpu/drm/xe/xe_mmio.c           | 16 +++---
 drivers/gpu/drm/xe/xe_pci.c            | 69 ++++++++------------------
 drivers/gpu/drm/xe/xe_pci_types.h      | 41 +++++++++++++++
 drivers/gpu/drm/xe/xe_pmu.c            |  7 ++-
 drivers/gpu/drm/xe/xe_query.c          | 29 ++++++-----
 drivers/gpu/drm/xe/xe_step.c           |  2 +
 14 files changed, 168 insertions(+), 100 deletions(-)
Signature · 1 line
2.49.0