From: Xin Wang <x.wang@intel.com>
To: intel-xe@lists.freedesktop.org
Cc: rodrigo.vivi@intel.com, karthik.poosa@intel.com,
james.xiong@intel.com, stuart.summers@intel.com,
shuicheng.lin@intel.com, vinay.belgaumkar@intel.com,
Xin Wang <x.wang@intel.com>
Subject: [PATCH 1/3] drm/xe: early-return for SR-IOV VF in C6 funcs
Date: Mon, 25 Aug 2025 15:32:17 -0700 [thread overview]
Message-ID: <20250825223219.1351786-2-x.wang@intel.com> (raw)
In-Reply-To: <20250825223219.1351786-1-x.wang@intel.com>
VF drivers can't access any of gtidle control registers. By
returning early when IS_SRIOV_VF() is true, we avoid executing
the assertions.
Suggested-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
Signed-off-by: Xin Wang <x.wang@intel.com>
---
drivers/gpu/drm/xe/xe_gt_idle.c | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/drivers/gpu/drm/xe/xe_gt_idle.c b/drivers/gpu/drm/xe/xe_gt_idle.c
index ffb210216aa9..611c506bdad1 100644
--- a/drivers/gpu/drm/xe/xe_gt_idle.c
+++ b/drivers/gpu/drm/xe/xe_gt_idle.c
@@ -377,12 +377,12 @@ int xe_gt_idle_init(struct xe_gt_idle *gtidle)
void xe_gt_idle_enable_c6(struct xe_gt *gt)
{
- xe_device_assert_mem_access(gt_to_xe(gt));
- xe_force_wake_assert_held(gt_to_fw(gt), XE_FW_GT);
-
if (IS_SRIOV_VF(gt_to_xe(gt)))
return;
+ xe_device_assert_mem_access(gt_to_xe(gt));
+ xe_force_wake_assert_held(gt_to_fw(gt), XE_FW_GT);
+
/* Units of 1280 ns for a total of 5s */
xe_mmio_write32(>->mmio, RC_IDLE_HYSTERSIS, 0x3B9ACA);
/* Enable RC6 */
@@ -392,12 +392,12 @@ void xe_gt_idle_enable_c6(struct xe_gt *gt)
void xe_gt_idle_disable_c6(struct xe_gt *gt)
{
- xe_device_assert_mem_access(gt_to_xe(gt));
- xe_force_wake_assert_held(gt_to_fw(gt), XE_FW_GT);
-
if (IS_SRIOV_VF(gt_to_xe(gt)))
return;
+ xe_device_assert_mem_access(gt_to_xe(gt));
+ xe_force_wake_assert_held(gt_to_fw(gt), XE_FW_GT);
+
xe_mmio_write32(>->mmio, RC_CONTROL, 0);
xe_mmio_write32(>->mmio, RC_STATE, 0);
}
--
2.43.0
next prev parent reply other threads:[~2025-08-25 22:32 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-08-25 22:32 [PATCH 0/3] Ensure GT is in C0 during resumes Xin Wang
2025-08-25 22:32 ` Xin Wang [this message]
2025-08-26 14:19 ` [PATCH 1/3] drm/xe: early-return for SR-IOV VF in C6 funcs Rodrigo Vivi
2025-08-26 16:25 ` Wang, X
2025-08-25 22:32 ` [PATCH 2/3] drm/xe: make xe_gt_idle_disable_c6() handle the forcewake internally Xin Wang
2025-08-25 22:32 ` [PATCH 3/3] drm/xe: Ensure GT is in C0 during resumes Xin Wang
2025-08-25 22:39 ` ✓ CI.KUnit: success for Ensure GT is in C0 during resumes (rev3) Patchwork
2025-08-25 23:34 ` ✓ Xe.CI.BAT: " Patchwork
2025-08-26 8:05 ` ✗ 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=20250825223219.1351786-2-x.wang@intel.com \
--to=x.wang@intel.com \
--cc=intel-xe@lists.freedesktop.org \
--cc=james.xiong@intel.com \
--cc=karthik.poosa@intel.com \
--cc=rodrigo.vivi@intel.com \
--cc=shuicheng.lin@intel.com \
--cc=stuart.summers@intel.com \
--cc=vinay.belgaumkar@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 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.