From: Imre Deak <imre.deak@intel.com>
To: intel-gfx@lists.freedesktop.org
Subject: [Intel-gfx] [PATCH 4/4] drm/i915: Prevent needless toggling of DC states during modesets
Date: Fri, 16 Jun 2023 21:51:04 +0300 [thread overview]
Message-ID: <20230616185104.2502003-4-imre.deak@intel.com> (raw)
In-Reply-To: <20230616185104.2502003-1-imre.deak@intel.com>
DC states are disabled / re-enabled around each modeset, which may lead
to a needless off->on->off toggling of the DC_off power well. This has
some overhead as toggling DC states involves running a DMC firmware
handler and also running a periodic firmware handler while DC states are
enabled. The limit of when DC states have a benefit is at 30 FPS (using
DC3co) and below 30 FPS (using DC5/6), where the firmware can actually
disable clocks / power off power wells. Accordingly delay powering off
the DC_off powerwell (which re-enables DC states) by 17 ms at the end of
a modeset to avoid the above overhead at or above 60 FPS.
Signed-off-by: Imre Deak <imre.deak@intel.com>
---
drivers/gpu/drm/i915/display/intel_display.c | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/i915/display/intel_display.c b/drivers/gpu/drm/i915/display/intel_display.c
index dd52c689267f4..de77d130d6f9f 100644
--- a/drivers/gpu/drm/i915/display/intel_display.c
+++ b/drivers/gpu/drm/i915/display/intel_display.c
@@ -7148,7 +7148,11 @@ static void intel_atomic_commit_tail(struct intel_atomic_state *state)
*/
intel_uncore_arm_unclaimed_mmio_detection(&dev_priv->uncore);
}
- intel_display_power_put(dev_priv, POWER_DOMAIN_DC_OFF, wakeref);
+ /*
+ * Delay re-enabling DC states by 17 ms to avoid the off->on->off
+ * toggling overhead at and above 60 FPS.
+ */
+ intel_display_power_put_async_delay(dev_priv, POWER_DOMAIN_DC_OFF, wakeref, 17);
intel_runtime_pm_put(&dev_priv->runtime_pm, state->wakeref);
/*
--
2.37.2
next prev parent reply other threads:[~2023-06-16 18:51 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-06-16 18:51 [Intel-gfx] [PATCH 1/4] drm/i915: Add missing forward declarations/includes to display power headers Imre Deak
2023-06-16 18:51 ` [Intel-gfx] [PATCH 2/4] drm/i915: Remove redundant forward declarations from " Imre Deak
2023-06-16 18:51 ` [Intel-gfx] [PATCH 3/4] drm/i915: Add way to specify the power-off delay of a display power domain Imre Deak
2023-06-16 18:51 ` Imre Deak [this message]
2023-06-22 9:38 ` [Intel-gfx] [PATCH 4/4] drm/i915: Prevent needless toggling of DC states during modesets Hogander, Jouni
2023-06-22 12:05 ` Imre Deak
2023-06-22 12:25 ` Hogander, Jouni
2023-06-16 19:35 ` [Intel-gfx] ✗ Fi.CI.CHECKPATCH: warning for series starting with [1/4] drm/i915: Add missing forward declarations/includes to display power headers Patchwork
2023-06-16 19:36 ` [Intel-gfx] ✗ Fi.CI.SPARSE: " Patchwork
2023-06-17 0:44 ` [Intel-gfx] [PATCH 1/4] " Randy Dunlap
2023-06-17 5:57 ` [Intel-gfx] ✓ Fi.CI.BAT: success for series starting with [1/4] " Patchwork
2023-06-17 13:10 ` [Intel-gfx] ✗ Fi.CI.IGT: failure " Patchwork
2023-06-19 10:48 ` Imre Deak
2023-06-22 17:21 ` [Intel-gfx] ✗ Fi.CI.CHECKPATCH: warning for series starting with [1/4] drm/i915: Add missing forward declarations/includes to display power headers (rev2) Patchwork
2023-06-22 17:21 ` [Intel-gfx] ✗ Fi.CI.SPARSE: " Patchwork
2023-06-22 17:35 ` [Intel-gfx] ✗ Fi.CI.BAT: failure " Patchwork
2023-06-22 17:57 ` Imre Deak
2023-06-26 11:30 ` Imre Deak
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=20230616185104.2502003-4-imre.deak@intel.com \
--to=imre.deak@intel.com \
--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