From: sashiko-bot@kernel.org
To: "Daniele Ceraolo Spurio" <daniele.ceraolospurio@intel.com>,
intel-xe@lists.freedesktop.org
Subject: Re: [PATCH v4 1/2] drm/xe/wopcm: Use the size from HW when excluding the wopcm range from GGTT
Date: Wed, 18 Nov 2026 22:10:05 +0000 [thread overview]
Message-ID: <sashiko-outbox-222088@kernel.org> (raw)
In-Reply-To: <20261118220120.109186-3-daniele.ceraolospurio@intel.com>
Thank you for your contribution! Sashiko AI review found 1 potential
issue to consider:
- [Medium] drm/xe/ggtt: missing start offset in
ggtt_get_range_from_guc() range check
--
commit 87d7496d04ac1372f5227944d418e464c057bf0e
Author: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
drm/xe/wopcm: Use the size from HW when excluding the wopcm range from GGTT
This commit reads the per-tile WOPCM size from hardware into struct xe_tile
and uses it for both GGTT and stolen memory setup instead of a hardcoded
value, while dropping the WOPCM lower-bound check on SR-IOV VFs.
> diff --git a/drivers/gpu/drm/xe/xe_ggtt.c b/drivers/gpu/drm/xe/xe_ggtt.c
> index 44480fad27679..1bc5b8c0f2b9e 100644
> --- a/drivers/gpu/drm/xe/xe_ggtt.c
> +++ b/drivers/gpu/drm/xe/xe_ggtt.c
[ ... ]
> @@ -422,13 +422,11 @@ static int ggtt_probe(struct xe_ggtt *ggtt, u64 *start, u64 *size)
>
> static int ggtt_get_range_from_guc(struct xe_ggtt *ggtt, u64 *start, u64 *size)
> {
> - struct xe_device *xe = tile_to_xe(ggtt->tile);
> - u64 wopcm = xe_wopcm_size(xe);
> -
> *start = xe_tile_sriov_vf_ggtt_base(ggtt->tile);
> *size = xe_tile_sriov_vf_ggtt(ggtt->tile);
>
> - if (*start < wopcm || *start + *size > GUC_GGTT_TOP) {
> + /* We can't check start against WOPCM as VF doesn't have access to the WOPCM size */
> + if (*size > GUC_GGTT_TOP) {
> xe_log_err_fatal(ggtt->tile, GGTT, -ERANGE,
> "Invalid GGTT configuration: %#llx-%#llx\n",
> *start, *start + *size - 1);
[Severity: Medium]
Should this upper-bound check remain *start + *size > GUC_GGTT_TOP?
Dropping *start + allows a VF GGTT range with *size <= GUC_GGTT_TOP but
*start + *size > GUC_GGTT_TOP to pass validation, and since
ggtt_read_available_range() only clamps *size on !IS_SRIOV_VF(xe), the VF
GGTT will be initialized with addresses extending past GUC_GGTT_TOP.
--
Sashiko AI review · https://sashiko.dev/#/patchset/20261118220120.109186-3-daniele.ceraolospurio@intel.com?part=1
next prev parent reply other threads:[~2026-11-18 22:10 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-18 22:01 [PATCH v4 1/2] drm/xe/wopcm: Use the size from HW when excluding the wopcm range from GGTT Daniele Ceraolo Spurio
2026-11-18 22:01 ` [PATCH v4 2/2] drm/xe/wopcm: Simplify GuC WOPCM programming Daniele Ceraolo Spurio
2026-11-18 22:10 ` sashiko-bot [this message]
2026-11-18 22:48 ` [PATCH v4 1/2] drm/xe/wopcm: Use the size from HW when excluding the wopcm range from GGTT Matt Roper
2026-11-19 3:10 ` ✗ CI.checkpatch: warning for series starting with [v4,1/2] " Patchwork
2026-11-19 3:12 ` ✓ CI.KUnit: success " Patchwork
2026-11-19 3:54 ` ✓ Xe.CI.BAT: " Patchwork
2026-11-20 4:20 ` ✗ Xe.CI.FULL: failure " 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=sashiko-outbox-222088@kernel.org \
--to=sashiko-bot@kernel.org \
--cc=daniele.ceraolospurio@intel.com \
--cc=intel-xe@lists.freedesktop.org \
--cc=sashiko-reviews@lists.linux.dev \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.