[PATCH] drm/i915/display: Fix the PIPE_MISC 12 BPC PORT_OUTPUT for DG2

Ankit Nautiyal ankit.k.nautiyal at intel.com
Fri Aug 20 09:57:44 UTC 2021


Currently 12 BPC PORT_OUTPUT_BPC bits are set in PIPE_MISC register
for all Display > 12. DG2 is an exception.
This patch tweaks the condition to read and write the above bits
for DG2.

Signed-off-by: Ankit Nautiyal <ankit.k.nautiyal at intel.com>
---
 drivers/gpu/drm/i915/display/intel_display.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/gpu/drm/i915/display/intel_display.c b/drivers/gpu/drm/i915/display/intel_display.c
index 134a6acbd8fb..943c65782f7a 100644
--- a/drivers/gpu/drm/i915/display/intel_display.c
+++ b/drivers/gpu/drm/i915/display/intel_display.c
@@ -5850,8 +5850,8 @@ static void bdw_set_pipemisc(const struct intel_crtc_state *crtc_state)
 		val |= PIPEMISC_10_BPC;
 		break;
 	case 36:
-		/* Port output 12BPC defined for ADLP+ */
-		if (DISPLAY_VER(dev_priv) > 12)
+		/* Port output 12BPC defined for ADLP+ except for DG2 */
+		if (DISPLAY_VER(dev_priv) > 12 && !IS_DG2(dev_priv))
 			val |= PIPEMISC_12_BPC_ADLP;
 		break;
 	default:
@@ -5913,7 +5913,7 @@ int bdw_get_pipemisc_bpp(struct intel_crtc *crtc)
 	case PIPEMISC_10_BPC:
 		return 30;
 	/*
-	 * PORT OUTPUT 12 BPC defined for ADLP+.
+	 * PORT OUTPUT 12 BPC defined for ADLP+ (except DG2)
 	 *
 	 * TODO:
 	 * For previous platforms with DSI interface, bits 5:7
@@ -5923,7 +5923,7 @@ int bdw_get_pipemisc_bpp(struct intel_crtc *crtc)
 	 * MIPI DSI HW readout.
 	 */
 	case PIPEMISC_12_BPC_ADLP:
-		if (DISPLAY_VER(dev_priv) > 12)
+		if (DISPLAY_VER(dev_priv) > 12 && !IS_DG2(dev_priv))
 			return 36;
 		fallthrough;
 	default:
-- 
2.25.1



More information about the Intel-gfx-trybot mailing list