Bug 107625 - external display stops working with error: pipe state doesn't match!
Summary: external display stops working with error: pipe state doesn't match!
Status: CLOSED WORKSFORME
Alias: None
Product: DRI
Classification: Unclassified
Component: DRM/Intel (show other bugs)
Version: XOrg git
Hardware: x86-64 (AMD64) Linux (All)
: high normal
Assignee: Intel GFX Bugs mailing list
QA Contact: Intel GFX Bugs mailing list
URL:
Whiteboard: Triaged
Keywords:
Depends on:
Blocks: 105980
  Show dependency treegraph
 
Reported: 2018-08-20 12:13 UTC by Evgheni Dereveanchin
Modified: 2018-10-24 11:50 UTC (History)
3 users (show)

See Also:
i915 platform: HSW
i915 features: display/DP


Attachments
dmesg outout around issue (1.66 MB, text/plain)
2018-08-31 14:36 UTC, Evgheni Dereveanchin
no flags Details

Description Evgheni Dereveanchin 2018-08-20 12:13:24 UTC
I've got a ThinkPad w541 attached to a docking station that sometimes fails to activate external displays (after unlocking the station while it stayed docked).

The following pops up in dmesg:

[267945.537623] [drm:intel_set_cpu_fifo_underrun_reporting [i915]] *ERROR* uncleared fifo underrun on pipe C
[267945.537659] [drm:intel_cpu_fifo_underrun_irq_handler [i915]] *ERROR* CPU pipe C FIFO underrun
[267945.562674] [drm:pipe_config_err [i915]] *ERROR* mismatch in pixel_rate (expected 148500, found 296999)
[267945.562709] [drm:pipe_config_err [i915]] *ERROR* mismatch in shared_dpll (expected 00000000ce43ecf6, found 000000004d1cde9a)
[267945.562762] [drm:pipe_config_err [i915]] *ERROR* mismatch in base.adjusted_mode.crtc_clock (expected 148500, found 296999)
[267945.562785] [drm:pipe_config_err [i915]] *ERROR* mismatch in port_clock (expected 270000, found 540000)
[267945.562788] ------------[ cut here ]------------
[267945.562789] pipe state doesn't match!
[267945.562838] WARNING: CPU: 6 PID: 1590 at /build/linux-eHSiSv/linux-4.17.14/drivers/gpu/drm/i915/intel_display.c:11614 intel_atomic_commit_tail+0xc55/0xcc0 [i915]
[267945.562839] Modules linked in: fuse tun devlink ebtable_filter ebtables ip6table_filter ip6_tables iptable_filter ipmi_devintf ipmi_msghandler bridge stp llc bnep openvswitch nsh nf_conntrack_ipv6 nf_nat_ipv6 nf_conntrac
k_ipv4 nf_defrag_ipv4 nf_nat_ipv4 nf_defrag_ipv6 nf_nat nf_conntrack binfmt_misc intel_rapl arc4 x86_pkg_temp_thermal intel_powerclamp coretemp snd_hda_codec_hdmi iwlmvm btusb btrtl btbcm kvm_intel btintel wmi_bmof mac80211 
uvcvideo nouveau bluetooth snd_hda_codec_realtek videobuf2_vmalloc kvm videobuf2_memops snd_hda_codec_generic videobuf2_v4l2 i915 videobuf2_common irqbypass iwlwifi mxm_wmi videodev drbg intel_cstate ansi_cprng joydev ttm sn
d_hda_intel intel_uncore media serio_raw pcspkr drm_kms_helper iTCO_wdt evdev sg snd_hda_codec ecdh_generic iTCO_vendor_support intel_rapl_perf
[267945.562882]  cfg80211 snd_hda_core drm snd_hwdep snd_pcm mei_me i2c_algo_bit snd_timer shpchp mei ie31200_edac thinkpad_acpi nvram wmi tpm_tis snd soundcore tpm_tis_core rfkill battery tpm ac rng_core video pcc_cpufreq b
utton nfsd auth_rpcgss nfs_acl lockd grace parport_pc ppdev lp sunrpc parport ip_tables x_tables autofs4 ext4 crc16 mbcache jbd2 fscrypto ecb btrfs zstd_decompress zstd_compress xxhash algif_skcipher af_alg hid_generic usbhi
d hid dm_crypt dm_mod raid10 raid456 async_raid6_recov async_memcpy async_pq async_xor async_tx xor raid6_pq libcrc32c crc32c_generic raid1 raid0 multipath linear md_mod sr_mod cdrom sd_mod crct10dif_pclmul crc32_pclmul crc3
2c_intel ghash_clmulni_intel pcbc ahci libahci xhci_pci aesni_intel sdhci_pci ehci_pci aes_x86_64 libata cqhci crypto_simd xhci_hcd ehci_hcd
[267945.562941]  cryptd glue_helper sdhci lpc_ich psmouse scsi_mod i2c_i801 usbcore mmc_core e1000e usb_common thermal
[267945.562952] CPU: 6 PID: 1590 Comm: Xorg Not tainted 4.17.0-2-amd64 #1 Debian 4.17.14-1
[267945.562953] Hardware name: LENOVO 20EGS0R60R/20EGS0R60R, BIOS GNET85WW (2.33 ) 12/07/2017
[267945.562977] RIP: 0010:intel_atomic_commit_tail+0xc55/0xcc0 [i915]
[267945.562978] RSP: 0018:ffffbaa882a0fb90 EFLAGS: 00010282
[267945.562979] RAX: 0000000000000000 RBX: 0000000000000002 RCX: 0000000000000006
[267945.562980] RDX: 0000000000000007 RSI: 0000000000000096 RDI: ffff95123e396730
[267945.562982] RBP: ffff95122abe0330 R08: 00000000000003dd R09: 0000000000000004
[267945.562983] R10: ffffbaa882a0f9b8 R11: 0000000000000001 R12: ffff95122abe8000
[267945.562984] R13: ffff951117f09800 R14: ffff9511f4902800 R15: ffff95122abe0000
[267945.562985] FS:  00007f1fe17a2a40(0000) GS:ffff95123e380000(0000) knlGS:0000000000000000
[267945.562987] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[267945.562988] CR2: 00007f2c5d4c8084 CR3: 000000044c5de004 CR4: 00000000001606e0
[267945.562989] Call Trace:
[267945.563014]  intel_atomic_commit+0x29a/0x2d0 [i915]
[267945.563033]  drm_mode_atomic_ioctl+0x822/0x9a0 [drm]
[267945.563046]  ? drm_atomic_set_property+0x4f0/0x4f0 [drm]
[267945.563057]  drm_ioctl_kernel+0x5b/0xb0 [drm]
[267945.563067]  drm_ioctl+0x2c3/0x360 [drm]
[267945.563078]  ? drm_atomic_set_property+0x4f0/0x4f0 [drm]
[267945.563082]  do_vfs_ioctl+0xa4/0x630
[267945.563085]  ? __schedule+0x299/0x860
[267945.563087]  ksys_ioctl+0x70/0x80
[267945.563089]  __x64_sys_ioctl+0x16/0x20
[267945.563092]  do_syscall_64+0x55/0x110
[267945.563097]  entry_SYSCALL_64_after_hwframe+0x44/0xa9
[267945.563099] RIP: 0033:0x7f1fe26a8067
[267945.563100] RSP: 002b:00007ffcd0d89ee8 EFLAGS: 00003246 ORIG_RAX: 0000000000000010
[267945.563101] RAX: ffffffffffffffda RBX: 000055c94463d860 RCX: 00007f1fe26a8067
[267945.563102] RDX: 00007ffcd0d89f30 RSI: 00000000c03864bc RDI: 000000000000000e
[267945.563103] RBP: 00007ffcd0d89f30 R08: 000055c944c03610 R09: 0000000000000002
[267945.563104] R10: 0000000000000002 R11: 0000000000003246 R12: 00000000c03864bc
[267945.563105] R13: 000000000000000e R14: 0000000000000000 R15: 000055c94463d880
[267945.563107] Code: e9 da f8 ff ff e8 9c 7a ed c8 0f 0b 0f b6 44 24 18 e9 9b f8 ff ff e8 8b 7a ed c8 0f 0b 0f b6 14 24 e9 8f fd ff ff e8 7b 7a ed c8 <0f> 0b e9 32 f9 ff ff e8 6f 7a ed c8 0f 0b 49 8b 46 50 e9 f9 fd 
[267945.563139] ---[ end trace 72b891b331e25ab9 ]---


This looks somewhat similar to #105455 but opening a new bug as suggested in the bug report instructions.
Comment 1 Evgheni Dereveanchin 2018-08-20 12:17:14 UTC
xrandr output on my system when the problem is in place:

$ xrandr                                                    
Screen 0: minimum 320 x 200, current 1920 x 1080, maximum 8192 x 8192
eDP-1 connected primary 1920x1080+0+0 (normal left inverted right x axis y axis) 344mm x 193mm
   1920x1080     60.00 +  59.97*   59.96    59.93  
   1680x1050     59.95    59.88  
   1600x1024     60.17  
   1400x1050     59.98  
   1600x900      59.99    59.94    59.95    59.82  
   1280x1024     60.02  
   1440x900      59.89  
   1400x900      59.96    59.88  
   1280x960      60.00  
   1440x810      60.00    59.97  
   1368x768      59.88    59.85  
   1360x768      59.80    59.96  
   1280x800      59.99    59.97    59.81    59.91  
   1152x864      60.00  
   1280x720      60.00    59.99    59.86    59.74  
   1024x768      60.04    60.00  
   960x720       60.00  
   928x696       60.05  
   896x672       60.01  
   1024x576      59.95    59.96    59.90    59.82  
   960x600       59.93    60.00  
   960x540       59.96    59.99    59.63    59.82  
   800x600       60.00    60.32    56.25  
   840x525       60.01    59.88  
   864x486       59.92    59.57  
   800x512       60.17  
   700x525       59.98  
   800x450       59.95    59.82  
   640x512       60.02  
   720x450       59.89  
   700x450       59.96    59.88  
   640x480       60.00    59.94  
   720x405       59.51    58.99  
   684x384       59.88    59.85  
   680x384       59.80    59.96  
   640x400       59.88    59.98  
   576x432       60.06  
   640x360       59.86    59.83    59.84    59.32  
   512x384       60.00  
   512x288       60.00    59.92  
   480x270       59.63    59.82  
   400x300       60.32    56.34  
   432x243       59.92    59.57  
   320x240       60.05  
   360x202       59.51    59.13  
   320x180       59.84    59.32  
VGA-1 disconnected (normal left inverted right x axis y axis)
DP-1 disconnected (normal left inverted right x axis y axis)
HDMI-1 disconnected (normal left inverted right x axis y axis)
DP-2 disconnected (normal left inverted right x axis y axis)
HDMI-2 disconnected (normal left inverted right x axis y axis)
DP-2-1 connected (normal left inverted right x axis y axis)
   1920x1080     60.00 +  50.00    59.94  
   1680x1050     59.88  
   1400x1050     59.95  
   1600x900      60.00  
   1280x1024     75.02    60.02  
   1440x900      59.90  
   1280x960      60.00  
   1280x800      59.91  
   1152x864      75.00  
   1280x720      60.00    50.00    59.94  
   1024x768      75.03    70.07    60.00  
   832x624       74.55  
   800x600       72.19    75.00    60.32    56.25  
   720x576       50.00  
   720x480       60.00    59.94  
   640x480       75.00    72.81    66.67    60.00    59.94  
   720x400       70.08  
DP-2-2 connected (normal left inverted right x axis y axis)
   1920x1080     60.00 +  50.00    59.94  
   1680x1050     59.88  
   1400x1050     59.95  
   1600x900      60.00  
   1280x1024     75.02    60.02  
   1440x900      59.90  
   1280x960      60.00  
   1280x800      59.91  
   1152x864      75.00  
   1280x720      60.00    50.00    59.94  
   1024x768      75.03    70.07    60.00  
   832x624       74.55  
   800x600       72.19    75.00    60.32    56.25  
   720x576       50.00  
   720x480       60.00    59.94  
   640x480       75.00    72.81    66.67    60.00    59.94  
   720x400       70.08  
DP-2-3 disconnected (normal left inverted right x axis y axis)


When trying to activate one of the external displays I get this:

$ xrandr --output DP-2-2  --auto --right-of eDP-1  --verbose
screen 0: 3840x1080 1013x285 mm  96.25dpi
crtc 1:    1920x1080  60.00 +1920+0 "DP-2-2"
xrandr: Configure crtc 1 failed
crtc 0: disable
crtc 1: disable
crtc 2: disable
screen 0: revert
crtc 0: revert
crtc 1: revert
crtc 2: revert

Rebooting the system fixes the issue but it re-occurs from time to time on different kernel versions.
Comment 2 James Ausmus 2018-08-20 23:51:31 UTC
Hi Evgheni - How often does this issue reproduce?

Also, please try to reproduce the error using drm-tip (https://cgit.freedesktop.org/drm-tip) and kernel parameters drm.debug=0x1e log_buf_len=4M, and if the problem persists attach the full dmesg from boot.
Comment 3 Evgheni Dereveanchin 2018-08-23 08:31:37 UTC
Hi James, thanks for the fast reply.

I can't reliably reproduce it - pops up once in a couple of weeks (the system is always turned on). I've enabled debugging and will wait for the problem to re-occur, will share the logs here once that happens.
Comment 4 Evgheni Dereveanchin 2018-08-31 14:36:07 UTC
Created attachment 141397 [details]
dmesg outout around issue

I've not been able to catch the issue for some time and as I was constantly running out of disk space due to debug logs I decided to undock to see if that's related.

Attaching dmesg output around the period: the laptop was undocked at 712379 and docked at 712384. The fifo underrun error appeared immediately after that and both external displays stopped working. There was no kernel backtrace this time.

Software versions used are:
kernel 4.17.0-3-amd64 (Debian)
libdrm-intel1-2.4.93-1
xserver-xorg-video-intel 2.99.917+git20171229-1+b1
Comment 5 Lakshmi 2018-09-03 06:38:36 UTC
> Attaching dmesg output around the period: the laptop was undocked at 712379
> and docked at 712384. The fifo underrun error appeared immediately after
> that and both external displays stopped working. There was no kernel
> backtrace this time.

Were you able to update drm-tip to latest? is this logs from latest drm-tip?
https://cgit.freedesktop.org/drm-tip
Comment 6 Lakshmi 2018-09-07 12:41:56 UTC
Evgheni, ping?
Comment 7 Evgheni Dereveanchin 2018-09-07 12:45:40 UTC
Unfortunately I didn't have time to build a kernel and try drm-tip on it. The logs provided are from kernel 4.17.17 as shipped with Debian Unstable.
Comment 8 Lakshmi 2018-10-11 15:05:58 UTC
Evgheni, do you still have the issue with latest kernel?
Comment 9 Evgheni Dereveanchin 2018-10-16 12:29:47 UTC
I did a few tests and did not see this issue on kernel 4.18.10 and libdrm-intel1 2.4.94 so we can probably close this
Comment 10 Lakshmi 2018-10-16 12:32:49 UTC
Thanks for the feedback. Closing this bug.


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.