public inbox for intel-xe@lists.freedesktop.org
 help / color / mirror / Atom feed
* [PATCH v2 00/10] Start fixing OA whitelist mistakes
@ 2026-04-08 23:42 Matt Roper
  2026-04-08 23:43 ` [PATCH v2 01/10] drm/xe/oa: Stop whitelisting non-SAG MMIO_TRG registers on non-DG2 Matt Roper
                   ` (18 more replies)
  0 siblings, 19 replies; 21+ messages in thread
From: Matt Roper @ 2026-04-08 23:42 UTC (permalink / raw)
  To: intel-xe; +Cc: Ashutosh Dixit, Matt Roper

There are a number of mistakes in the OA register whitelists:
 - Unlimited upper bounds (never allowed for whitelists entries!)
 - Whitelisting registers that userspace already has access to
 - Whitelisting registers that userspace is not intended to ever need
   access to

This series addresses the first two bullets and partially addresses the
third.  For registers that weren't supposed to be exposed in the first
place, there are still some cases where we're exposing registers that we
really shouldn't be, or exposing them on engines that we shouldn't be,
but we need to confirm that no legitimate userspace has started
(mis)using them before making further changes so that we won't cause a
regression.

This series also partially unmacro-izes some of the OA entries since the
several layers of C macros were obfuscating exactly what was/wasn't
being whitelisted and making it harder to audit for mistakes.

v2:
 - Continue to whitelist OAGSAG's trigger since we've been allowing
   userspace to access it on the "wrong" engine.  Hardware only expects
   the GSC engine to access this instance, so it doesn't automatically
   grant VCS/VECS access.
 - Eliminate whitelisting of OASTARTTRIG_COUNTER; this has never been a
   valid register for userspace to have access to and was only
   accidentally included due to improper use of a RANGE_4 flag.
 - Consolidate oam_mmio_trg_vcs and oam_mmio_trg_vecs into a single
   entry with a custom match function.
 - Eliminate some layers of C macros to make it clear which registers
   we're actually referencing.

--
2.52.0

---
Matt Roper (10):
      drm/xe/oa: Stop whitelisting non-SAG MMIO_TRG registers on non-DG2
      drm/xe/oa: Stop whitelisting OAG_OASTATUS
      drm/xe/oa: Stop whitelisting OAM registers on non Xe2/Xe3
      drm/xe/oa: Stop whitelisting OAG registers after Xe3
      drm/xe: Add WHITELIST_RO macro
      drm/xe/oa: Consolidate RTP entries for OAM whitelist
      drm/xe/oa: Consolidate RTP entries for OAG whitelist
      drm/xe/oa: Consolidate RTP entries for OA MERT
      drm/xe: Enable all FORCE_TO_NONPRIV registers
      drm/xe/oa: Stop whitelisting OASTARTTRIG_COUNTER

 drivers/gpu/drm/xe/regs/xe_engine_regs.h |   7 +-
 drivers/gpu/drm/xe/xe_reg_whitelist.c    | 115 ++++++++++++++++++-------------
 2 files changed, 74 insertions(+), 48 deletions(-)
---
base-commit: 9e217a8df7b2f298a2fd850e29f970b7360dc77b
change-id: 20260407-oa-whitelist-cleanup-21baae7fbb78

Best regards,
-- 
Matt Roper
Graphics Software Engineer
Linux GPU Platform Enablement
Intel Corporation


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

end of thread, other threads:[~2026-04-14 14:11 UTC | newest]

Thread overview: 21+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-04-08 23:42 [PATCH v2 00/10] Start fixing OA whitelist mistakes Matt Roper
2026-04-08 23:43 ` [PATCH v2 01/10] drm/xe/oa: Stop whitelisting non-SAG MMIO_TRG registers on non-DG2 Matt Roper
2026-04-08 23:43 ` [PATCH v2 02/10] drm/xe/oa: Stop whitelisting OAG_OASTATUS Matt Roper
2026-04-08 23:43 ` [PATCH v2 03/10] drm/xe/oa: Stop whitelisting OAM registers on non Xe2/Xe3 Matt Roper
2026-04-08 23:43 ` [PATCH v2 04/10] drm/xe/oa: Stop whitelisting OAG registers after Xe3 Matt Roper
2026-04-08 23:43 ` [PATCH v2 05/10] drm/xe: Add WHITELIST_RO macro Matt Roper
2026-04-08 23:43 ` [PATCH v2 06/10] drm/xe/oa: Consolidate RTP entries for OAM whitelist Matt Roper
2026-04-08 23:43 ` [PATCH v2 07/10] drm/xe/oa: Consolidate RTP entries for OAG whitelist Matt Roper
2026-04-08 23:43 ` [PATCH v2 08/10] drm/xe/oa: Consolidate RTP entries for OA MERT Matt Roper
2026-04-08 23:43 ` [PATCH v2 09/10] drm/xe: Enable all FORCE_TO_NONPRIV registers Matt Roper
2026-04-08 23:43 ` [PATCH v2 10/10] drm/xe/oa: Stop whitelisting OASTARTTRIG_COUNTER Matt Roper
2026-04-08 23:50 ` ✗ CI.checkpatch: warning for Start fixing OA whitelist mistakes (rev3) Patchwork
2026-04-08 23:51 ` ✗ CI.KUnit: failure " Patchwork
2026-04-09 20:49 ` ✗ CI.checkpatch: warning for Start fixing OA whitelist mistakes (rev4) Patchwork
2026-04-09 20:50 ` ✗ CI.KUnit: failure " Patchwork
2026-04-10 16:35 ` ✗ CI.checkpatch: warning for Start fixing OA whitelist mistakes (rev5) Patchwork
2026-04-10 16:37 ` ✓ CI.KUnit: success " Patchwork
2026-04-10 17:13 ` ✓ Xe.CI.BAT: " Patchwork
2026-04-11  4:30 ` ✗ Xe.CI.FULL: failure " Patchwork
2026-04-14  4:25 ` [PATCH v2 00/10] Start fixing OA whitelist mistakes Dixit, Ashutosh
2026-04-14 14:11   ` Matt Roper

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