Intel-XE Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: sashiko-bot@kernel.org
To: "Lukasz Laguna" <lukasz.laguna@intel.com>,
	intel-xe@lists.freedesktop.org
Subject: Re: [PATCH] drm/xe/vf: Support PCIe FLR
Date: Tue, 24 Nov 2026 15:42:05 +0000	[thread overview]
Message-ID: <sashiko-outbox-231452@kernel.org> (raw)
In-Reply-To: <20261124151645.411812-1-lukasz.laguna@intel.com>

Thank you for your contribution! Sashiko AI review found 1 potential
issue to consider:
- [High] drm/xe/vf: skipped exec queue teardown in xe_guc_flr_prepare()
  on VF FLR
--

commit 1f41ab3661146300f9d5cbbfdfcce6ad967d0c93
Author: Lukasz Laguna <lukasz.laguna@intel.com>

drm/xe/vf: Support PCIe FLR

This commit enables PCIe Function Level Reset on SR-IOV VFs and resets the
GuC VF state over MMIO across all GTs before re-initializing the device.

> diff --git a/drivers/gpu/drm/xe/xe_pci_error.c b/drivers/gpu/drm/xe/xe_pci_error.c
> index d288bb291aa1b..4a14eb36173b6 100644
> --- a/drivers/gpu/drm/xe/xe_pci_error.c
> +++ b/drivers/gpu/drm/xe/xe_pci_error.c
[ ... ]
> @@ -234,7 +235,7 @@ static void xe_pci_error_resume(struct pci_dev *pdev)
>  
>  static inline bool xe_pci_reset_skip(struct xe_device *xe)
>  {
> -	return !IS_DGFX(xe) || IS_SRIOV_VF(xe) || xe_sriov_pf_num_vfs(xe) || xe->info.probe_display;
> +	return !IS_DGFX(xe) || xe_sriov_pf_num_vfs(xe) || xe->info.probe_display;
>  }

[Severity: High]
Does enabling FLR on VFs skip tearing down GuC exec queues during
xe_pci_reset_prepare()?

On VFs, uc_fw_vf_override() sets guc->fw.status to
XE_UC_FIRMWARE_PRELOADED, for which xe_uc_fw_is_loadable() returns false.
When xe_pci_reset_prepare() calls xe_device_suspend(xe, false, true) ->
xe_gt_flr_prepare() -> xe_uc_flr_prepare() -> xe_guc_flr_prepare(), it
returns early without running xe_guc_submit_pause_abort():

drivers/gpu/drm/xe/xe_guc.c:xe_guc_flr_prepare() {
	if (!xe_uc_fw_is_loadable(&guc->fw))
		return;

	xe_guc_submit_stop(guc);
	xe_guc_submit_pause_abort(guc);
}

As a result, existing user and VM-bind exec queues are not killed and
pending jobs are not aborted during FLR preparation.  On resume in
xe_pci_reset_done(), guc_exec_queue_start() sees those queues still alive
and accesses their wiped VRAM LRC buffers (q->lrc[i]) and resubmits pending
jobs against VRAM state cleared by the FLR.

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20261124151645.411812-1-lukasz.laguna@intel.com?part=1

      parent reply	other threads:[~2026-11-24 15:42 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-24 15:16 [PATCH] drm/xe/vf: Support PCIe FLR Lukasz Laguna
2026-11-24 15:33 ` ✗ CI.KUnit: failure for " Patchwork
2026-11-24 15:42 ` sashiko-bot [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=sashiko-outbox-231452@kernel.org \
    --to=sashiko-bot@kernel.org \
    --cc=intel-xe@lists.freedesktop.org \
    --cc=lukasz.laguna@intel.com \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox