Bug 108860

Summary: [drm:intel_cpu_fifo_underrun_irq_handler [i915]] *ERROR* CPU pipe A FIFO underrun
Product: DRI Reporter: Nick Desaulniers <nick.desaulniers>
Component: DRM/IntelAssignee: Intel GFX Bugs mailing list <intel-gfx-bugs>
Status: RESOLVED MOVED QA Contact: Intel GFX Bugs mailing list <intel-gfx-bugs>
Severity: major    
Priority: medium CC: intel-gfx-bugs, jani.saarinen, nutello, ville.syrjala
Version: XOrg git   
Hardware: Other   
OS: All   
Whiteboard: Triaged, ReadyForDev
i915 platform: KBL i915 features: display/watermark
Attachments:
Description Flags
dmesg.txt
none
dmesg2.txt
none
dmesg3.txt
none
dmesg4.txt
none
dmesg5.txt none

Description Nick Desaulniers 2018-11-26 00:34:52 UTC
This is seen in dmesg after a flicker on the screen.

[   54.560613] [drm:intel_cpu_fifo_underrun_irq_handler [i915]] *ERROR* CPU pipe A FIFO underrun

Kernel command line parameters tried, to no effect:
i915.enable_fbc=0
i915.enable_rc6=0

This is on a i7-7500U (Kabylake) on a Razer Blade Stealth laptop.  Running a  4.19.0-rc7 kernel.
Comment 1 Nick Desaulniers 2018-11-26 00:37:52 UTC
Disabling thunderbolt support in BIOS does nothing.
Comment 2 Lakshmi 2018-11-26 07:38:09 UTC
Nick, please attach full dmesg from boot with kernel parameters drm.debug=0x1e log_buf_len=4M.

Apart from the error in dmesg, is there any other impact to you?
Comment 3 Nick Desaulniers 2018-11-27 06:11:28 UTC
Setting:
drm.debug=0x1e log_buf_len=4M
AND disabling crash kernel seemed to have helped.  Now to pare back which of those three is helping...

> is there any other impact to you?

Very noticeable screen blanks, a few per minute.
Comment 4 Nick Desaulniers 2018-11-27 06:18:17 UTC
Created attachment 142621 [details]
dmesg.txt

Just hit another unexpected screen blank.

> [ 2474.103168] [drm:intel_fbc_underrun_work_fn [i915]] Disabling FBC due to FIFO underrun.
Comment 5 Nick Desaulniers 2018-11-27 06:58:34 UTC
I feel like I wasn't getting any screen blanks with those debug options for quite a while.  After resuming from sleep a couple of times, I got a screen blank (attached dmesg) and have been getting them ever since.  Let's see what happens after a reboot, keeping those debug options.
Comment 6 Nick Desaulniers 2018-11-27 07:03:02 UTC
Created attachment 142622 [details]
dmesg2.txt

Nope, hit a screen blank within 9s of reboot.
Comment 7 Jani Saarinen 2018-11-27 07:08:32 UTC
Nick, can you try if this series helps at all? 
https://patchwork.freedesktop.org/series/51878/
Comment 8 Nick Desaulniers 2018-11-28 23:02:38 UTC
I wasn't able to apply the patch series to mainline.  Is there a different tree that I should apply this to?

$ git apply --check ~/Downloads/drm-i915-Program-SKL-watermarks-ddb-more-carefully.mbox
error: patch failed: drivers/gpu/drm/i915/intel_display.c:3329
error: drivers/gpu/drm/i915/intel_display.c: patch does not apply
error: patch failed: drivers/gpu/drm/i915/intel_sprite.c:508
error: drivers/gpu/drm/i915/intel_sprite.c: patch does not apply
error: patch failed: drivers/gpu/drm/i915/intel_sprite.c:824
error: drivers/gpu/drm/i915/intel_sprite.c: patch does not apply
error: patch failed: drivers/gpu/drm/i915/intel_atomic_plane.c:139
error: drivers/gpu/drm/i915/intel_atomic_plane.c: patch does not apply
error: patch failed: drivers/gpu/drm/i915/intel_display.c:10839
error: drivers/gpu/drm/i915/intel_display.c: patch does not apply
error: patch failed: drivers/gpu/drm/i915/intel_atomic_plane.c:210
error: drivers/gpu/drm/i915/intel_atomic_plane.c: patch does not apply
error: patch failed: drivers/gpu/drm/i915/intel_display.c:5405
error: drivers/gpu/drm/i915/intel_display.c: patch does not apply
error: patch failed: drivers/gpu/drm/i915/intel_sprite.c:594
error: drivers/gpu/drm/i915/intel_sprite.c: patch does not apply
error: patch failed: drivers/gpu/drm/i915/intel_pm.c:4910
error: drivers/gpu/drm/i915/intel_pm.c: patch does not apply
error: patch failed: drivers/gpu/drm/i915/intel_pm.c:4894
error: drivers/gpu/drm/i915/intel_pm.c: patch does not apply
error: patch failed: drivers/gpu/drm/i915/intel_pm.c:4746
error: drivers/gpu/drm/i915/intel_pm.c: patch does not apply
error: patch failed: drivers/gpu/drm/i915/intel_pm.c:4578
error: drivers/gpu/drm/i915/intel_pm.c: patch does not apply
error: patch failed: drivers/gpu/drm/i915/intel_display.c:10114
error: drivers/gpu/drm/i915/intel_display.c: patch does not apply
error: patch failed: drivers/gpu/drm/i915/intel_drv.h:2199
error: drivers/gpu/drm/i915/intel_drv.h: patch does not apply
error: patch failed: drivers/gpu/drm/i915/intel_pm.c:3951
error: drivers/gpu/drm/i915/intel_pm.c: patch does not apply
error: patch failed: drivers/gpu/drm/i915/intel_sprite.c:542
error: drivers/gpu/drm/i915/intel_sprite.c: patch does not apply
error: patch failed: drivers/gpu/drm/i915/intel_atomic_plane.c:169
error: drivers/gpu/drm/i915/intel_atomic_plane.c: patch does not apply
error: patch failed: drivers/gpu/drm/i915/intel_display.c:12661
error: drivers/gpu/drm/i915/intel_display.c: patch does not apply
error: patch failed: drivers/gpu/drm/i915/intel_drv.h:2299
error: drivers/gpu/drm/i915/intel_drv.h: patch does not apply
error: patch failed: drivers/gpu/drm/i915/intel_pm.c:4581
error: drivers/gpu/drm/i915/intel_pm.c: patch does not apply
error: patch failed: drivers/gpu/drm/i915/intel_sprite.c:373
error: drivers/gpu/drm/i915/intel_sprite.c: patch does not apply
Comment 9 Nick Desaulniers 2018-11-28 23:20:49 UTC
Seems the patches also do not apply cleanly to git://anongit.freedesktop.org/drm-tip drm-tip branch.
Comment 10 Nick Desaulniers 2018-11-28 23:45:31 UTC
From the drm-intel tree, I tried to apply the patchset to the branches: drm-intel-fixes, drm-intel-next, and drm-intel-next-fixes but the patchset fails to apply to all.  It looks like it came close for drm-intel-next, will see if I can resolve it manually myself.
Comment 11 Nick Desaulniers 2018-11-28 23:52:35 UTC
Ah looks like that series just landed in for-linux-next branch of drm-intel tree 4 hours ago, will try that.
Comment 12 Nick Desaulniers 2018-11-29 00:23:45 UTC
Seems to be working well.  I saw the underrun warning in 1/2 boots, but no obnoxious screen blanking (which is what I'm more concerned about).  Will reopen if I see the screen blanking again, thanks!
Comment 13 Nick Desaulniers 2018-11-29 00:51:49 UTC
gah, spoke too soon.  Flickering is back.  Will try to get the debug logs with this kernel.
Comment 14 Nick Desaulniers 2018-11-29 00:56:54 UTC
Created attachment 142655 [details]
dmesg3.txt

drm-intel tree for-linux-next branch including recommended patches.
Comment 15 Lakshmi 2018-11-29 07:08:32 UTC
Ville, any comments here? More patches to come?
Comment 16 Jani Saarinen 2018-11-29 07:30:08 UTC
Nick, always provide logs from boot to issue seen, thanks.
Comment 17 Nick Desaulniers 2018-11-30 07:48:55 UTC
Created attachment 142664 [details]
dmesg4.txt

dmesg from boot to issue observed
Comment 18 Lakshmi 2018-12-18 05:38:45 UTC
This issue is similar to https://bugs.freedesktop.org/show_bug.cgi?id=107758
Comment 19 Ville Syrjala 2019-01-22 20:37:33 UTC
[    0.000000] DMI: Razer Blade Stealth/Razer, BIOS 6.05 01/26/2017

Looks like the latest BIOS for this machine is 8.02 (assuming I landed in the right webpage). Might be worth updating the BIOS to see if it helps. Sadly looks like they provide it as some kind of Windows .exe :(
Comment 20 Nick Desaulniers 2019-01-23 04:45:16 UTC
Just updgraded to BIOS v8.02.  Still blinky.  Same error in dmesg.
Comment 21 Nick Desaulniers 2019-06-16 01:50:02 UTC
I just booted a fresh build of drm-tip as suggested in https://bugs.freedesktop.org/show_bug.cgi?id=99344#c13.


$ dmesg | grep fifo 
[    5.549241] [drm:intel_cpu_fifo_underrun_irq_handler [i915]] *ERROR* CPU pipe A FIFO underrun

$ cat /proc/version
Linux version 5.2.0-rc4+ (nick@nick-Blade-Stealth) (clang version 9.0.0 (https://github.com/llvm/llvm-project.git 80fee25776c2fb61e74c1ecb1a523375c2500b69)) #32 SMP Sat Jun 15 17:34:43 PDT 2019

$ cd linux
$ git show -1
commit 39e3d39be374d48ba73b61ec34f19a0afd5ac6f4 (HEAD -> drm-tip, drm-tip/drm-tip)
Author: Matt Roper <matthew.d.roper@intel.com>
Date:   Sat Jun 15 08:21:37 2019 -0700

    drm-tip: 2019y-06m-15d-15h-20m-54s UTC integration manifest
...
Comment 22 Nick Desaulniers 2019-06-16 02:01:22 UTC
Created attachment 144557 [details]
dmesg5.txt
Comment 23 Lakshmi 2019-06-17 05:47:28 UTC
(In reply to Nick Desaulniers from comment #21)
> I just booted a fresh build of drm-tip as suggested in
> https://bugs.freedesktop.org/show_bug.cgi?id=99344#c13.
> 
> 
> $ dmesg | grep fifo 
> [    5.549241] [drm:intel_cpu_fifo_underrun_irq_handler [i915]] *ERROR* CPU
> pipe A FIFO underrun
> 
> $ cat /proc/version
> Linux version 5.2.0-rc4+ (nick@nick-Blade-Stealth) (clang version 9.0.0
> (https://github.com/llvm/llvm-project.git
> 80fee25776c2fb61e74c1ecb1a523375c2500b69)) #32 SMP Sat Jun 15 17:34:43 PDT
> 2019
> 
> $ cd linux
> $ git show -1
> commit 39e3d39be374d48ba73b61ec34f19a0afd5ac6f4 (HEAD -> drm-tip,
> drm-tip/drm-tip)
> Author: Matt Roper <matthew.d.roper@intel.com>
> Date:   Sat Jun 15 08:21:37 2019 -0700
> 
>     drm-tip: 2019y-06m-15d-15h-20m-54s UTC integration manifest
> ...

The impact of this issue is screen flickering? or blank screen? or both? How often it happens? Asking this to know the severity of this issue.
Comment 24 Nick Desaulniers 2019-06-18 02:21:31 UTC
(In reply to Lakshmi from comment #23)
> The impact of this issue is screen flickering? or blank screen? or both?

Flickering

> How often it happens?

Once or twice per minute; pretty distracting/hard to use.

Thanks for taking a look; let me know what else I can to do help.  I will bring my laptop to Intel @ Santa Clara and sit with any kernel folks if necessary.
Comment 25 Lakshmi 2019-06-25 08:16:51 UTC
@Ville, any thoughts based on the latest feedback from BIOS 8.2?
Comment 26 Ville Syrjala 2019-06-25 12:08:47 UTC
No good ideas atm. I think there are a few other people with Razer Blade something or another laptops that have similar issues.

A fresh dmesg with drm.debug=0xe from latest drm-tip might show us a bit more information (at least it would dump out more of the watermark state).
Comment 27 Lakshmi 2019-07-15 10:13:53 UTC
@Nick, As Ville suggested can you please provide the dmesg with drm.debug=0xe from latest drm-tip (https://cgit.freedesktop.org/drm-tip)?
Comment 28 Lakshmi 2019-08-27 10:52:31 UTC
(In reply to Lakshmi from comment #27)
> @Nick, As Ville suggested can you please provide the dmesg with
> drm.debug=0xe from latest drm-tip (https://cgit.freedesktop.org/drm-tip)?

No feedback for more than a month. Dropping the priority to Medium.
Comment 29 Martin Peres 2019-11-29 18:00:42 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/drm/intel/issues/190.

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.