mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Marek Vasut <marex@nabladev.com>
To: "Uwe Kleine-König" <ukleinek@debian.org>,
	dri-devel@lists.freedesktop.org
Cc: Danilo Krummrich <dakr@kernel.org>,
	David Airlie <airlied@gmail.com>, Li Chen <me@linux.beauty>,
	Lyude Paul <lyude@redhat.com>,
	Maarten Lankhorst <maarten.lankhorst@linux.intel.com>,
	Maxime Ripard <mripard@kernel.org>,
	Ole Carlsen <ole.carlsen@tutamail.com>,
	Simona Vetter <simona@ffwll.ch>,
	Thomas Zimmermann <tzimmermann@suse.de>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] Revert "nouveau: pci: quiesce GPU on shutdown"
Date: Sat, 14 Nov 2026 17:37:55 +0100	[thread overview]
Message-ID: <293083d1-1085-40a7-9d6d-1776ed649238@nabladev.com> (raw)
In-Reply-To: <aviIPk4xbKhgqcTy@monoceros>

On 11/14/26 5:20 PM, Uwe Kleine-König wrote:

[...]

>> -static void
>> -nouveau_drm_shutdown(struct pci_dev *pdev)
>> -{
>> -	struct nouveau_drm *drm = pci_get_drvdata(pdev);
>> -	int ret;
>> -
>> -	if (!drm)
>> -		return;
>> -
>> -	if (drm->dev->switch_power_state == DRM_SWITCH_POWER_OFF ||
>> -	    drm->dev->switch_power_state == DRM_SWITCH_POWER_DYNAMIC_OFF)
>> -		return;
>> -
>> -	ret = nouveau_do_suspend(drm, false);
>> -	if (ret)
>> -		NV_ERROR(drm, "shutdown suspend failed with: %d\n", ret);
>> -
>> -	pci_save_state(pdev);
>> -	pci_disable_device(pdev);
>> -	pci_set_power_state(pdev, PCI_D3hot);
>> -	/*
>> -	 *  This is just to give the pci power transition time to settle
>> -	 *  before an immediate kexec jump. it’s mirroring the existing
>> -	 *  nouveau_pmops_suspend() behavior, which already does
>> -	 *  udelay(200) right after pci_set_power_state(..., pci_d3hot). In
>> -	 *  ->shutdown() we’re allowed to sleep, so I used usleep_range()
>> -	 *  instead of a busy-wait udelay().
>> -	 */
>> -	usleep_range(200, 400);
>> -}
>> -
> 
> I cannot reproduce it

I can surely reproduce it, because since Linux 7.1 I cannot shut down my 
computer, something which worked since the beginning.

> , but maybe it's helpful to find out where/how the
> driver hangs. Adding printks might be enough, and if not, remove stuff
> from nouveau_drm_shutdown() until it works.

The laptop screen goes off, the machine is unresponsive this late during 
shutdown, so adding printks() does not help.

> I'd guess this gives the
> needed insights to determine a fix without reverting the identified
> commit.
The problematic commit should be reverted and reworked, since it breaks 
existing users. I am open to testing patches on that machine.

      reply	other threads:[~2026-11-16  1:20 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-25 21:30 Marek Vasut
2026-11-14 16:20 ` Uwe Kleine-König
2026-11-14 16:37   ` Marek Vasut [this message]

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=293083d1-1085-40a7-9d6d-1776ed649238@nabladev.com \
    --to=marex@nabladev.com \
    --cc=airlied@gmail.com \
    --cc=dakr@kernel.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lyude@redhat.com \
    --cc=maarten.lankhorst@linux.intel.com \
    --cc=me@linux.beauty \
    --cc=mripard@kernel.org \
    --cc=ole.carlsen@tutamail.com \
    --cc=simona@ffwll.ch \
    --cc=tzimmermann@suse.de \
    --cc=ukleinek@debian.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

all inboxes | Powered by JetHome®