Intel-XE Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Stuart Summers <stuart.summers@intel.com>
Cc: rodrigo.vivi@intel.com, riana.tauro@intel.com,
	anoop.c.vijay@intel.com, intel-xe@lists.freedesktop.org,
	Stuart Summers <stuart.summers@intel.com>
Subject: [PATCH 2/2] drm/xe: Process device OOB workarounds during early info init
Date: Mon, 30 Nov 2026 21:50:12 +0000	[thread overview]
Message-ID: <20261130215010.199139-6-stuart.summers@intel.com> (raw)
In-Reply-To: <20261130215010.199139-4-stuart.summers@intel.com>

Device OOB workarounds only match on platform, subplatform and platform
step, all of which are known once xe_info_init_early() has copied them
out of the device descriptor. Processing them there instead of in
xe_device_probe_early() makes XE_DEVICE_WA() usable for the rest of
early probe, which runs before xe_device_probe_early().

While moving the call, check the return value of xe_wa_device_init(),
which the old call site silently dropped.

Signed-off-by: Stuart Summers <stuart.summers@intel.com>
Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
---
 drivers/gpu/drm/xe/xe_device.c | 3 ---
 drivers/gpu/drm/xe/xe_pci.c    | 9 +++++++++
 2 files changed, 9 insertions(+), 3 deletions(-)

diff --git a/drivers/gpu/drm/xe/xe_device.c b/drivers/gpu/drm/xe/xe_device.c
index fccb0eff54ee..86de5f183c0a 100644
--- a/drivers/gpu/drm/xe/xe_device.c
+++ b/drivers/gpu/drm/xe/xe_device.c
@@ -725,9 +725,6 @@ int xe_device_probe_early(struct xe_device *xe)
 {
 	int err;
 
-	xe_wa_device_init(xe);
-	xe_wa_process_device_oob(xe);
-
 	err = xe_mmio_probe_early(xe);
 	if (err)
 		return err;
diff --git a/drivers/gpu/drm/xe/xe_pci.c b/drivers/gpu/drm/xe/xe_pci.c
index ac04a45ab13e..0c6bc82d917b 100644
--- a/drivers/gpu/drm/xe/xe_pci.c
+++ b/drivers/gpu/drm/xe/xe_pci.c
@@ -15,6 +15,8 @@
 #include <drm/drm_drv.h>
 #include <drm/intel/pciids.h>
 
+#include <generated/xe_device_wa_oob.h>
+
 #include "display/xe_display.h"
 #include "regs/xe_gt_regs.h"
 #include "regs/xe_regs.h"
@@ -40,6 +42,7 @@
 #include "xe_tile.h"
 #include "xe_tile_printk.h"
 #include "xe_wedge.h"
+#include "xe_wa.h"
 
 enum toggle_d3cold {
 	D3COLD_DISABLE,
@@ -807,6 +810,12 @@ static int xe_info_init_early(struct xe_device *xe,
 	xe->info.subplatform = subplatform_desc ?
 		subplatform_desc->subplatform : XE_SUBPLATFORM_NONE;
 
+	err = xe_wa_device_init(xe);
+	if (err)
+		return err;
+
+	xe_wa_process_device_oob(xe);
+
 	xe->info.dma_mask_size = desc->dma_mask_size;
 	xe->info.va_bits = desc->va_bits;
 	xe->info.vm_max_level = desc->vm_max_level;
-- 
2.43.0


  parent reply	other threads:[~2026-11-30 21:51 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-30 21:50 [PATCH 0/2] Refactor to prepare for CRI media workaround Stuart Summers
2026-11-30 21:50 ` [PATCH 1/2] drm/xe/sysctrl: Use preallocated mailbox staging buffers Stuart Summers
2026-11-30 21:50 ` Stuart Summers [this message]
2026-11-30 22:02 ` ✓ CI.KUnit: success for Refactor to prepare for CRI media workaround Patchwork

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20261130215010.199139-6-stuart.summers@intel.com \
    --to=stuart.summers@intel.com \
    --cc=anoop.c.vijay@intel.com \
    --cc=intel-xe@lists.freedesktop.org \
    --cc=riana.tauro@intel.com \
    --cc=rodrigo.vivi@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox