From: "Dixit, Ashutosh" <ashutosh.dixit@intel.com>
To: Matt Roper <matthew.d.roper@intel.com>
Cc: intel-xe@lists.freedesktop.org,
Michal Wajdeczko <michal.wajdeczko@intel.com>
Subject: Re: [PATCH v3 1/4] drm/xe/reg_sr: Don't process gt/hwe lists in VF
Date: Tue, 17 Feb 2026 13:34:46 -0800 [thread overview]
Message-ID: <87ikbvawax.wl-ashutosh.dixit@intel.com> (raw)
In-Reply-To: <20260213000929.732113-7-matthew.d.roper@intel.com>
On Thu, 12 Feb 2026 16:09:31 -0800, Matt Roper wrote:
>
Hi Matt,
> diff --git a/drivers/gpu/drm/xe/xe_hw_engine.c b/drivers/gpu/drm/xe/xe_hw_engine.c
> index 4d3ee5226e3a..7061312ce6b5 100644
> --- a/drivers/gpu/drm/xe/xe_hw_engine.c
> +++ b/drivers/gpu/drm/xe/xe_hw_engine.c
> @@ -472,6 +472,9 @@ hw_engine_setup_default_state(struct xe_hw_engine *hwe)
> },
> };
>
> + if (IS_SRIOV_VF(gt_to_xe(gt)))
> + return;
> +
I was thinking, instead of having this check in multiple places, this check
should be moved inside xe_rtp_process_to_sr(). And then we should tell
xe_rtp_process_to_sr() whether to skip or to continue somehow. We could
either:
a. add a "type" field (gt/hwe/lrc) to either reg_sr or to ctx, or,
b. add another 'vf' argument to xe_rtp_process_to_sr() ('vf' would be say 1
for lrc and 0 for other cases).
And based on this information xe_rtp_process_to_sr() would either skip or
continue for VF's.
Thanks.
--
Ashutosh
> xe_rtp_process_to_sr(&ctx, engine_entries, ARRAY_SIZE(engine_entries), &hwe->reg_sr);
> }
>
> diff --git a/drivers/gpu/drm/xe/xe_reg_sr.c b/drivers/gpu/drm/xe/xe_reg_sr.c
> index d3e13ea33123..1ac911fc6e94 100644
> --- a/drivers/gpu/drm/xe/xe_reg_sr.c
> +++ b/drivers/gpu/drm/xe/xe_reg_sr.c
> @@ -13,6 +13,7 @@
> #include <drm/drm_managed.h>
> #include <drm/drm_print.h>
>
> +#include "xe_assert.h"
> #include "xe_device.h"
> #include "xe_device_types.h"
> #include "xe_force_wake.h"
> @@ -169,8 +170,11 @@ void xe_reg_sr_apply_mmio(struct xe_reg_sr *sr, struct xe_gt *gt)
> if (xa_empty(&sr->xa))
> return;
>
> - if (IS_SRIOV_VF(gt_to_xe(gt)))
> - return;
> + /*
> + * We don't process non-LRC reg_sr lists in VF, so they should have
> + * been empty in the check above.
> + */
> + xe_gt_assert(gt, !IS_SRIOV_VF(gt_to_xe(gt)));
>
> xe_gt_dbg(gt, "Applying %s save-restore MMIOs\n", sr->name);
>
> diff --git a/drivers/gpu/drm/xe/xe_reg_whitelist.c b/drivers/gpu/drm/xe/xe_reg_whitelist.c
> index 9c513778d370..83b2d1c68acf 100644
> --- a/drivers/gpu/drm/xe/xe_reg_whitelist.c
> +++ b/drivers/gpu/drm/xe/xe_reg_whitelist.c
> @@ -188,6 +188,9 @@ void xe_reg_whitelist_process_engine(struct xe_hw_engine *hwe)
> {
> struct xe_rtp_process_ctx ctx = XE_RTP_PROCESS_CTX_INITIALIZER(hwe);
>
> + if (IS_SRIOV_VF(gt_to_xe(hwe->gt)))
> + return;
> +
> xe_rtp_process_to_sr(&ctx, register_whitelist, ARRAY_SIZE(register_whitelist),
> &hwe->reg_whitelist);
> whitelist_apply_to_hwe(hwe);
> diff --git a/drivers/gpu/drm/xe/xe_tuning.c b/drivers/gpu/drm/xe/xe_tuning.c
> index 316f5e2b2e48..ddd8519f3f19 100644
> --- a/drivers/gpu/drm/xe/xe_tuning.c
> +++ b/drivers/gpu/drm/xe/xe_tuning.c
> @@ -15,6 +15,7 @@
> #include "xe_gt_types.h"
> #include "xe_platform_types.h"
> #include "xe_rtp.h"
> +#include "xe_sriov.h"
>
> #undef XE_REG_MCR
> #define XE_REG_MCR(...) XE_REG(__VA_ARGS__, .mcr = 1)
> @@ -197,6 +198,9 @@ void xe_tuning_process_gt(struct xe_gt *gt)
> {
> struct xe_rtp_process_ctx ctx = XE_RTP_PROCESS_CTX_INITIALIZER(gt);
>
> + if (IS_SRIOV_VF(gt_to_xe(gt)))
> + return;
> +
> xe_rtp_process_ctx_enable_active_tracking(&ctx,
> gt->tuning_active.gt,
> ARRAY_SIZE(gt_tunings));
> @@ -208,6 +212,9 @@ void xe_tuning_process_engine(struct xe_hw_engine *hwe)
> {
> struct xe_rtp_process_ctx ctx = XE_RTP_PROCESS_CTX_INITIALIZER(hwe);
>
> + if (IS_SRIOV_VF(gt_to_xe(hwe->gt)))
> + return;
> +
> xe_rtp_process_ctx_enable_active_tracking(&ctx,
> hwe->gt->tuning_active.engine,
> ARRAY_SIZE(engine_tunings));
> diff --git a/drivers/gpu/drm/xe/xe_wa.c b/drivers/gpu/drm/xe/xe_wa.c
> index 843ce9fe7aab..92547280a5b6 100644
> --- a/drivers/gpu/drm/xe/xe_wa.c
> +++ b/drivers/gpu/drm/xe/xe_wa.c
> @@ -1003,6 +1003,9 @@ void xe_wa_process_gt(struct xe_gt *gt)
> {
> struct xe_rtp_process_ctx ctx = XE_RTP_PROCESS_CTX_INITIALIZER(gt);
>
> + if (IS_SRIOV_VF(gt_to_xe(gt)))
> + return;
> +
> xe_rtp_process_ctx_enable_active_tracking(&ctx, gt->wa_active.gt,
> ARRAY_SIZE(gt_was));
> xe_rtp_process_to_sr(&ctx, gt_was, ARRAY_SIZE(gt_was), >->reg_sr);
> @@ -1021,6 +1024,9 @@ void xe_wa_process_engine(struct xe_hw_engine *hwe)
> {
> struct xe_rtp_process_ctx ctx = XE_RTP_PROCESS_CTX_INITIALIZER(hwe);
>
> + if (IS_SRIOV_VF(gt_to_xe(hwe->gt)))
> + return;
> +
> xe_rtp_process_ctx_enable_active_tracking(&ctx, hwe->gt->wa_active.engine,
> ARRAY_SIZE(engine_was));
> xe_rtp_process_to_sr(&ctx, engine_was, ARRAY_SIZE(engine_was), &hwe->reg_sr);
> --
> 2.53.0
>
next prev parent reply other threads:[~2026-02-17 21:34 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-02-13 0:09 [PATCH v3 0/4] Add debugfs facility to catch RTP mistakes Matt Roper
2026-02-13 0:09 ` [PATCH v3 1/4] drm/xe/reg_sr: Don't process gt/hwe lists in VF Matt Roper
2026-02-17 21:34 ` Dixit, Ashutosh [this message]
2026-02-13 0:09 ` [PATCH v3 2/4] drm/xe/reg_sr: Add debugfs to verify status of reg_sr programming Matt Roper
2026-02-13 0:09 ` [PATCH v3 3/4] drm/xe: Add facility to lookup the value of a register in a default LRC Matt Roper
2026-02-13 0:09 ` [PATCH v3 4/4] drm/xe/reg_sr: Allow register_save_restore_check debugfs to verify LRC values Matt Roper
2026-02-13 0:16 ` ✓ CI.KUnit: success for Add debugfs facility to catch RTP mistakes (rev2) Patchwork
2026-02-13 0:59 ` ✓ Xe.CI.BAT: " Patchwork
2026-02-14 1:07 ` ✗ Xe.CI.FULL: failure " Patchwork
2026-02-23 17:40 ` [PATCH v3 0/4] Add debugfs facility to catch RTP mistakes Daniel Charles
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=87ikbvawax.wl-ashutosh.dixit@intel.com \
--to=ashutosh.dixit@intel.com \
--cc=intel-xe@lists.freedesktop.org \
--cc=matthew.d.roper@intel.com \
--cc=michal.wajdeczko@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