From: Arisa Snowbell <arisa.snowbell@gmail.com>
To: intel-xe@lists.freedesktop.org
Cc: dri-devel@lists.freedesktop.org,
"Daniele Ceraolo Spurio" <daniele.ceraolospurio@intel.com>,
"Arisa Snowbell" <arisa.snowbell@gmail.com>,
"Matthew Brost" <matthew.brost@intel.com>,
"Thomas Hellström" <thomas.hellstrom@linux.intel.com>,
"Rodrigo Vivi" <rodrigo.vivi@intel.com>,
"David Airlie" <airlied@gmail.com>,
"Simona Vetter" <simona@ffwll.ch>,
linux-kernel@vger.kernel.org
Subject: [PATCH 5/5] drm/xe/uc_fw: select the DG2 HuC blob for a load by the GSC
Date: Thu, 26 Nov 2026 21:57:57 +0100 [thread overview]
Message-ID: <20261126205758.49845-6-arisa.snowbell@gmail.com> (raw)
In-Reply-To: <20261126205758.49845-1-arisa.snowbell@gmail.com>
The GSC loads the whole DG2 HuC binary (dg2_huc_gsc.bin, the one i915
uses), so there is no legacy CSS image to find in it for a DMA load: parse
the CPD header for the manifest version only.
This enables the HuC on DG2.
Signed-off-by: Arisa Snowbell <arisa.snowbell@gmail.com>
---
drivers/gpu/drm/xe/xe_uc_fw.c | 14 +++++++++-----
1 file changed, 9 insertions(+), 5 deletions(-)
diff --git a/drivers/gpu/drm/xe/xe_uc_fw.c b/drivers/gpu/drm/xe/xe_uc_fw.c
index d0ea05923..05f51378b 100644
--- a/drivers/gpu/drm/xe/xe_uc_fw.c
+++ b/drivers/gpu/drm/xe/xe_uc_fw.c
@@ -137,6 +137,7 @@ struct fw_blobs_by_type {
fw_def(BATTLEMAGE, GT_TYPE_ANY, no_ver(xe, huc, bmg)) \
fw_def(LUNARLAKE, GT_TYPE_ANY, no_ver(xe, huc, lnl)) \
fw_def(METEORLAKE, GT_TYPE_ANY, no_ver(i915, huc_gsc, mtl)) \
+ fw_def(DG2, GT_TYPE_ANY, no_ver(i915, huc_gsc, dg2)) \
fw_def(DG1, GT_TYPE_ANY, no_ver(i915, huc, dg1)) \
fw_def(ALDERLAKE_N, GT_TYPE_ANY, no_ver(i915, huc, tgl)) \
fw_def(ALDERLAKE_P, GT_TYPE_ANY, no_ver(i915, huc, tgl)) \
@@ -555,11 +556,7 @@ static int parse_cpd_header(struct xe_uc_fw *uc_fw, const void *data, size_t siz
if (css_entry) {
int ret;
- /*
- * This section does not contain a CSS entry on DG2. We
- * don't support DG2 HuC right now, so no need to handle
- * it, just add a reminder in case that changes.
- */
+ /* The DG2 HuC has no CSS entry, its caller passes none */
xe_assert(xe, xe->info.platform != XE_DG2);
offset = entry_offset(header, css_entry);
@@ -661,6 +658,13 @@ static int parse_headers(struct xe_uc_fw *uc_fw, const struct firmware *fw)
case XE_UC_FW_TYPE_GSC:
return parse_gsc_layout(uc_fw, fw->data, fw->size);
case XE_UC_FW_TYPE_HUC:
+ /*
+ * The GSC loads the whole DG2 binary itself, so there is no
+ * legacy CSS image to find for a DMA load.
+ */
+ if (uc_fw_to_xe(uc_fw)->info.platform == XE_DG2)
+ return parse_cpd_header(uc_fw, fw->data, fw->size, "HUCP.man", NULL);
+
ret = parse_cpd_header(uc_fw, fw->data, fw->size, "HUCP.man", "huc_fw");
if (!ret || ret != -ENOENT)
return ret;
--
2.56.1
prev parent reply other threads:[~2026-11-26 20:58 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20261126205758.49845-1-arisa.snowbell@gmail.com>
2026-11-26 20:57 ` [PATCH 1/5] drm/xe/heci: expose the DG2 HECI1 interface to mei Arisa Snowbell
2026-11-26 20:57 ` [PATCH 2/5] mei: gsc: bind the xe HECI1 device Arisa Snowbell
2026-11-26 20:57 ` [PATCH 3/5] drm/xe/huc: load the DG2 HuC through the GSC via mei_pxp Arisa Snowbell
2026-11-26 20:57 ` [PATCH 4/5] drm/xe: hold video decode work and HuC queries for a pending DG2 HuC load Arisa Snowbell
2026-11-26 20:57 ` Arisa Snowbell [this message]
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=20261126205758.49845-6-arisa.snowbell@gmail.com \
--to=arisa.snowbell@gmail.com \
--cc=airlied@gmail.com \
--cc=daniele.ceraolospurio@intel.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=intel-xe@lists.freedesktop.org \
--cc=linux-kernel@vger.kernel.org \
--cc=matthew.brost@intel.com \
--cc=rodrigo.vivi@intel.com \
--cc=simona@ffwll.ch \
--cc=thomas.hellstrom@linux.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
all inboxes | Powered by JetHome®