From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 62CA0334C01; Thu, 27 Nov 2025 15:01:10 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1764255670; cv=none; b=oVQtw8w2tDPDG2qmFAdBJ59SnMoNKsZGh+8/65bKv9S/Ly1CDI6ZvH4owUrCPwiKF4bIcEZlUGAiL2FbxDfKbUmE/gN48Jd0YEgyzqp/tTfa/kJFz555iEnkOmZeMzzPgK3bipbswCZu834jakaXomxty6txAU3oTtvYyFCeBFM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1764255670; c=relaxed/simple; bh=wAFmsnRrFxy2TGQmmDylO6AcVQ+M6RCE+DSsAOA0ObY=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=MmEDh9D74inHIaLxi/K6djco3zHXxTuPRN1gTL0i2xV8LyK+0zKvnovUgqUFvorDdxhkxPIJDa4kHph0MaOYN+0n2fPLrykxP9SriFED+juSAaaBSK6GPT0JKO4nTZMjaZz9AV2UhmaP9gMimE0DUnXFjuI0a9phnwO8F3kyo9k= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=Msw1RhSH; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="Msw1RhSH" Received: by smtp.kernel.org (Postfix) with ESMTPSA id E4356C116C6; Thu, 27 Nov 2025 15:01:09 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1764255670; bh=wAFmsnRrFxy2TGQmmDylO6AcVQ+M6RCE+DSsAOA0ObY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Msw1RhSHAH1PMZYiCiL8l16HnsHzAFQa6JQr0dq415IZy8oPZHHqLEoPQld8w3pik yyotsyEqJgjjnbic3q5PFRBhYnP/aO2h5bRo2wMxjrTHshYoI02uwC91brdJGpgS2g d6xe1MQzdCNjKrSDllKIOThGgDRmPlWXMprwlxEU= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Alex Hung , "Mario Limonciello (AMD)" , Ivan Lipski , Dan Wheeler , Alex Deucher Subject: [PATCH 6.17 074/175] drm/amd/display: Move sleep into each retry for retrieve_link_cap() Date: Thu, 27 Nov 2025 15:45:27 +0100 Message-ID: <20251127144045.668768554@linuxfoundation.org> X-Mailer: git-send-email 2.52.0 In-Reply-To: <20251127144042.945669935@linuxfoundation.org> References: <20251127144042.945669935@linuxfoundation.org> User-Agent: quilt/0.69 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: patches@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 6.17-stable review patch. If anyone has any objections, please let me know. ------------------ From: Mario Limonciello (AMD) commit 71ad9054c1f241be63f9d11df8cbd0aa0352fe16 upstream. [Why] When a monitor is booting it's possible that it isn't ready to retrieve link caps and this can lead to an EDID read failure: ``` [drm:retrieve_link_cap [amdgpu]] *ERROR* retrieve_link_cap: Read receiver caps dpcd data failed. amdgpu 0000:c5:00.0: [drm] *ERROR* No EDID read. ``` [How] Rather than msleep once and try a few times, msleep each time. Should be no changes for existing working monitors, but should correct reading caps on a monitor that is slow to boot. Closes: https://gitlab.freedesktop.org/drm/amd/-/issues/4672 Reviewed-by: Alex Hung Signed-off-by: Mario Limonciello (AMD) Signed-off-by: Ivan Lipski Tested-by: Dan Wheeler Signed-off-by: Alex Deucher (cherry picked from commit 669dca37b3348a447db04bbdcbb3def94d5997cc) Cc: stable@vger.kernel.org Signed-off-by: Greg Kroah-Hartman --- drivers/gpu/drm/amd/display/dc/link/protocols/link_dp_capability.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) --- a/drivers/gpu/drm/amd/display/dc/link/protocols/link_dp_capability.c +++ b/drivers/gpu/drm/amd/display/dc/link/protocols/link_dp_capability.c @@ -1734,12 +1734,13 @@ static bool retrieve_link_cap(struct dc_ } dpcd_set_source_specific_data(link); - /* Sink may need to configure internals based on vendor, so allow some - * time before proceeding with possibly vendor specific transactions - */ - msleep(post_oui_delay); for (i = 0; i < read_dpcd_retry_cnt; i++) { + /* + * Sink may need to configure internals based on vendor, so allow some + * time before proceeding with possibly vendor specific transactions + */ + msleep(post_oui_delay); status = core_link_read_dpcd( link, DP_DPCD_REV,