diff mbox

[2/2] drm/i915/audio: extend audio sync rate support for DP MST

Message ID 1480569439-54252-2-git-send-email-libin.yang@intel.com (mailing list archive)
State New, archived
Headers show

Commit Message

Yang, Libin Dec. 1, 2016, 5:17 a.m. UTC
From: Libin Yang <libin.yang@intel.com>

Remove the type judgement in i915_audio_component_sync_audio_rate().
Audio rate sync is necessary for all i915 digital audio now.

Signed-off-by: Libin Yang <libin.yang@intel.com>
---
 drivers/gpu/drm/i915/intel_audio.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

Comments

Yang, Libin Dec. 2, 2016, 6:47 a.m. UTC | #1
Any comments? Thanks.

Regards,
Libin


>-----Original Message-----
>From: Yang, Libin
>Sent: Thursday, December 1, 2016 1:17 PM
>To: intel-gfx@lists.freedesktop.org; jani.nikula@linux.intel.com;
>ville.syrjala@linux.intel.com; Vetter, Daniel <daniel.vetter@intel.com>;
>Pandiyan, Dhinakaran <dhinakaran.pandiyan@intel.com>; tiwai@suse.de
>Cc: Yang, Libin <libin.yang@intel.com>
>Subject: [PATCH 2/2] drm/i915/audio: extend audio sync rate support for DP
>MST
>
>From: Libin Yang <libin.yang@intel.com>
>
>Remove the type judgement in i915_audio_component_sync_audio_rate().
>Audio rate sync is necessary for all i915 digital audio now.
>
>Signed-off-by: Libin Yang <libin.yang@intel.com>
>---
> drivers/gpu/drm/i915/intel_audio.c | 4 +---
> 1 file changed, 1 insertion(+), 3 deletions(-)
>
>diff --git a/drivers/gpu/drm/i915/intel_audio.c
>b/drivers/gpu/drm/i915/intel_audio.c
>index c8a1345..3bbc96c 100644
>--- a/drivers/gpu/drm/i915/intel_audio.c
>+++ b/drivers/gpu/drm/i915/intel_audio.c
>@@ -805,9 +805,7 @@ static int
>i915_audio_component_sync_audio_rate(struct device *kdev, int port,
>
> 	/* 1. get the pipe */
> 	intel_encoder = get_saved_enc(dev_priv, port, pipe);
>-	if (!intel_encoder || !intel_encoder->base.crtc ||
>-	    (intel_encoder->type != INTEL_OUTPUT_HDMI &&
>-	     intel_encoder->type != INTEL_OUTPUT_DP)) {
>+	if (!intel_encoder || !intel_encoder->base.crtc) {
> 		DRM_DEBUG_KMS("Not valid for port %c\n",
>port_name(port));
> 		err = -ENODEV;
> 		goto unlock;
>--
>2.7.4
Jani Nikula Dec. 2, 2016, 2:25 p.m. UTC | #2
On Fri, 02 Dec 2016, "Yang, Libin" <libin.yang@intel.com> wrote:
> Any comments? Thanks.

Both pushed to dinq, thanks for the patches.

Libin and/or Dhinakaran, please improve the documentation of struct
i915_audio_component_ops to describe the parameters of sync_audio_rate
and get_eld hooks. For example, there's nothing about pipe being -1 for
non-MST.

BR,
Jani.


>
> Regards,
> Libin
>
>
>>-----Original Message-----
>>From: Yang, Libin
>>Sent: Thursday, December 1, 2016 1:17 PM
>>To: intel-gfx@lists.freedesktop.org; jani.nikula@linux.intel.com;
>>ville.syrjala@linux.intel.com; Vetter, Daniel <daniel.vetter@intel.com>;
>>Pandiyan, Dhinakaran <dhinakaran.pandiyan@intel.com>; tiwai@suse.de
>>Cc: Yang, Libin <libin.yang@intel.com>
>>Subject: [PATCH 2/2] drm/i915/audio: extend audio sync rate support for DP
>>MST
>>
>>From: Libin Yang <libin.yang@intel.com>
>>
>>Remove the type judgement in i915_audio_component_sync_audio_rate().
>>Audio rate sync is necessary for all i915 digital audio now.
>>
>>Signed-off-by: Libin Yang <libin.yang@intel.com>
>>---
>> drivers/gpu/drm/i915/intel_audio.c | 4 +---
>> 1 file changed, 1 insertion(+), 3 deletions(-)
>>
>>diff --git a/drivers/gpu/drm/i915/intel_audio.c
>>b/drivers/gpu/drm/i915/intel_audio.c
>>index c8a1345..3bbc96c 100644
>>--- a/drivers/gpu/drm/i915/intel_audio.c
>>+++ b/drivers/gpu/drm/i915/intel_audio.c
>>@@ -805,9 +805,7 @@ static int
>>i915_audio_component_sync_audio_rate(struct device *kdev, int port,
>>
>> 	/* 1. get the pipe */
>> 	intel_encoder = get_saved_enc(dev_priv, port, pipe);
>>-	if (!intel_encoder || !intel_encoder->base.crtc ||
>>-	    (intel_encoder->type != INTEL_OUTPUT_HDMI &&
>>-	     intel_encoder->type != INTEL_OUTPUT_DP)) {
>>+	if (!intel_encoder || !intel_encoder->base.crtc) {
>> 		DRM_DEBUG_KMS("Not valid for port %c\n",
>>port_name(port));
>> 		err = -ENODEV;
>> 		goto unlock;
>>--
>>2.7.4
>
Yang, Libin Dec. 3, 2016, 1:22 p.m. UTC | #3
>-----Original Message-----
>From: Jani Nikula [mailto:jani.nikula@linux.intel.com]
>Sent: Friday, December 2, 2016 10:25 PM
>To: Yang, Libin <libin.yang@intel.com>; intel-gfx@lists.freedesktop.org;
>ville.syrjala@linux.intel.com; Vetter, Daniel <daniel.vetter@intel.com>;
>Pandiyan, Dhinakaran <dhinakaran.pandiyan@intel.com>; tiwai@suse.de;
>Liang.Xiao1@dell.com
>Subject: RE: [PATCH 2/2] drm/i915/audio: extend audio sync rate support for
>DP MST
>
>On Fri, 02 Dec 2016, "Yang, Libin" <libin.yang@intel.com> wrote:
>> Any comments? Thanks.
>
>Both pushed to dinq, thanks for the patches.
>
>Libin and/or Dhinakaran, please improve the documentation of struct
>i915_audio_component_ops to describe the parameters of sync_audio_rate
>and get_eld hooks. For example, there's nothing about pipe being -1 for non-
>MST.

Thanks. Get it. I will update it next week.

Regards,
Libin

>
>BR,
>Jani.
>
>
>>
>> Regards,
>> Libin
>>
>>
>>>-----Original Message-----
>>>From: Yang, Libin
>>>Sent: Thursday, December 1, 2016 1:17 PM
>>>To: intel-gfx@lists.freedesktop.org; jani.nikula@linux.intel.com;
>>>ville.syrjala@linux.intel.com; Vetter, Daniel
>>><daniel.vetter@intel.com>; Pandiyan, Dhinakaran
>>><dhinakaran.pandiyan@intel.com>; tiwai@suse.de
>>>Cc: Yang, Libin <libin.yang@intel.com>
>>>Subject: [PATCH 2/2] drm/i915/audio: extend audio sync rate support
>>>for DP MST
>>>
>>>From: Libin Yang <libin.yang@intel.com>
>>>
>>>Remove the type judgement in i915_audio_component_sync_audio_rate().
>>>Audio rate sync is necessary for all i915 digital audio now.
>>>
>>>Signed-off-by: Libin Yang <libin.yang@intel.com>
>>>---
>>> drivers/gpu/drm/i915/intel_audio.c | 4 +---
>>> 1 file changed, 1 insertion(+), 3 deletions(-)
>>>
>>>diff --git a/drivers/gpu/drm/i915/intel_audio.c
>>>b/drivers/gpu/drm/i915/intel_audio.c
>>>index c8a1345..3bbc96c 100644
>>>--- a/drivers/gpu/drm/i915/intel_audio.c
>>>+++ b/drivers/gpu/drm/i915/intel_audio.c
>>>@@ -805,9 +805,7 @@ static int
>>>i915_audio_component_sync_audio_rate(struct device *kdev, int port,
>>>
>>> 	/* 1. get the pipe */
>>> 	intel_encoder = get_saved_enc(dev_priv, port, pipe);
>>>-	if (!intel_encoder || !intel_encoder->base.crtc ||
>>>-	    (intel_encoder->type != INTEL_OUTPUT_HDMI &&
>>>-	     intel_encoder->type != INTEL_OUTPUT_DP)) {
>>>+	if (!intel_encoder || !intel_encoder->base.crtc) {
>>> 		DRM_DEBUG_KMS("Not valid for port %c\n",
>port_name(port));
>>> 		err = -ENODEV;
>>> 		goto unlock;
>>>--
>>>2.7.4
>>
>
>--
>Jani Nikula, Intel Open Source Technology Center
diff mbox

Patch

diff --git a/drivers/gpu/drm/i915/intel_audio.c b/drivers/gpu/drm/i915/intel_audio.c
index c8a1345..3bbc96c 100644
--- a/drivers/gpu/drm/i915/intel_audio.c
+++ b/drivers/gpu/drm/i915/intel_audio.c
@@ -805,9 +805,7 @@  static int i915_audio_component_sync_audio_rate(struct device *kdev, int port,
 
 	/* 1. get the pipe */
 	intel_encoder = get_saved_enc(dev_priv, port, pipe);
-	if (!intel_encoder || !intel_encoder->base.crtc ||
-	    (intel_encoder->type != INTEL_OUTPUT_HDMI &&
-	     intel_encoder->type != INTEL_OUTPUT_DP)) {
+	if (!intel_encoder || !intel_encoder->base.crtc) {
 		DRM_DEBUG_KMS("Not valid for port %c\n", port_name(port));
 		err = -ENODEV;
 		goto unlock;