From: Jani Nikula <jani.nikula@linux.intel.com>
To: Chris Wilson <chris@chris-wilson.co.uk>, intel-gfx@lists.freedesktop.org
Cc: janusz.krzysztofik@intel.com
Subject: Re: [PATCH 2/2] drm/i915: Disable active links before rebooting
Date: Thu, 16 May 2019 13:13:53 +0300 [thread overview]
Message-ID: <87d0kiaeqm.fsf@intel.com> (raw)
In-Reply-To: <20190515150042.8409-3-chris@chris-wilson.co.uk>
On Wed, 15 May 2019, Chris Wilson <chris@chris-wilson.co.uk> wrote:
> Certain monitors, e.g. Dell, do not like it when we reboot with an
> active link, leaving them in a confused state where they refuse to
> renegotiate the link after the reboot. If we hook into the reboot
> notifier, we can switch off any active link before rebooting, leaving
> everything in a consistent, hopefully happy, state.
>
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
> ---
> drivers/gpu/drm/i915/i915_pci.c | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/drivers/gpu/drm/i915/i915_pci.c b/drivers/gpu/drm/i915/i915_pci.c
> index 401eb6c71ae1..7b2dc8d66f35 100644
> --- a/drivers/gpu/drm/i915/i915_pci.c
> +++ b/drivers/gpu/drm/i915/i915_pci.c
> @@ -26,6 +26,7 @@
> #include <linux/vgaarb.h>
> #include <linux/vga_switcheroo.h>
>
> +#include <drm/drm_atomic_helper.h>
> #include <drm/drm_drv.h>
>
> #include "i915_drv.h"
> @@ -909,6 +910,9 @@ static void i915_pci_shutdown(struct pci_dev *pdev)
> /* Cancel any outstanding rendering */
> if (READ_ONCE(i915->gt.awake))
> i915_gem_set_wedged(i915);
> +
> + /* Disable active links to avoid confusing certain (Dell) monitors */
> + drm_atomic_helper_shutdown(&i915->drm);
I think we could use this to replace edp_notify_handler(). But the above
alone is not enough because it won't do the wait, as we do the waits in
enable, and after boot we've lost track of when the last disable was.
BR,
Jani.
> }
>
> static struct pci_driver i915_pci_driver = {
--
Jani Nikula, Intel Open Source Graphics Center
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2019-05-16 10:10 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-05-15 15:00 Shutdown hooks Chris Wilson
2019-05-15 15:00 ` [PATCH 1/2] drm/i915: Hook into the reboot notifier to cancel outstanding GPU operations Chris Wilson
2019-05-15 15:00 ` [PATCH 2/2] drm/i915: Disable active links before rebooting Chris Wilson
2019-05-16 10:13 ` Jani Nikula [this message]
2019-05-15 15:27 ` ✓ Fi.CI.BAT: success for series starting with [1/2] drm/i915: Hook into the reboot notifier to cancel outstanding GPU operations Patchwork
2019-05-15 20:42 ` ✓ Fi.CI.IGT: " Patchwork
2019-05-16 6:20 ` Shutdown hooks Krzysztofik, Janusz
2019-05-17 8:04 ` Janusz Krzysztofik
2019-05-17 8:56 ` Chris Wilson
-- strict thread matches above, loose matches on Subject: below --
2018-11-25 17:24 [PATCH 1/2] drm/i915: Hook into the reboot notifier to cancel outstanding GPU operations Chris Wilson
2018-11-25 17:24 ` [PATCH 2/2] drm/i915: Disable active links before rebooting Chris Wilson
2018-11-26 12:55 ` Jani Nikula
2018-11-27 13:07 ` Ville Syrjälä
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=87d0kiaeqm.fsf@intel.com \
--to=jani.nikula@linux.intel.com \
--cc=chris@chris-wilson.co.uk \
--cc=intel-gfx@lists.freedesktop.org \
--cc=janusz.krzysztofik@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