Skip to contentSkip to conversation

Defined NM doesn't work on KBL and uses automatic N/M.

PATCH In review Quanxian Wang 3 participants 9 messages May 26, 2017 – Dec 8, 2017

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

PATCH 1/1 Defined NM doesn't work on KBL and uses automatic N/M.

According to the bspec, when set N/M, should disable and enable transcoder which attaching DP audio. However with that implementation will affect performance more.

But with current implementation, KBL could not work with defined N/M. By default, KBL will use automatic N/M.

---
 drivers/gpu/drm/i915/intel_audio.c | 4 ++++
 1 file changed, 4 insertions(+)
drivers/gpu/drm/i915/intel_audio.c +4 -0
index d805b6e..ba4994e 100644
@@ -289,6 +289,10 @@ hsw_dp_audio_config_update(struct intel_crtc *intel_crtc, enum port port,
 	enum pipe pipe = intel_crtc->pipe;
 	u32 tmp;
 
+	/* It doesn't work on KBL and uses automatic N/M. */
+	if (IS_KABYLAKE(dev_priv))
+		nm = NULL;
+
 	if (nm)
 		DRM_DEBUG_KMS("using Maud %u, Naud %u\n", nm->m, nm->n);
 	else
Signature · 6 lines
2.5.0

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

✓ Fi.CI.BAT: success for Defined NM doesn't work on KBL and uses automatic N/M.

== Series Details ==

== Series Details ==

Series: Defined NM doesn't work on KBL and uses automatic N/M.
URL : https://patchwork.freedesktop.org/series/24938/
State : success

== Summary ==

Series 24938v1 Defined NM doesn't work on KBL and uses automatic N/M.
https://patchwork.freedesktop.org/api/1.0/series/24938/revisions/1/mbox/

fi-bdw-5557u     total:278  pass:267  dwarn:0   dfail:0   fail:0   skip:11  time:446s
fi-bdw-gvtdvm    total:278  pass:256  dwarn:8   dfail:0   fail:0   skip:14  time:428s
fi-bsw-n3050     total:278  pass:242  dwarn:0   dfail:0   fail:0   skip:36  time:579s
fi-bxt-j4205     total:278  pass:259  dwarn:0   dfail:0   fail:0   skip:19  time:513s
fi-byt-j1900     total:278  pass:254  dwarn:0   dfail:0   fail:0   skip:24  time:485s
fi-byt-n2820     total:278  pass:250  dwarn:0   dfail:0   fail:0   skip:28  time:484s
fi-hsw-4770      total:278  pass:262  dwarn:0   dfail:0   fail:0   skip:16  time:421s
fi-hsw-4770r     total:278  pass:262  dwarn:0   dfail:0   fail:0   skip:16  time:410s
fi-ilk-650       total:278  pass:228  dwarn:0   dfail:0   fail:0   skip:50  time:418s
fi-ivb-3520m     total:278  pass:260  dwarn:0   dfail:0   fail:0   skip:18  time:484s
fi-ivb-3770      total:278  pass:260  dwarn:0   dfail:0   fail:0   skip:18  time:468s
fi-kbl-7500u     total:278  pass:255  dwarn:5   dfail:0   fail:0   skip:18  time:462s
fi-kbl-7560u     total:278  pass:263  dwarn:5   dfail:0   fail:0   skip:10  time:570s
fi-skl-6260u     total:278  pass:268  dwarn:0   dfail:0   fail:0   skip:10  time:462s
fi-skl-6700hq    total:278  pass:239  dwarn:0   dfail:1   fail:17  skip:21  time:438s
fi-skl-6700k     total:278  pass:256  dwarn:4   dfail:0   fail:0   skip:18  time:464s
fi-skl-6770hq    total:278  pass:268  dwarn:0   dfail:0   fail:0   skip:10  time:499s
fi-skl-gvtdvm    total:278  pass:265  dwarn:0   dfail:0   fail:0   skip:13  time:440s
fi-snb-2520m     total:278  pass:250  dwarn:0   dfail:0   fail:0   skip:28  time:541s
fi-snb-2600      total:278  pass:249  dwarn:0   dfail:0   fail:0   skip:29  time:398s

d47b71fd942d8a88da311863a6cfc2fd73ba1234 drm-tip: 2017y-05m-25d-20h-54m-23s UTC integration manifest 3784560 Defined NM doesn't work on KBL and uses automatic N/M.

== Logs ==

For more details see: https://intel-gfx-ci.01.org/CI/Patchwork_4815/
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

maintainer
#2 lore raw
In reply to Quanxian Wang
Quoted 10 lines · Quanxian Wang

According to the bspec, when set N/M, should disable and enable transcoder which attaching DP audio. However with that implementation will affect performance more.

But with current implementation, KBL could not work with defined N/M. By default, KBL will use automatic N/M.

I have *NOT* reviewed this patch. Even if it's based on my suggestion in [1], it does not automatically signify review.

The patch subject should start with "drm/i915/audio:".

The DP spec always expresses the values as M/N, more specifically Maud/Naud, so it's confusing to see them expressed as N/M.

I still have trouble understanding the commit message. I am wondering if something was fixed in Kabylake and beyond, since according to 6014ac122ed0 ("drm/i915/audio: set proper N/M in modeset") we need this for certain modes. In particular, should the condition check for KBL || gen >= 10?

BR,
Jani.

[1] http://mid.mail-archive.com/[email protected]

Quoted 19 lines
---
 drivers/gpu/drm/i915/intel_audio.c | 4 ++++
 1 file changed, 4 insertions(+)
drivers/gpu/drm/i915/intel_audio.c +4 -0
index d805b6e..ba4994e 100644
@@ -289,6 +289,10 @@ hsw_dp_audio_config_update(struct intel_crtc *intel_crtc, enum port port,
 	enum pipe pipe = intel_crtc->pipe;
 	u32 tmp;
 
+	/* It doesn't work on KBL and uses automatic N/M. */
+	if (IS_KABYLAKE(dev_priv))
+		nm = NULL;
+
 	if (nm)
 		DRM_DEBUG_KMS("using Maud %u, Naud %u\n", nm->m, nm->n);
 	else
Signature · 5 lines
Jani Nikula, Intel Open Source Technology Center
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
#3 lore raw

Hi, Jani

Thanks for your comment. My comment below.

-----Original Message-----
From: Jani Nikula [mailto:[email protected]]
Sent: Friday, May 26, 2017 4:31 PM
To: Wang, Quanxian <[email protected]>; [email protected]
Cc: Yang, Libin <[email protected]>; Wang, Quanxian <[email protected]>
Subject: Re: [PATCH] Defined NM doesn't work on KBL and uses automatic N/M.

Quoted 10 lines · Quanxian Wang

According to the bspec, when set N/M, should disable and enable transcoder which attaching DP audio. However with that implementation will affect performance more.

But with current implementation, KBL could not work with defined N/M. By default, KBL will use automatic N/M.

I have *NOT* reviewed this patch. Even if it's based on my suggestion in [1], it does not automatically signify review. [Wang, Quanxian] Sorry, I accept your suggestion. So in order to respect what you said, I input your name here.

The patch subject should start with "drm/i915/audio:". [Wang, Quanxian] Ok.

The DP spec always expresses the values as M/N, more specifically Maud/Naud, so it's confusing to see them expressed as N/M. [Wang, Quanxian] accept it.

I still have trouble understanding the commit message. I am wondering if something was fixed in Kabylake and beyond, since according to
[Wang, Quanxian] in Ubuntu 17.04, we do audio testing on KBL/SKL/APL and more, the audio doesn't work on KBL specially, and other platform works fine. Even if with latest upstream kernel, but it works on 4.8 kernel. Therefore It is a regression issue. After investigation, we found it is caused by commit "6014ac122ed081feca99217bc57b2e15c7fc1a51] drm/i915/audio: set proper N/M in modeset". Therefore I provided this patch. After getting suggestion from you and Libin, we do more testing on 4K monitor for audio delay issue. Also talked with Libin why not use transcoder disable/enable process described in bspec, it will affect performance.
This is the whole story. You can check LCK number 3791 in Intel JIRA about that.

6014ac122ed0 ("drm/i915/audio: set proper N/M in modeset") we need this for certain modes. In particular, should the condition check for KBL || gen >= 10?

[Wang, Quanxian] Basically if upstream could provide a reasonable patch, it will appreciate since you are expert in this area. Thanks for your understanding.

BR,
Jani.

[1] http://mid.mail-archive.com/[email protected]

Quoted 10 lines
---
 drivers/gpu/drm/i915/intel_audio.c | 4 ++++
 1 file changed, 4 insertions(+)
drivers/gpu/drm/i915/intel_audio.c +0 -0
index d805b6e..ba4994e 100644

drivers/gpu/drm/i915/intel_audio.c hsw_dp_audio_config_update(struct intel_crtc *intel_crtc, enum port port, · line 298

Quoted 10 lines
drivers/gpu/drm/i915/intel_audio.c +4 -0
@@ -289,6 +289,10 @@ hsw_dp_audio_config_update(struct intel_crtc *intel_crtc, enum port port,
 	enum pipe pipe = intel_crtc->pipe;
 	u32 tmp;
 
+	/* It doesn't work on KBL and uses automatic N/M. */
+	if (IS_KABYLAKE(dev_priv))
+		nm = NULL;
+
 	if (nm)
 		DRM_DEBUG_KMS("using Maud %u, Naud %u\n", nm->m, nm->n);
 	else

--
Jani Nikula, Intel Open Source Technology Center
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

maintainer
#4 lore raw
Quoted 7 lines · Quanxian

[Wang, Quanxian] in Ubuntu 17.04, we do audio testing on KBL/SKL/APL and more, the audio doesn't work on KBL specially, and other platform works fine. Even if with latest upstream kernel, but it works on 4.8 kernel. Therefore It is a regression issue. After investigation, we found it is caused by commit "6014ac122ed081feca99217bc57b2e15c7fc1a51] drm/i915/audio: set proper N/M in modeset". Therefore I provided this patch.

If it's a regression, we need to backport the fix to stable kernels, and the patch needs annotation:

Fixes 6014ac122ed0 ("drm/i915/audio: set proper N/M in modeset")
Cc <[email protected]> # v4.10+
Quoted 7 lines

After getting suggestion from you and Libin, we do more testing on 4K monitor for audio delay issue. Also talked with Libin why not use transcoder disable/enable process described in bspec, it will affect performance.

This is the whole story. You can check LCK number 3791 in Intel JIRA about that.

Actually, I can't. And the commit message needs to have the explanation. I still do not know what the bug is specifically, or why Kabylake, and only Kabylake, needs this.

Quoted 3 lines

[Wang, Quanxian] Basically if upstream could provide a reasonable patch, it will appreciate since you are expert in this area. Thanks for your understanding.

The patch is probably fine. But I can't invent an explanation if I don't know what the problem is.

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
#5 lore raw

"The patch is probably fine. But I can't invent an explanation if I don't know what the problem is."

@Jani @libin, is it possible for you to help contact Intel graphics hardware design engineer to get the reason why M/N doesn't work as you implemented in kernel code in Kabylake platform? I don't find good reason in bspec. Thanks.

-----Original Message-----
From: Jani Nikula [mailto:[email protected]]
Sent: Friday, May 26, 2017 7:01 PM
To: Wang, Quanxian <[email protected]>; [email protected]
Cc: Yang, Libin <[email protected]>
Subject: RE: [PATCH] Defined NM doesn't work on KBL and uses automatic N/M.

Quoted 7 lines · Quanxian

[Wang, Quanxian] in Ubuntu 17.04, we do audio testing on KBL/SKL/APL and more, the audio doesn't work on KBL specially, and other platform works fine. Even if with latest upstream kernel, but it works on 4.8 kernel. Therefore It is a regression issue. After investigation, we found it is caused by commit "6014ac122ed081feca99217bc57b2e15c7fc1a51] drm/i915/audio: set proper N/M in modeset". Therefore I provided this patch.

If it's a regression, we need to backport the fix to stable kernels, and the patch needs annotation:

Fixes 6014ac122ed0 ("drm/i915/audio: set proper N/M in modeset")
Cc <[email protected]> # v4.10+
Quoted 7 lines

After getting suggestion from you and Libin, we do more testing on 4K monitor for audio delay issue. Also talked with Libin why not use transcoder disable/enable process described in bspec, it will affect performance.

This is the whole story. You can check LCK number 3791 in Intel JIRA about that.

Actually, I can't. And the commit message needs to have the explanation. I still do not know what the bug is specifically, or why Kabylake, and only Kabylake, needs this.

Quoted 3 lines

[Wang, Quanxian] Basically if upstream could provide a reasonable patch, it will appreciate since you are expert in this area. Thanks for your understanding.

The patch is probably fine. But I can't invent an explanation if I don't know what the problem is.

BR,
Jani.

--
Jani Nikula, Intel Open Source Technology Center
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

maintainer
#6 lore raw
Quoted 7 lines · Quanxian

"The patch is probably fine. But I can't invent an explanation if I don't know what the problem is."

@Jani @libin, is it possible for you to help contact Intel graphics hardware design engineer to get the reason why M/N doesn't work as you implemented in kernel code in Kabylake platform? I don't find good reason in bspec. Thanks.

How did you come up with the patch then? What made you try this?

BR,
Jani.

Quoted 44 lines

-----Original Message-----
From: Jani Nikula [mailto:[email protected]]
Sent: Friday, May 26, 2017 7:01 PM
To: Wang, Quanxian <[email protected]>; [email protected]
Cc: Yang, Libin <[email protected]>
Subject: RE: [PATCH] Defined NM doesn't work on KBL and uses automatic N/M.

Quoted 7 lines · Quanxian

[Wang, Quanxian] in Ubuntu 17.04, we do audio testing on KBL/SKL/APL and more, the audio doesn't work on KBL specially, and other platform works fine. Even if with latest upstream kernel, but it works on 4.8 kernel. Therefore It is a regression issue. After investigation, we found it is caused by commit "6014ac122ed081feca99217bc57b2e15c7fc1a51] drm/i915/audio: set proper N/M in modeset". Therefore I provided this patch.

If it's a regression, we need to backport the fix to stable kernels, and the patch needs annotation:

Fixes 6014ac122ed0 ("drm/i915/audio: set proper N/M in modeset")
Cc <[email protected]> # v4.10+
Quoted 7 lines

After getting suggestion from you and Libin, we do more testing on 4K monitor for audio delay issue. Also talked with Libin why not use transcoder disable/enable process described in bspec, it will affect performance.

This is the whole story. You can check LCK number 3791 in Intel JIRA about that.

Actually, I can't. And the commit message needs to have the explanation. I still do not know what the bug is specifically, or why Kabylake, and only Kabylake, needs this.

Quoted 3 lines

[Wang, Quanxian] Basically if upstream could provide a reasonable patch, it will appreciate since you are expert in this area. Thanks for your understanding.

The patch is probably fine. But I can't invent an explanation if I don't know what the problem is.

BR,
Jani.

--
Jani Nikula, Intel Open Source Technology Center

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

-----Original Message-----
From: Jani Nikula [mailto:[email protected]]
Sent: Monday, May 29, 2017 4:29 PM
To: Wang, Quanxian <[email protected]>; [email protected]
Cc: Yang, Libin <[email protected]>
Subject: RE: [PATCH] Defined NM doesn't work on KBL and uses automatic N/M.

Quoted 7 lines · Quanxian

"The patch is probably fine. But I can't invent an explanation if I don't know what the problem is."

@Jani @libin, is it possible for you to help contact Intel graphics hardware design engineer to get the reason why M/N doesn't work as you implemented in kernel code in Kabylake platform? I don't find good reason in bspec. Thanks.

How did you come up with the patch then? What made you try this?
[Wang, Quanxian] I am from OSV enabling team and responsible for Ubuntu enabling. 17.04 (kernel 4.10) is released, we will do full testing for all Intel platforms including KBL/SKL... With audio testing, we found this regression issue on KBL and find patch caused this regression. Compared with previous implementation, we use automatic M/N to have a try. It works.

BR,
Jani.

Quoted 37 lines

-----Original Message-----
From: Jani Nikula [mailto:[email protected]]
Sent: Friday, May 26, 2017 7:01 PM
To: Wang, Quanxian <[email protected]>; [email protected]
Cc: Yang, Libin <[email protected]>
Subject: RE: [PATCH] Defined NM doesn't work on KBL and uses automatic N/M.

Quoted 7 lines · Quanxian

[Wang, Quanxian] in Ubuntu 17.04, we do audio testing on KBL/SKL/APL and more, the audio doesn't work on KBL specially, and other platform works fine. Even if with latest upstream kernel, but it works on 4.8 kernel. Therefore It is a regression issue. After investigation, we found it is caused by commit "6014ac122ed081feca99217bc57b2e15c7fc1a51] drm/i915/audio: set proper N/M in modeset". Therefore I provided this patch.

If it's a regression, we need to backport the fix to stable kernels, and the patch needs annotation:

Fixes 6014ac122ed0 ("drm/i915/audio: set proper N/M in modeset")
Cc <[email protected]> # v4.10+
Quoted 7 lines

After getting suggestion from you and Libin, we do more testing on 4K monitor for audio delay issue. Also talked with Libin why not use transcoder disable/enable process described in bspec, it will affect performance.

This is the whole story. You can check LCK number 3791 in Intel JIRA about that.

Actually, I can't. And the commit message needs to have the explanation. I still do not know what the bug is specifically, or why Kabylake, and only Kabylake, needs this.

Quoted 3 lines

[Wang, Quanxian] Basically if upstream could provide a reasonable patch, it will appreciate since you are expert in this area. Thanks for your understanding.

Quoted 8 lines

The patch is probably fine. But I can't invent an explanation if I don't know what the problem is.

BR,
Jani.

--
Jani Nikula, Intel Open Source Technology Center

--
Jani Nikula, Intel Open Source Technology Center
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

#8 lore raw

Hi, Jani

I have created a Bugzilla in free desktop for tracking.
https://bugs.freedesktop.org/show_bug.cgi?id=104093

Appreciate find audio expert could help us address root cause.

Thank you.

Quanxian

-----Original Message-----
From: Intel-gfx [mailto:[email protected]] On Behalf Of Wang, Quanxian
Sent: Wednesday, May 31, 2017 11:21 AM
To: Jani Nikula <[email protected]>; [email protected]
Subject: Re: [Intel-gfx] [PATCH] Defined NM doesn't work on KBL and uses automatic N/M.

-----Original Message-----
From: Jani Nikula [mailto:[email protected]]
Sent: Monday, May 29, 2017 4:29 PM
To: Wang, Quanxian <[email protected]>; [email protected]
Cc: Yang, Libin <[email protected]>
Subject: RE: [PATCH] Defined NM doesn't work on KBL and uses automatic N/M.

Quoted 7 lines · Quanxian

"The patch is probably fine. But I can't invent an explanation if I don't know what the problem is."

@Jani @libin, is it possible for you to help contact Intel graphics hardware design engineer to get the reason why M/N doesn't work as you implemented in kernel code in Kabylake platform? I don't find good reason in bspec. Thanks.

How did you come up with the patch then? What made you try this?
[Wang, Quanxian] I am from OSV enabling team and responsible for Ubuntu enabling. 17.04 (kernel 4.10) is released, we will do full testing for all Intel platforms including KBL/SKL... With audio testing, we found this regression issue on KBL and find patch caused this regression. Compared with previous implementation, we use automatic M/N to have a try. It works.

BR,
Jani.

Quoted 37 lines

-----Original Message-----
From: Jani Nikula [mailto:[email protected]]
Sent: Friday, May 26, 2017 7:01 PM
To: Wang, Quanxian <[email protected]>; [email protected]
Cc: Yang, Libin <[email protected]>
Subject: RE: [PATCH] Defined NM doesn't work on KBL and uses automatic N/M.

Quoted 7 lines · Quanxian

[Wang, Quanxian] in Ubuntu 17.04, we do audio testing on KBL/SKL/APL and more, the audio doesn't work on KBL specially, and other platform works fine. Even if with latest upstream kernel, but it works on 4.8 kernel. Therefore It is a regression issue. After investigation, we found it is caused by commit "6014ac122ed081feca99217bc57b2e15c7fc1a51] drm/i915/audio: set proper N/M in modeset". Therefore I provided this patch.

If it's a regression, we need to backport the fix to stable kernels, and the patch needs annotation:

Fixes 6014ac122ed0 ("drm/i915/audio: set proper N/M in modeset")
Cc <[email protected]> # v4.10+
Quoted 7 lines

After getting suggestion from you and Libin, we do more testing on 4K monitor for audio delay issue. Also talked with Libin why not use transcoder disable/enable process described in bspec, it will affect performance.

This is the whole story. You can check LCK number 3791 in Intel JIRA about that.

Actually, I can't. And the commit message needs to have the explanation. I still do not know what the bug is specifically, or why Kabylake, and only Kabylake, needs this.

Quoted 3 lines

[Wang, Quanxian] Basically if upstream could provide a reasonable patch, it will appreciate since you are expert in this area. Thanks for your understanding.

Quoted 8 lines

The patch is probably fine. But I can't invent an explanation if I don't know what the problem is.

BR,
Jani.

--
Jani Nikula, Intel Open Source Technology Center

--
Jani Nikula, Intel Open Source Technology Center
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx