All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2 1/28] drm/amdgpu: fix that issue that the number of the crtc of the 3250c is not correct
@ 2022-01-28  3:47 RyanLin
  2022-01-28 14:40 ` Deucher, Alexander
  0 siblings, 1 reply; 2+ messages in thread
From: RyanLin @ 2022-01-28  3:47 UTC (permalink / raw)
  To: harry.wentland, sunpeng.li, alexander.deucher, christian.koenig,
	David1.Zhou, airlied, daniel, seanpaul, bas, nicholas.kazlauskas,
	sashal, markyacoub, victorchengchi.lu, ching-shih.li,
	Rodrigo.Siqueira, ddavenport, amd-gfx, dri-devel, linux-kernel,
	leon.li
  Cc: RyanLin

v2:
  - remove unnecessary comments and Id

[Why]
External displays take priority over internal display when there are fewer 
display controllers than displays.

[How]
The root cause is because of that number of the crtc is not correct.
The number of the crtc on the 3250c is 3, but on the 3500c is 4.
From the source code, we can see that number of the crtc has been fixed at 4.
Needs to set the num_crtc to 3 for 3250c platform.

Signed-off-by: RyanLin <Tsung-Hua.Lin@amd.com>

---
 drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 12 +++++++++---
 1 file changed, 9 insertions(+), 3 deletions(-)

diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
index 40c91b448f7d..455a2c45e8cd 100644
--- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
+++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
@@ -2738,9 +2738,15 @@ static int dm_early_init(void *handle)
 		break;
 #if defined(CONFIG_DRM_AMD_DC_DCN1_0)
 	case CHIP_RAVEN:
-		adev->mode_info.num_crtc = 4;
-		adev->mode_info.num_hpd = 4;
-		adev->mode_info.num_dig = 4;
+		if (adev->rev_id >= 8) {
+			adev->mode_info.num_crtc = 3;
+			adev->mode_info.num_hpd = 3;
+			adev->mode_info.num_dig = 3;
+		} else {
+			adev->mode_info.num_crtc = 4;
+			adev->mode_info.num_hpd = 4;
+			adev->mode_info.num_dig = 4;
+		}
 		break;
 #endif
 #if defined(CONFIG_DRM_AMD_DC_DCN2_0)
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH v2 1/28] drm/amdgpu: fix that issue that the number of the crtc of the 3250c is not correct
  2022-01-28  3:47 [PATCH v2 1/28] drm/amdgpu: fix that issue that the number of the crtc of the 3250c is not correct RyanLin
@ 2022-01-28 14:40 ` Deucher, Alexander
  0 siblings, 0 replies; 2+ messages in thread
From: Deucher, Alexander @ 2022-01-28 14:40 UTC (permalink / raw)
  To: Lin, Tsung-hua (Ryan), Wentland, Harry, Li, Sun peng (Leo),
	Koenig,  Christian, David1.Zhou, airlied, daniel, seanpaul, bas,
	Kazlauskas, Nicholas, sashal, markyacoub, victorchengchi.lu,
	ching-shih.li, Siqueira, Rodrigo, ddavenport, amd-gfx, dri-devel,
	linux-kernel, Li, Leon

[-- Attachment #1: Type: text/plain, Size: 3022 bytes --]

[Public]

Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
________________________________
From: RyanLin <Tsung-Hua.Lin@amd.com>
Sent: Thursday, January 27, 2022 10:47 PM
To: Wentland, Harry <Harry.Wentland@amd.com>; Li, Sun peng (Leo) <Sunpeng.Li@amd.com>; Deucher, Alexander <Alexander.Deucher@amd.com>; Koenig, Christian <Christian.Koenig@amd.com>; David1.Zhou@amd.com <David1.Zhou@amd.com>; airlied@linux.ie <airlied@linux.ie>; daniel@ffwll.ch <daniel@ffwll.ch>; seanpaul@chromium.org <seanpaul@chromium.org>; bas@basnieuwenhuizen.nl <bas@basnieuwenhuizen.nl>; Kazlauskas, Nicholas <Nicholas.Kazlauskas@amd.com>; sashal@kernel.org <sashal@kernel.org>; markyacoub@google.com <markyacoub@google.com>; victorchengchi.lu@amd.com <victorchengchi.lu@amd.com>; ching-shih.li@amd.corp-partner.google.com <ching-shih.li@amd.corp-partner.google.com>; Siqueira, Rodrigo <Rodrigo.Siqueira@amd.com>; ddavenport@chromium.org <ddavenport@chromium.org>; amd-gfx@lists.freedesktop.org <amd-gfx@lists.freedesktop.org>; dri-devel@lists.freedesktop.org <dri-devel@lists.freedesktop.org>; linux-kernel@vger.kernel.org <linux-kernel@vger.kernel.org>; Li, Leon <Leon.Li@amd.com>
Cc: Lin, Tsung-hua (Ryan) <Tsung-hua.Lin@amd.com>
Subject: [PATCH v2 1/28] drm/amdgpu: fix that issue that the number of the crtc of the 3250c is not correct

v2:
  - remove unnecessary comments and Id

[Why]
External displays take priority over internal display when there are fewer
display controllers than displays.

[How]
The root cause is because of that number of the crtc is not correct.
The number of the crtc on the 3250c is 3, but on the 3500c is 4.
From the source code, we can see that number of the crtc has been fixed at 4.
Needs to set the num_crtc to 3 for 3250c platform.

Signed-off-by: RyanLin <Tsung-Hua.Lin@amd.com>

---
 drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 12 +++++++++---
 1 file changed, 9 insertions(+), 3 deletions(-)

diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
index 40c91b448f7d..455a2c45e8cd 100644
--- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
+++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
@@ -2738,9 +2738,15 @@ static int dm_early_init(void *handle)
                 break;
 #if defined(CONFIG_DRM_AMD_DC_DCN1_0)
         case CHIP_RAVEN:
-               adev->mode_info.num_crtc = 4;
-               adev->mode_info.num_hpd = 4;
-               adev->mode_info.num_dig = 4;
+               if (adev->rev_id >= 8) {
+                       adev->mode_info.num_crtc = 3;
+                       adev->mode_info.num_hpd = 3;
+                       adev->mode_info.num_dig = 3;
+               } else {
+                       adev->mode_info.num_crtc = 4;
+                       adev->mode_info.num_hpd = 4;
+                       adev->mode_info.num_dig = 4;
+               }
                 break;
 #endif
 #if defined(CONFIG_DRM_AMD_DC_DCN2_0)
--
2.25.1


[-- Attachment #2: Type: text/html, Size: 5523 bytes --]

^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2022-01-28 14:40 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-01-28  3:47 [PATCH v2 1/28] drm/amdgpu: fix that issue that the number of the crtc of the 3250c is not correct RyanLin
2022-01-28 14:40 ` Deucher, Alexander

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.