Bug 1393264 - virtio-gpu *ERROR* [CRTC:25:crtc-0] flip_done timed out
Summary: virtio-gpu *ERROR* [CRTC:25:crtc-0] flip_done timed out
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: kernel
Version: 25
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Kernel Maintainer List
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-11-09 08:31 UTC by Marc-Andre Lureau
Modified: 2017-02-06 12:59 UTC (History)
10 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-01-30 12:19:09 UTC
Type: Bug


Attachments (Terms of Use)

Description Marc-Andre Lureau 2016-11-09 08:31:29 UTC
Description of problem:

A VM with virtio-gpu, will produce the following kernel error on display resize:


[   39.103635] ------------[ cut here ]------------
[   39.103659] WARNING: CPU: 7 PID: 67 at drivers/gpu/drm/drm_atomic_helper.c:1549 drm_atomic_helper_commit_hw_done+0xa6/0xb0 [drm_kms_helper]
[   39.103661] Modules linked in: fuse uinput nf_conntrack_netbios_ns nf_conntrack_broadcast ip6t_REJECT nf_reject_ipv6 ip6t_rpfilter xt_conntrack ip_set nfnetlink ebtable_nat ebtable_broute bridge stp llc ip6table_mangle ip6table_security ip6table_nat nf_conntrack_ipv6 nf_defrag_ipv6 nf_nat_ipv6 ip6table_raw iptable_mangle iptable_security iptable_nat nf_conntrack_ipv4 nf_defrag_ipv4 nf_nat_ipv4 nf_nat nf_conntrack iptable_raw ebtable_filter ebtables ip6table_filter ip6_tables acpi_cpufreq tpm_tis tpm_tis_core tpm snd_intel8x0 snd_ac97_codec ac97_bus crct10dif_pclmul snd_seq snd_seq_device ppdev snd_pcm virtio_gpu ttm snd_timer crc32_pclmul drm_kms_helper 9pnet_virtio drm ghash_clmulni_intel parport_pc snd 9pnet virtio_balloon parport joydev i2c_piix4 pcspkr soundcore nfsd qemu_fw_cfg auth_rpcgss nfs_acl
[   39.103798]  lockd grace sunrpc 8139too virtio_console crc32c_intel serio_raw 8139cp virtio_pci mii ata_generic virtio_ring pata_acpi virtio floppy
[   39.103822] CPU: 7 PID: 67 Comm: kworker/7:0 Tainted: G        W       4.8.0+ #2
[   39.103824] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.9.3-1.fc26 04/01/2014
[   39.103857] Workqueue: events drm_mode_rmfb_work_fn [drm]
[   39.103862]  ffffb6dbc0877c08 ffffffffbb3e48bd 0000000000000000 0000000000000000
[   39.103869]  ffffb6dbc0877c48 ffffffffbb0a156b 0000060df36a3000 0000000000000000
[   39.103874]  ffff8a71f96956c0 ffffffffc032e440 ffff8a71fb6f0678 ffff8a71f36c79c0
[   39.103880] Call Trace:
[   39.103892]  [<ffffffffbb3e48bd>] dump_stack+0x63/0x86
[   39.103896]  [<ffffffffbb0a156b>] __warn+0xcb/0xf0
[   39.103900]  [<ffffffffbb0a169d>] warn_slowpath_null+0x1d/0x20
[   39.103916]  [<ffffffffc0323b56>] drm_atomic_helper_commit_hw_done+0xa6/0xb0 [drm_kms_helper]
[   39.103927]  [<ffffffffc033fa7b>] vgdev_atomic_commit_tail+0x4b/0x60 [virtio_gpu]
[   39.103946]  [<ffffffffc03252fc>] commit_tail+0x3c/0x60 [drm_kms_helper]
[   39.103961]  [<ffffffffc03253a5>] drm_atomic_helper_commit+0x85/0xa0 [drm_kms_helper]
[   39.104003]  [<ffffffffc02e3537>] drm_atomic_commit+0x37/0x60 [drm]
[   39.104022]  [<ffffffffc0325b9d>] drm_atomic_helper_set_config+0x7d/0xb0 [drm_kms_helper]
[   39.104056]  [<ffffffffc02d1bb5>] drm_mode_set_config_internal+0x65/0x110 [drm]
[   39.104088]  [<ffffffffc02d1ee6>] drm_framebuffer_remove+0x106/0x150 [drm]
[   39.104117]  [<ffffffffc02d1f73>] drm_mode_rmfb_work_fn+0x43/0x60 [drm]
[   39.104122]  [<ffffffffbb0bb5a4>] process_one_work+0x184/0x430
[   39.104126]  [<ffffffffbb0bba16>] worker_thread+0x1c6/0x490
[   39.104130]  [<ffffffffbb0bb850>] ? process_one_work+0x430/0x430
[   39.104136]  [<ffffffffbb0c1459>] kthread+0xd9/0xf0
[   39.104141]  [<ffffffffbb0c1380>] ? kthread_worker_fn+0x180/0x180
[   39.104146]  [<ffffffffbb808ed5>] ret_from_fork+0x25/0x30
[   39.104150] ---[ end trace e36a9558d55c1954 ]---
[   49.180015] [drm:drm_atomic_helper_commit_cleanup_done [drm_kms_helper]] *ERROR* [CRTC:25:crtc-0] flip_done timed out



The fix exists upstream in 4.9 (eed6f0eda0a), it needs a small adaptation for 4.8:

diff --git a/drivers/gpu/drm/virtio/virtgpu_display.c b/drivers/gpu/drm/virtio/virtgpu_display.c
index 4e192aa..75ec172 100644
--- a/drivers/gpu/drm/virtio/virtgpu_display.c
+++ b/drivers/gpu/drm/virtio/virtgpu_display.c
@@ -338,7 +338,7 @@ static void vgdev_atomic_commit_tail(struct drm_atomic_state *state)
 
        drm_atomic_helper_commit_modeset_disables(dev, state);
        drm_atomic_helper_commit_modeset_enables(dev, state);
-       drm_atomic_helper_commit_planes(dev, state, true);
+       drm_atomic_helper_commit_planes(dev, state, false);

Comment 1 Marc-Andre Lureau 2016-11-09 08:33:22 UTC
Dave, could you take care of backport for 4.8 -stable?

Comment 2 Laura Abbott 2017-01-17 01:18:40 UTC
*********** MASS BUG UPDATE **************
We apologize for the inconvenience.  There is a large number of bugs to go through and several of them have gone stale.  Due to this, we are doing a mass bug update across all of the Fedora 25 kernel bugs.
 
Fedora 25 has now been rebased to 4.9.3-200.fc25.  Please test this kernel update (or newer) and let us know if you issue has been resolved or if it is still present with the newer kernel.
 
If you have moved on to Fedora 26, and are still experiencing this issue, please change the version to Fedora 26.
 
If you experience different issues, please open a new bug report for those.


Note You need to log in before you can comment on or make changes to this bug.