All of lore.kernel.org
 help / color / mirror / Atom feed
From: Petr Belyaev <upcfrost@gmail.com>
To: amd-gfx@lists.freedesktop.org
Cc: alexander.deucher@amd.com, timur.kristof@gmail.com,
	Petr Belyaev <upcfrost@gmail.com>
Subject: [PATCH] drm/amd/pm/smu7: Don't send VddC_Request on CI
Date: Mon, 24 Aug 2026 16:47:14 +0200	[thread overview]
Message-ID: <20260824144714.182835-1-upcfrost@gmail.com> (raw)

smu7_upload_dpm_level_enable_mask() calls
smu7_apply_minimum_dce_voltage_request() unconditionally, which sends
PPSMC_MSG_VddC_Request to the SMC. CI SMC firmware does not implement
that message: it is only defined in smu7_ppsmc.h, tonga_ppsmc.h and
fiji_ppsmc.h, and there is no CI equivalent. The SMC therefore never
writes SMC_RESP, PHM_WAIT_FIELD_UNEQUAL() spins until it gives up, and
every call burns the full ~1.9s response timeout.

Nothing downstream notices, because ci_send_msg_to_smc() returns 0
regardless of the outcome. The only effects are the delay and

  amdgpu: failed to send message 15f ret is 0

in dmesg. On a Radeon R7 260X (BONAIRE, 1002:6658) this is 40 messages
per boot: 32 during the boot-time modeset, which becomes ~59s of blank
screen, and 8 more on every DPMS wake, adding ~15s before the display
comes back.

Commit 0138610c1413 ("drm/amd/pm/smu7: Fix SMU7 voltage dependency on
display clock") extended this feature to CI, which the previous
implementation had deliberately excluded -- the old call site was
guarded by pp_table_version == PP_TABLE_V1 with an adjacent comment
reading "TO DO for v0 iceland and Ci". That commit was verified on a
Radeon R9 M380, which is VI, so the CI path went untested.

Restore the PP_TABLE_V1 condition. With it back the failed messages
disappear entirely and both the boot modeset and the monitor wake are
immediate.

Fixes: 0138610c1413 ("drm/amd/pm/smu7: Fix SMU7 voltage dependency on display clock")
Link: https://gitlab.freedesktop.org/drm/amd/-/work_items/5678
Cc: stable@vger.kernel.org
Signed-off-by: Petr Belyaev <upcfrost@gmail.com>
---
 drivers/gpu/drm/amd/pm/powerplay/hwmgr/smu7_hwmgr.c | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/amd/pm/powerplay/hwmgr/smu7_hwmgr.c b/drivers/gpu/drm/amd/pm/powerplay/hwmgr/smu7_hwmgr.c
index 6529a91..aadf6d5 100644
--- a/drivers/gpu/drm/amd/pm/powerplay/hwmgr/smu7_hwmgr.c
+++ b/drivers/gpu/drm/amd/pm/powerplay/hwmgr/smu7_hwmgr.c
@@ -3189,7 +3189,11 @@ static int smu7_upload_dpm_level_enable_mask(struct pp_hwmgr *hwmgr)
 {
 	struct smu7_hwmgr *data = (struct smu7_hwmgr *)(hwmgr->backend);
 
-	smu7_apply_minimum_dce_voltage_request(hwmgr);
+	/* CI SMC firmware does not implement PPSMC_MSG_VddC_Request, and each
+	 * attempt costs a full SMC response timeout.
+	 */
+	if (hwmgr->pp_table_version == PP_TABLE_V1)
+		smu7_apply_minimum_dce_voltage_request(hwmgr);
 
 	if (!data->sclk_dpm_key_disabled) {
 		if (data->dpm_level_enable_mask.sclk_dpm_enable_mask)
-- 
2.54.0
:wqa

             reply	other threads:[~2026-08-24 15:22 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-08-24 14:47 Petr Belyaev [this message]
2026-08-24 15:07 ` [PATCH] drm/amd/pm/smu7: Don't send VddC_Request on CI Timur Kristóf
2026-08-24 16:11   ` Petr Belyaev
2026-08-24 19:54     ` Timur Kristóf

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=20260824144714.182835-1-upcfrost@gmail.com \
    --to=upcfrost@gmail.com \
    --cc=alexander.deucher@amd.com \
    --cc=amd-gfx@lists.freedesktop.org \
    --cc=timur.kristof@gmail.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.