Skip to contentSkip to conversation

drm/i915: Handle DSI case for DDI PLL

PATCH In review Vidya Srinivas 2 participants 3 messages Jan 9, 2017 – Feb 8, 2017

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 2/14 drm/i915: Handle DSI case for DDI PLL

From: Uma Shankar <[email protected]>

In case of DSI, DDI PLL is not required.
Handle the same as part of DDI PLL handling.

---
 drivers/gpu/drm/i915/intel_ddi.c | 24 +++++++++++++++++-------
 1 file changed, 17 insertions(+), 7 deletions(-)
 mode change 100644 => 100755 drivers/gpu/drm/i915/intel_ddi.c
drivers/gpu/drm/i915/intel_ddi.c +17 -7
old mode 100644
new mode 100755
index 66b367d..16137ef
@@ -1102,13 +1102,13 @@ void intel_ddi_clock_get(struct intel_encoder *encoder,
 {
 	struct intel_shared_dpll *pll;
 
-	pll = intel_get_shared_dpll(intel_crtc, crtc_state,
-				    intel_encoder);
-	if (!pll)
+	pll = intel_get_shared_dpll(intel_crtc, crtc_state, intel_encoder);
+	if (pll == NULL) {
 		DRM_DEBUG_DRIVER("failed to find PLL for pipe %c\n",
 				 pipe_name(intel_crtc->pipe));
-
-	return pll;
+		return false;
+	}
+	return true;
 }
 
 static bool
@@ -1124,7 +1124,6 @@ void intel_ddi_clock_get(struct intel_encoder *encoder,
 				 pipe_name(intel_crtc->pipe));
 		return false;
 	}
-
 	return true;
 }
 
@@ -1133,7 +1132,15 @@ void intel_ddi_clock_get(struct intel_encoder *encoder,
 		   struct intel_crtc_state *crtc_state,
 		   struct intel_encoder *intel_encoder)
 {
-	return !!intel_get_shared_dpll(intel_crtc, crtc_state, intel_encoder);
+	struct intel_shared_dpll *pll;
+
+	pll = intel_get_shared_dpll(intel_crtc, crtc_state, intel_encoder);
+	if (pll == NULL) {
+		DRM_DEBUG_DRIVER("failed to find PLL for pipe %c\n",
+				 pipe_name(intel_crtc->pipe));
+		return false;
+	}
+	return true;
 }
 
 /*
@@ -1150,6 +1157,9 @@ bool intel_ddi_pll_select(struct intel_crtc *intel_crtc,
 	struct intel_encoder *intel_encoder =
 		intel_ddi_get_crtc_new_encoder(crtc_state);
 
+	if (intel_encoder->type == INTEL_OUTPUT_DSI)
+		return true;
+
 	if (IS_SKYLAKE(dev_priv) || IS_KABYLAKE(dev_priv))
 		return skl_ddi_pll_select(intel_crtc, crtc_state,
 					  intel_encoder);
Signature · 6 lines
1.9.1

_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
maintainer
#1 lore raw
Quoted 4 lines · Vidya Srinivas

From: Uma Shankar <[email protected]>

In case of DSI, DDI PLL is not required.
Handle the same as part of DDI PLL handling.

Show me *one* code path where the functions you change may be called for DSI.

drivers/gpu/drm/i915/intel_ddi.c

Quoted 3 lines
drivers/gpu/drm/i915/intel_ddi.c +0 -0
old mode 100644
new mode 100755

Please make sure you never change the mode.

BR,
Jani.

Signature · 5 lines
Jani Nikula, Intel Open Source Technology Center
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
#2 lore raw
Quoted 9 lines

-----Original Message-----
From: Jani Nikula [mailto:[email protected]]
Sent: Wednesday, January 18, 2017 3:06 PM
To: Srinivas, Vidya <[email protected]>; intel- [email protected]
Subject: Re: [Intel-gfx] [PATCH 02/14] drm/i915: Handle DSI case for DDI PLL

Quoted 9 lines
Quoted 4 lines · Vidya Srinivas

From: Uma Shankar <[email protected]>

In case of DSI, DDI PLL is not required.
Handle the same as part of DDI PLL handling.

Show me *one* code path where the functions you change may be called for DSI.

This was needed in the earlier code around kernel 4.4 version. We re-verified in the latest upstream code and confirmed that this is no longer needed. We can drop this change. We will re-send the updated series without this.

Regards
Vidya

Quoted 7 lines

drivers/gpu/drm/i915/intel_ddi.c

Quoted 4 lines
drivers/gpu/drm/i915/intel_ddi.c +0 -0
old mode 100644
new mode 100755

Please make sure you never change the mode.

Quoted 6 lines

BR,
Jani.

--
Jani Nikula, Intel Open Source Technology Center

_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx