Bug 88540 - [All - Bisected] slow cursor movements with atomic plane helpers
Summary: [All - Bisected] slow cursor movements with atomic plane helpers
Status: CLOSED FIXED
Alias: None
Product: DRI
Classification: Unclassified
Component: DRM/Intel (show other bugs)
Version: DRI git
Hardware: x86-64 (AMD64) Linux (All)
: medium critical
Assignee: Matt Roper
QA Contact: Intel GFX Bugs mailing list
URL:
Whiteboard:
Keywords:
: 88676 (view as bug list)
Depends on:
Blocks:
 
Reported: 2015-01-17 17:57 UTC by Rodrigo Vivi
Modified: 2017-09-04 10:28 UTC (History)
4 users (show)

See Also:
i915 platform:
i915 features:


Attachments
dmesg (227.83 KB, text/plain)
2015-01-17 17:57 UTC, Rodrigo Vivi
no flags Details

Description Rodrigo Vivi 2015-01-17 17:57:49 UTC
Created attachment 112399 [details]
dmesg

==System Environment==

--------------------------
Regression: Yes.

Non-working platforms: I've faced on BDW and BSW but I believe it can affect all platforms.

==kernel==

drm-intel-nightly: 2015y-01m-17d-09h-41m-12s UTC integration manifest

==Bug detailed description==

System gets impossible to use due very slow cursor movements.

bisect took me to the point we change to atomic plane helpers, but it can be a miss usage of atomic helpers everywhere else.

 drm/i915: Move to atomic plane helpers (v9)
    
attached dmesg shows many calls of drm_atomic_set_fb_for_plane whenever moving cursor.

[  103.143044] [drm:drm_atomic_set_fb_for_plane] Set [FB:45] for plane state ffff88009a1ce680
[  103.159720] [drm:drm_atomic_set_fb_for_plane] Set [FB:45] for plane state ffff88009a1ce300
[  103.176653] [drm:drm_atomic_set_fb_for_plane] Set [FB:45] for plane state ffff88009a1ce680
[  104.696065] [drm:drm_atomic_set_fb_for_plane] Set [NOFB] for plane state ffff88009b0a2600

==Reproduce steps==

Just boot a system with kde environment and *try* to use the cursor.
Comment 1 Jani Nikula 2015-01-19 11:16:48 UTC
See discussion in thread
http://mid.gmane.org/20150117100635.GA1281@hudson.localdomain
Comment 2 Matt Roper 2015-01-19 16:51:00 UTC
I believe this patch:
  http://lists.freedesktop.org/archives/dri-devel/2015-January/075670.html

will solve the immediate problem being reported here, at least for the existing Intel userspace I'm aware of.

The problem here is that the display server wants to update the cursor faster than the display refresh rate and we were throttling the updates to vblank.  The patch here removes that throttling for the case where the cursor is only being moved to a new position, but doesn't address the case where the cursor image changes.  If there are any userspace display servers that also try to update the cursor image to a new framebuffer while reprogramming the cursor faster than the refresh rate, they'll still see the throttling.  I'm not sure if there are any existing userspace display servers that work that way today.
Comment 3 Rodrigo Vivi 2015-01-19 18:45:53 UTC
Thanks for the fix. I hope that lands fast so we can close this bug.

Tested-by: Rodrigo Vivi <rodrigo.vivi@intel.com>r
Comment 4 Rodrigo Vivi 2015-01-20 18:32:02 UTC
Thanks for the fix
Comment 5 Rodrigo Vivi 2015-01-22 00:13:03 UTC
*** Bug 88676 has been marked as a duplicate of this bug. ***
Comment 6 Jari Tahvanainen 2017-09-04 10:28:09 UTC
Closing old verified+fixed.


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.