From: John.C.Harrison@Intel.com
To: Intel-GFX@Lists.FreeDesktop.Org
Cc: John Harrison <John.C.Harrison@Intel.com>,
DRI-Devel@Lists.FreeDesktop.Org
Subject: [PATCH 1/3] drm/i915/guc: Temporarily bump the GuC load timeout
Date: Mon, 20 Dec 2021 16:52:19 -0800 [thread overview]
Message-ID: <20211221005221.1090824-2-John.C.Harrison@Intel.com> (raw)
In-Reply-To: <20211221005221.1090824-1-John.C.Harrison@Intel.com>
From: John Harrison <John.C.Harrison@Intel.com>
There is a known (but exceedingly unlikely) race condition where the
asynchronous frequency management code could reduce the GT clock while
a GuC reload is in progress (during a full GT reset). A fix is in
progress but there are complex locking issues to be resolved. In the
meantime bump the timeout to 500ms. Even at slowest clock, this
should be sufficient. And in the working case, a larger timeout makes
no difference.
Signed-off-by: John Harrison <John.C.Harrison@Intel.com>
---
drivers/gpu/drm/i915/gt/uc/intel_guc_fw.c | 13 +++++++++++--
1 file changed, 11 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/i915/gt/uc/intel_guc_fw.c b/drivers/gpu/drm/i915/gt/uc/intel_guc_fw.c
index 31420ce1ce6b..c03bde5ec61f 100644
--- a/drivers/gpu/drm/i915/gt/uc/intel_guc_fw.c
+++ b/drivers/gpu/drm/i915/gt/uc/intel_guc_fw.c
@@ -105,12 +105,21 @@ static int guc_wait_ucode(struct intel_uncore *uncore)
/*
* Wait for the GuC to start up.
* NB: Docs recommend not using the interrupt for completion.
- * Measurements indicate this should take no more than 20ms, so a
+ * Measurements indicate this should take no more than 20ms
+ * (assuming the GT clock is at maximum frequency). So, a
* timeout here indicates that the GuC has failed and is unusable.
* (Higher levels of the driver may decide to reset the GuC and
* attempt the ucode load again if this happens.)
+ *
+ * FIXME: There is a known (but exceedingly unlikely) race condition
+ * where the asynchronous frequency management code could reduce
+ * the GT clock while a GuC reload is in progress (during a full
+ * GT reset). A fix is in progress but there are complex locking
+ * issues to be resolved. In the meantime bump the timeout to
+ * 500ms. Even at slowest clock, this should be sufficient. And
+ * in the working case, a larger timeout makes no difference.
*/
- ret = wait_for(guc_ready(uncore, &status), 100);
+ ret = wait_for(guc_ready(uncore, &status), 500);
if (ret) {
struct drm_device *drm = &uncore->i915->drm;
--
2.25.1
next prev parent reply other threads:[~2021-12-21 0:52 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-12-21 0:52 [PATCH 0/3] Update to GuC version 69.0.3 John.C.Harrison
2021-12-21 0:52 ` John.C.Harrison [this message]
2021-12-21 1:13 ` [Intel-gfx] [PATCH 1/3] drm/i915/guc: Temporarily bump the GuC load timeout Matthew Brost
2021-12-21 0:52 ` [PATCH 2/3] drm/i915/guc: Update to GuC version 69.0.3 John.C.Harrison
2021-12-21 0:52 ` [PATCH 3/3] drm/i915/guc: Improve GuC loading status check/error reports John.C.Harrison
-- strict thread matches above, loose matches on Subject: below --
2021-12-21 20:28 [PATCH 0/3] Update to GuC version 69.0.3 John.C.Harrison
2021-12-21 20:29 ` [PATCH 1/3] drm/i915/guc: Temporarily bump the GuC load timeout John.C.Harrison
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=20211221005221.1090824-2-John.C.Harrison@Intel.com \
--to=john.c.harrison@intel.com \
--cc=DRI-Devel@Lists.FreeDesktop.Org \
--cc=Intel-GFX@Lists.FreeDesktop.Org \
/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