|Summary:||[GLK] Fifo underrun when changing resolution|
|Component:||DRM/Intel||Assignee:||Luis Botello <luis.botello.ortega>|
|Status:||CLOSED FIXED||QA Contact:||Intel GFX Bugs mailing list <intel-gfx-bugs>|
|Priority:||highest||CC:||dhinakaran.pandiyan, intel-gfx-bugs, mahesh1.kumar, ricardo.vega|
|i915 platform:||GLK||i915 features:||display/Other|
Description cprigent 2017-03-21 14:56:23 UTC
Created attachment 130351 [details] kern.log System Environment ======= Ubuntu 16.10 libdrm-2.4.75-7-gf6499b1 from http://cgit.freedesktop.org/mesa/drm cairo 1.15.4-6-g5854dd9 from http://cgit.freedesktop.org/cairo Kernel: 4.10.0-15ccc64 branch drm-tip from https://cgit.freedesktop.org/drm-tip commit 15ccc648be8c8717d0e7b7d6ac6038394c15f898 Author: Ander Conselvan de Oliveira <email@example.com> Date: Mon Feb 27 09:13:30 2017 +0200 drm-tip: 2017y-02m-27d-07h-11m-41s UTC integration manifest Regression ======= Tested for the first time Bug detailed description ======= This problem only affect eDP so far, but is sending FIFO under run in dmesg after changing resolutions and having other programs running in the background Reproduce Steps ============== Enter in UI with your credentials Open Libreoffice Open glxgears Open a terminal, change resolution Xrandr --output eDP-1 --mode 1024x768 xrandr --output eDP-1 --mode 640x480 xrandr --output eDP-1 --mode 1920x1080 Expected Result ============= dmesg should be clean of FIFO underun caused by kernel Actual Result =========== [ 399.346861] [drm:intel_cpu_fifo_underrun_irq_handler [i915]] *ERROR* CPU pipe A FIFO underrun [ 399.346967] [drm:intel_fbc_underrun_work_fn [i915]] Disabling FBC due to FIFO underrun.
Comment 1 Ander Conselvan de Oliveira 2017-03-29 13:37:17 UTC
I noticed watermark programming differences for GLK in bspec, but fixing those didn't help, I can still reproduce these underruns. firstname.lastname@example.org:anderco/linux.git wip-glk-wm
Comment 2 Ander Conselvan de Oliveira 2017-03-31 14:38:49 UTC
The underrun happens immediately after enabling the edp transcoder in haswell_crtc_enable(). But I still don't know why.
Comment 3 cprigent 2017-04-04 09:38:44 UTC
Updated to highest/blocker due to impact on Alpha results.
Comment 4 Ander Conselvan de Oliveira 2017-04-04 11:04:18 UTC
I still haven't found the root cause for this, but I was enable to narrow it down further: - The underrun only happens with eDP because it is triggered by using the pipe scaler. If I force HDMI to use panel fitting, the underrun is also triggered. - The underrun happens only the first time the scaler is used. After reverting to the panel native resolution, a subsequent modeset won't trigger the underrun again. However, the underrun can be triggered once after a suspend/resume cycle. - Using the scaler to scale a plane before the modeset that triggers the scaler usage by the pipe will also prevent the underrun.
Comment 5 Ander Conselvan de Oliveira 2017-04-07 11:33:44 UTC
Created attachment 130742 [details] [review] Workaround patch I haven't been able to root cause the issue. The attached patch works around it by disabling underrun reporting on the first frame when enabling the pipe scaler. I'm now also seeing an underrun with FBC, but that happens even without changing resolution and goes away with i915.enable_fbc=0.
Comment 6 Ander Conselvan de Oliveira 2017-04-18 11:34:40 UTC
Created attachment 130896 [details] [review] Workaround patch I found a better workaround. If DPF clock gating is disabled before the pipe scaler is enabled, the underrun doesn't happen.
Comment 7 cprigent 2017-04-18 11:42:40 UTC
Hi Luis, Please check with the patch attached. Thanks.
Comment 8 Luis Botello 2017-04-21 23:20:15 UTC
(In reply to Ander Conselvan de Oliveira from comment #6) > Created attachment 130896 [details] [review] [review] > Workaround patch > > I found a better workaround. If DPF clock gating is disabled before the pipe > scaler is enabled, the underrun doesn't happen. With this patch there is no FIFO underruns, I used this config: ====================================== Software ====================================== kernel version : 4.11.0-rc7-drm-tip-patch-ander-underrun-f7dd93d+ architecture : x86_64 bios revision : 43.30 bios release date : 04/11/2017 ksc : 1.25 xf86-video-intel (tag) : 2.99.917 xf86-video-intel (commit) : 2.99.917-771-gb57abe2 xorg-xserver : 1.18.4 libdrm : 2.4.80 vaapi (intel-driver) : Intel i965 driver for Intel(R) Geminilake - 1.8.2.pre1 (1.7.3-382-gdbe582c) cairo : 1.15.5 xserver : X.Org X Server 22.214.171.124 dmc version : 1.4
Comment 9 cprigent 2017-04-24 09:41:19 UTC
Thanks. Status updated to resolved / fixed. It will be tested again when patch will be merged and this bug will be closed if still not reproduced.
Comment 10 Ander Conselvan de Oliveira 2017-05-08 09:02:38 UTC
Let's keep this open until the patch is merged. https://patchwork.freedesktop.org/series/24100/
Comment 11 Jani Saarinen 2017-05-22 10:10:25 UTC
I guess not yet merged?
Comment 12 Jani Saarinen 2017-06-07 10:49:19 UTC
Same situation still. Waiting some confirmation.
Comment 13 Jari Tahvanainen 2017-07-04 11:53:22 UTC
workaround patch still not merged...
Comment 14 Luis Botello 2017-07-17 22:19:43 UTC
Hi Ander, do you have any updates about patch merge?
Comment 15 Ander Conselvan de Oliveira 2017-07-18 06:19:49 UTC
(In reply to Luis Botello from comment #14) > Hi Ander, do you have any updates about patch merge? No, I'm not working on this (or Intel anymore). Maybe Imre can help?
Comment 16 Luis Botello 2017-07-24 20:59:48 UTC
(In reply to Ander Conselvan de Oliveira from comment #15) > (In reply to Luis Botello from comment #14) > > Hi Ander, do you have any updates about patch merge? > > No, I'm not working on this (or Intel anymore). Maybe Imre can help? Thanks Ander for your input. I just tested with top of drm-tip, issue still present: commit 30d8319f3f0974c3f116620627b428a7db307e78 Author: Imre Deak <email@example.com> AuthorDate: Mon Jul 24 17:53:34 2017 +0300 Commit: Imre Deak <firstname.lastname@example.org> CommitDate: Mon Jul 24 17:53:34 2017 +0300 drm-tip: 2017y-07m-24d-14h-53m-05s UTC integration manifest
Comment 17 Jani Saarinen 2017-09-29 04:16:53 UTC
Fix from Imre on review: https://patchwork.freedesktop.org/series/31094/
Comment 18 Jani Saarinen 2017-10-02 13:25:55 UTC
v2 now under review.
Comment 19 Jani Saarinen 2017-10-03 09:32:07 UTC
author Imre Deak <email@example.com> 2017-10-02 07:55:57 (GMT) committer Imre Deak <firstname.lastname@example.org> 2017-10-03 09:09:16 (GMT) commit ed69cd40685c949ec9c65701758bbf9e6840240f tree 72c71dcd4167579b4af494756a948dbe0aee2436 parent 495001c6457124e553ebeec30a42e75367724e4b drm/i915/glk, cnl: Implement WaDisableScalarClockGating
Comment 20 Ricardo 2017-10-03 12:57:56 UTC
Luis please verify