Intel-XE Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Michal Wajdeczko <michal.wajdeczko@intel.com>
To: Satyanarayana K V P <satyanarayana.k.v.p@intel.com>,
	<intel-xe@lists.freedesktop.org>
Cc: Matthew Brost <matthew.brost@intel.com>,
	Tomasz Lis <tomasz.lis@intel.com>
Subject: Re: [PATCH v6 1/3] drm/xe/vf: Enable VF migration only on supported GuC versions
Date: Thu, 27 Nov 2025 15:45:51 +0100	[thread overview]
Message-ID: <cdc62518-6d54-496d-9d7e-94313ae1e8a6@intel.com> (raw)
In-Reply-To: <20251124160719.29812-6-satyanarayana.k.v.p@intel.com>



On 11/24/2025 5:07 PM, Satyanarayana K V P wrote:
> Enable VF migration starting with GuC 70.54.0 (compatibility version
> 1.27.0) which supports additional VF2GUC_RESFIX_START message required
> to handle migration recovery in a more robust way.
> 
> Signed-off-by: Satyanarayana K V P <satyanarayana.k.v.p@intel.com>
> Cc: Michal Wajdeczko <michal.wajdeczko@intel.com>
> Cc: Matthew Brost <matthew.brost@intel.com>
> Cc: Tomasz Lis <tomasz.lis@intel.com>
> 
> ---
> V5 -> V6:
> - Fixed review comments (Michal W).
> - Updated commit message.
> - return xe_sriov_vf_migration_supported() from vf_migration_init_late().
> 
> V4 -> V5:
> - Created new function vf_migration_init_late() (Michal W).
> 
> V3 -> V4:
> - New commit
> 
> V2 -> V3:
> - None.
> 
> V1 -> V2:
> - None.
> ---
>  drivers/gpu/drm/xe/xe_sriov_vf.c | 19 +++++++++++++++++++
>  1 file changed, 19 insertions(+)
> 
> diff --git a/drivers/gpu/drm/xe/xe_sriov_vf.c b/drivers/gpu/drm/xe/xe_sriov_vf.c
> index 284ce37ca92d..f53d68f2f1d2 100644
> --- a/drivers/gpu/drm/xe/xe_sriov_vf.c
> +++ b/drivers/gpu/drm/xe/xe_sriov_vf.c
> @@ -170,6 +170,22 @@ void xe_sriov_vf_init_early(struct xe_device *xe)
>  	vf_migration_init_early(xe);
>  }
>  
> +static bool vf_migration_init_late(struct xe_device *xe)
> +{
> +	struct xe_gt *gt = xe_root_mmio_gt(xe);
> +	struct xe_uc_fw_version guc_version;
> +

hmm, I'm wondering whether we should do anything here if migration was already disabled at some earlier point

this can be already observed on ADLP [1] where we have two messages:

<5> [420.828841] xe 0000:00:02.1: [drm] VF: migration disabled: requires memory-based IRQ support
...
<5> [420.910616] xe 0000:00:02.1: [drm] VF: migration disabled: requires GuC ABI >= 1.27.0, but only 1.24.4 found

maybe this function should look like:

int vf_migration_init_late(...)
{
	if (!xe_sriov_vf_migration_supported(xe))
		return 0;

	if (MAKE_GUC_VER_STRUCT(guc_version) < MAKE_GUC_VER(1, 27, 0)) {
		xe_sriov_vf_migration_disable(xe,
					      "requires GuC ABI >= 1.27.0, but only %u.%u.%u found",
					      guc_version.major, guc_version.minor,
					      guc_version.patch);
		return 0;
	}

  	return xe_sriov_vf_ccs_init(xe);
}

including VF CCS since it is still part of the 'migration' feature, right

[1] https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-156339v6/bat-adlp-7/igt@sriov_basic@enable-vfs-autoprobe-on.html


> +	xe_gt_sriov_vf_guc_versions(gt, NULL, &guc_version);
> +	if (MAKE_GUC_VER_STRUCT(guc_version) < MAKE_GUC_VER(1, 27, 0)) {
> +		xe_sriov_vf_migration_disable(xe,
> +					      "requires GuC ABI >= 1.27.0, but only %u.%u.%u found",
> +					      guc_version.major, guc_version.minor,
> +					      guc_version.patch);
> +	}
> +
> +	return xe_sriov_vf_migration_supported(xe);
> +}
> +
>  /**
>   * xe_sriov_vf_init_late() - SR-IOV VF late initialization functions.
>   * @xe: the &xe_device to initialize
> @@ -180,6 +196,9 @@ void xe_sriov_vf_init_early(struct xe_device *xe)
>   */
>  int xe_sriov_vf_init_late(struct xe_device *xe)
>  {
> +	if (!vf_migration_init_late(xe))
> +		return 0;
> +
>  	return xe_sriov_vf_ccs_init(xe);
>  }
>  


  reply	other threads:[~2025-11-27 14:46 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-11-24 16:07 [PATCH v6 0/3] VF double migration Satyanarayana K V P
2025-11-24 16:07 ` [PATCH v6 1/3] drm/xe/vf: Enable VF migration only on supported GuC versions Satyanarayana K V P
2025-11-27 14:45   ` Michal Wajdeczko [this message]
2025-11-24 16:07 ` [PATCH v6 2/3] drm/xe/vf: Introduce RESFIX start marker support Satyanarayana K V P
2025-11-27 16:17   ` Michal Wajdeczko
2025-11-24 16:07 ` [PATCH v6 3/3] drm/xe/vf: Add debugfs entries to test VF double migration Satyanarayana K V P
2025-11-27 16:51   ` Michal Wajdeczko
2025-11-25  3:30 ` ✓ CI.KUnit: success for VF double migration (rev6) Patchwork
2025-11-25  4:08 ` ✓ Xe.CI.BAT: " Patchwork
2025-11-25  6:55 ` ✗ 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=cdc62518-6d54-496d-9d7e-94313ae1e8a6@intel.com \
    --to=michal.wajdeczko@intel.com \
    --cc=intel-xe@lists.freedesktop.org \
    --cc=matthew.brost@intel.com \
    --cc=satyanarayana.k.v.p@intel.com \
    --cc=tomasz.lis@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