Bug 98148 - applying rotate-90/270 transform properties fails with "Invalid argument" on Skylake
Summary: applying rotate-90/270 transform properties fails with "Invalid argument" on ...
Status: CLOSED NOTABUG
Alias: None
Product: DRI
Classification: Unclassified
Component: DRM/Intel (show other bugs)
Version: XOrg git
Hardware: Other All
: medium normal
Assignee: Intel GFX Bugs mailing list
QA Contact: Intel GFX Bugs mailing list
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-10-07 15:14 UTC by Carlos Garnacho Parro
Modified: 2017-03-16 14:42 UTC (History)
1 user (show)

See Also:
i915 platform: SKL
i915 features: display/Other


Attachments

Description Carlos Garnacho Parro 2016-10-07 15:14:25 UTC
Mutter/gnome-shell on wayland implement output rotation through DRM properties, this method is preferred over the fallback code that performs output rotation through an intermediate offscreen framebuffer.

This however seems to fail on Skylake hardware for rotate-90 and rotate-270, the drmModeObjectSetProperty() call at [1] trying to set the "rotation" property fails with "Invalid argument" despite the two modes being previously obtained by parsing the properties at [2].

I filed https://bugzilla.gnome.org/show_bug.cgi?id=772512 to mutter in order to handle this more gracefully, there still seems to be something fishy about the "Invalid argument" errors.

[1] https://git.gnome.org/browse/mutter/tree/src/backends/native/meta-monitor-manager-kms.c#n1360
[2] https://git.gnome.org/browse/mutter/tree/src/backends/native/meta-monitor-manager-kms.c#n564
Comment 1 Chris Wilson 2016-10-07 15:20:18 UTC
rotate-90/270 requires the framebuffer output be Y-tiled. That requires teaching GBM or whatever mutter is using that it can use Y-tiling on gen9.
Comment 2 Jari Tahvanainen 2017-03-16 12:10:23 UTC
Based on closed 772512 and quick chat on IRC:intel-gfx@freenode.net marking resolved+notabug.
Comment 3 Carlos Garnacho Parro 2017-03-16 14:42:48 UTC
I forgot about this bug... you're most probably right, mutter is not doing the Y-tiling request for the affected framebuffers.

However mutter is just smart enough now to fallback to the same paths that handle portrait rotation on gen<9, I filed https://bugzilla.gnome.org/show_bug.cgi?id=780141 to handle the remaining bits after the resolution of this bug. You're welcome to chime in there, since I'm unclear how to tell gbm to enable y-tiling.


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.