Bug 98322

Summary: QXL drm driver regression in 4.7
Product: DRI Reporter: Takashi Iwai <tiwai>
Component: DRM/otherAssignee: Default DRI bug account <dri-devel>
Status: RESOLVED INVALID QA Contact:
Severity: normal    
Priority: medium    
Version: unspecified   
Hardware: Other   
OS: All   
Whiteboard:
i915 platform: i915 features:

Description Takashi Iwai 2016-10-19 15:56:40 UTC
Since 4.7 kernel, qxl drm driver spews the errors when using VT:

 kernel: [TTM] Buffer eviction failed
 kernel: qxl 0000:00:02.0: object_init failed for (4026540032, 0x00000001)
 kernel: [drm:qxl_alloc_bo_reserved [qxl]] *ERROR* failed to allocate VRAM BO

In my test case, just install a QEMU/KVM VM with QXL interface, login GUI, and then switch to VT1.  At login there, the error appears repeatedly.

4.6 kernel works fine.

The git bisection spotted that it was introduced by
6819c3c2517604f979da3de773f2420e07dd4f4b
    drm/qxl: Use drm_fb_helper deferred_io support

This was originally reported for opensuse TW:
  https://bugzilla.suse.com/show_bug.cgi?id=1003298
Comment 1 Takashi Iwai 2016-10-20 13:16:14 UTC
OK, I found out the culprit.  It's the race of dirty update callback and the dirty clip update.  The schedule_work() in drm_fb_helper_dirty() must be inside the spinlock.  Otherwise the concurrent calls may conflict, one clears the clip while the another is called after that with the cleared clip area.

I'll post the patch soon later.
Comment 2 David C. Rankin 2016-10-21 21:41:00 UTC
I can confirm this bug remains in the 4.8 kernel as well. KVM with Archlinux guest (virt-manager defaults, except for window scaling) results in the following message displayed between every command:

[TTM] Byffer eviction failed
qxl 0000:00:02:0: object_init failed for (402650032, 0x00000001)
[drm:qxl_alloc_bo_reserved [qxl1] *ERROR* failed to allocate VRAM BO

Arch kernel package: linux-4.8.2-1-x86_64.pkg.tar.xz
Comment 3 Martin Peres 2019-10-14 13:20:10 UTC
Hi,

Freedesktop's Bugzilla instance is EOLed and open bugs are about to be migrated to http://gitlab.freedesktop.org.

To avoid migrating out of date bugs, I am now closing all the bugs that did not see any activity in the past year. If the issue is still happening, please create a new bug in the relevant project at https://gitlab.freedesktop.org/drm (use misc by default).

Sorry about the noise!

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.