AMD-GFX Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: "Mario Limonciello (AMD)" <superm1@kernel.org>
To: mario.limonciello@amd.com, airlied@gmail.com,
	alexander.deucher@amd.com, christian.koenig@amd.com,
	dakr@kernel.org, gregkh@linuxfoundation.org, lenb@kernel.org,
	pavel@kernel.org, rafael@kernel.org, simona@ffwll.ch
Cc: amd-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org,
	linux-pm@vger.kernel.org
Subject: [RFC PATCH 2/3] drm/amd: Drop special cases for thaw() callback
Date: Mon, 13 Oct 2025 12:47:10 -0500	[thread overview]
Message-ID: <20251013174729.1101186-3-superm1@kernel.org> (raw)
In-Reply-To: <20251013174729.1101186-1-superm1@kernel.org>

From: Mario Limonciello <mario.limonciello@amd.com>

The special cases to use pm_hibernate_is_recovering() and
pm_hibernation_mode_is_suspend() were for an optimization to avoid
turning the display on and moving memory around when the system
was about to hibernate anyway.

As the hibernate core skips thaw() unless it's necessary drop them.

Signed-off-by: Mario Limonciello <mario.limonciello@amd.com>
---
 drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 4 ----
 1 file changed, 4 deletions(-)

diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c
index 6d547f4e4bafc..4a37c3e517a9f 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c
@@ -2671,10 +2671,6 @@ static int amdgpu_pmops_thaw(struct device *dev)
 {
 	struct drm_device *drm_dev = dev_get_drvdata(dev);
 
-	/* do not resume device if it's normal hibernation */
-	if (!pm_hibernate_is_recovering() && !pm_hibernation_mode_is_suspend())
-		return 0;
-
 	return amdgpu_device_resume(drm_dev, true);
 }
 
-- 
2.43.0


  parent reply	other threads:[~2025-10-13 17:54 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-10-13 17:47 [RFC PATCH 0/3] Skip thaw sequence for all devices, not just amdgpu Mario Limonciello (AMD)
2025-10-13 17:47 ` [RFC PATCH 1/3] PM: hibernate: Nominally skip thaw sequence for all devices Mario Limonciello (AMD)
2025-10-13 17:58   ` Rafael J. Wysocki
2025-10-13 18:27     ` Mario Limonciello
2025-10-13 18:29       ` Rafael J. Wysocki
2025-10-13 17:47 ` Mario Limonciello (AMD) [this message]
2025-10-13 17:47 ` [RFC PATCH 3/3] PM: Drop pm_hibernate_is_recovering() and pm_hibernation_mode_is_suspend() Mario Limonciello (AMD)

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=20251013174729.1101186-3-superm1@kernel.org \
    --to=superm1@kernel.org \
    --cc=airlied@gmail.com \
    --cc=alexander.deucher@amd.com \
    --cc=amd-gfx@lists.freedesktop.org \
    --cc=christian.koenig@amd.com \
    --cc=dakr@kernel.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=lenb@kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=mario.limonciello@amd.com \
    --cc=pavel@kernel.org \
    --cc=rafael@kernel.org \
    --cc=simona@ffwll.ch \
    /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