]> www.infradead.org Git - users/dwmw2/linux.git/commitdiff
drm/amd: Avoid ASSERT for some message failures
authorMario Limonciello <mario.limonciello@amd.com>
Wed, 11 Jan 2023 21:52:31 +0000 (15:52 -0600)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 10 Mar 2023 08:33:56 +0000 (09:33 +0100)
[ Upstream commit 3e5019ee67760cd61b2a5fd605e1289c2f92d983 ]

On DCN314 when resuming from s0i3 an ASSERT is shown indicating that
`VBIOSSMC_MSG_SetHardMinDcfclkByFreq` returned `VBIOSSMC_Result_Failed`.

This isn't a driver bug; it's a BIOS/configuration bug. To make this
easier to triage, add an explicit warning when this issue happens.

This matches the behavior utilized for failures with
`VBIOSSMC_MSG_TransferTableDram2Smu` configuration.

Signed-off-by: Mario Limonciello <mario.limonciello@amd.com>
Reviewed-by: Harry Wentland <harry.wentland@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/gpu/drm/amd/display/dc/clk_mgr/dcn314/dcn314_smu.c

index 2db595672a469da3c760602532b1b8f53ac1719e..aa264c600408d52b7ba0a43c2ffbf5115e3501bb 100644 (file)
@@ -146,6 +146,9 @@ static int dcn314_smu_send_msg_with_param(struct clk_mgr_internal *clk_mgr,
                if (msg_id == VBIOSSMC_MSG_TransferTableDram2Smu &&
                    param == TABLE_WATERMARKS)
                        DC_LOG_WARNING("Watermarks table not configured properly by SMU");
+               else if (msg_id == VBIOSSMC_MSG_SetHardMinDcfclkByFreq ||
+                        msg_id == VBIOSSMC_MSG_SetMinDeepSleepDcfclk)
+                       DC_LOG_WARNING("DCFCLK_DPM is not enabled by BIOS");
                else
                        ASSERT(0);
                REG_WRITE(MP1_SMN_C2PMSG_91, VBIOSSMC_Result_OK);