From: Imre Deak <imre.deak@intel.com>
To: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Cc: intel-xe@lists.freedesktop.org
Subject: Re: [PATCH 1/2] drm/xe/display: Match i915 driver suspend/resume sequences better
Date: Mon, 5 Aug 2024 21:43:27 +0300 [thread overview]
Message-ID: <ZrEdT1mxvBpeeRFe@ideak-desk.fi.intel.com> (raw)
In-Reply-To: <20240805151309.461021-2-maarten.lankhorst@linux.intel.com>
On Mon, Aug 05, 2024 at 05:13:08PM +0200, Maarten Lankhorst wrote:
> Suspend fbdev sooner, and disable user access before suspending to
> prevent some races. I've noticed this when comparing xe suspend to
> i915's.
This is only part of
24b412b1bfeb ("drm/i915: Disable intel HPD poll after DRM poll init/enable")
f4ed123ae295 ("drm/i915: Suspend the framebuffer console during driver shutdown")
1ef28d86bea9 ("drm/i915: Suspend the framebuffer console earlier during system suspend")
bd738d859e71 ("drm/i915: Prevent modesets during driver init/shutdown")
done for i915, imo all the above changes should be applied to xe.
> Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
> ---
> drivers/gpu/drm/xe/display/xe_display.c | 12 ++++++++----
> 1 file changed, 8 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/gpu/drm/xe/display/xe_display.c b/drivers/gpu/drm/xe/display/xe_display.c
> index ca4468c820788..44405f17c1d28 100644
> --- a/drivers/gpu/drm/xe/display/xe_display.c
> +++ b/drivers/gpu/drm/xe/display/xe_display.c
> @@ -294,8 +294,12 @@ void xe_display_pm_suspend(struct xe_device *xe, bool runtime)
> * properly.
> */
> intel_power_domains_disable(xe);
> - if (has_display(xe))
> + intel_fbdev_set_suspend(&xe->drm, FBINFO_STATE_SUSPENDED, true);
> +
> + if (has_display(xe)) {
> drm_kms_helper_poll_disable(&xe->drm);
> + intel_display_driver_disable_user_access(xe);
> + }
>
> if (!runtime)
> intel_display_driver_suspend(xe);
> @@ -308,8 +312,6 @@ void xe_display_pm_suspend(struct xe_device *xe, bool runtime)
>
> intel_opregion_suspend(xe, s2idle ? PCI_D1 : PCI_D3cold);
>
> - intel_fbdev_set_suspend(&xe->drm, FBINFO_STATE_SUSPENDED, true);
> -
> intel_dmc_suspend(xe);
> }
>
> @@ -353,8 +355,10 @@ void xe_display_pm_resume(struct xe_device *xe, bool runtime)
> intel_display_driver_resume(xe);
>
> intel_hpd_poll_disable(xe);
> - if (has_display(xe))
> + if (has_display(xe)) {
> drm_kms_helper_poll_enable(&xe->drm);
> + intel_display_driver_enable_user_access(xe);
> + }
>
> intel_opregion_resume(xe);
>
> --
> 2.45.2
>
next prev parent reply other threads:[~2024-08-05 18:43 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-08-05 15:13 [PATCH 0/2] drm/xe/display suspend/resume fixes Maarten Lankhorst
2024-08-05 15:13 ` [PATCH 1/2] drm/xe/display: Match i915 driver suspend/resume sequences better Maarten Lankhorst
2024-08-05 18:43 ` Imre Deak [this message]
2024-08-06 7:44 ` Jani Nikula
2024-08-06 13:17 ` Imre Deak
2024-08-05 15:13 ` [PATCH 2/2] drm/xe/display: Make display suspend/resume work on discrete Maarten Lankhorst
2024-08-05 15:48 ` ✓ CI.Patch_applied: success for drm/xe/display suspend/resume fixes Patchwork
2024-08-05 15:48 ` ✓ CI.checkpatch: " Patchwork
2024-08-05 15:49 ` ✓ CI.KUnit: " Patchwork
2024-08-05 16:01 ` ✓ CI.Build: " Patchwork
2024-08-05 16:03 ` ✓ CI.Hooks: " Patchwork
2024-08-05 16:05 ` ✓ CI.checksparse: " Patchwork
2024-08-05 16:24 ` ✓ CI.BAT: " Patchwork
2024-08-05 16:59 ` [PATCH 0/2] " Jani Nikula
2024-08-05 18:03 ` ✗ CI.FULL: failure for " 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=ZrEdT1mxvBpeeRFe@ideak-desk.fi.intel.com \
--to=imre.deak@intel.com \
--cc=intel-xe@lists.freedesktop.org \
--cc=maarten.lankhorst@linux.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.