forced software cursor with PageFlip enabled triggers artifacts on screen

Bug #1870512 reported by Aleksander Miera
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
X.Org X server
Fix Released
Unknown
xorg-server (Ubuntu)
Fix Released
Medium
Unassigned

Bug Description

The following Xorg configuration triggers faulty behaviour, like blinking cursor, corrupt graphics around it etc.:

  1 Section "Device"
  2 Identifier "graphicsdriver"
  3 Driver "modesetting"
  4 Option "SWCursor" "true"
  5 #Option "PageFlip" "off"
  6 #Option "AccelMethod" "none"
  7 EndSection

Either switching SWCursor to false or uncommenting line 5 or 6 makes the issue disappear.
Disabling accelleration is naturally the least recommended way of resolving the issue.
As far as I've analyzed Xorg's source code shipped with 20.04, I can see that https://gitlab.freedesktop.org/xorg/xserver/commit/0aaac8d783e78c040a70a55ba8d67809abd7e625
which should probably automatically handle the issue (haven't tried to build with those changes yet) is not included. If it ever should be in (as it looks like a workaround only), reamains an open question.

I am not entirely sure which package to attach this bug to, Xorg seems the most viable at the moment. My reason for the uncertainty originates from the fact, that I have also tested other distros, e.g. SuSE tumbleweed (build from this week, exact versions to be added if needed) with KDE plasma, which happens to reproduce the bug only with OpenGL set as compositor's backend; XRender operates perfectly fine there; hence it is a bit unclear to me which compoment is the "owning interface" and which one is actually buggy, be it Xorg, mesa or compositor; please reassign the bug accordingly if needed.

My plan for the nearest future is to verify whether the aforementioned change actually circumvents the issue. If anything else should be looked at to fix the problem, I am open for suggestions.

ProblemType: Bug
DistroRelease: Ubuntu 20.04
Package: xserver-xorg-core 2:1.20.7-2ubuntu2
ProcVersionSignature: Ubuntu 5.4.0-21.25-generic 5.4.27
Uname: Linux 5.4.0-21-generic x86_64
ApportVersion: 2.20.11-0ubuntu21
Architecture: amd64
BootLog: Error: [Errno 13] Permission denied: '/var/log/boot.log'
CompositorRunning: None
CurrentDesktop: ubuntu:GNOME
Date: Fri Apr 3 09:41:57 2020
DistUpgraded: Fresh install
DistroCodename: focal
DistroVariant: ubuntu
ExtraDebuggingInterest: Yes, including running git bisection searches
GraphicsCard:
 Intel Corporation 4th Gen Core Processor Integrated Graphics Controller [8086:0416] (rev 06) (prog-if 00 [VGA controller])
   Subsystem: Dell 4th Gen Core Processor Integrated Graphics Controller [1028:060d]
   Subsystem: Dell GK107GLM [Quadro K1100M] [1028:060d]
InstallationDate: Installed on 2020-03-30 (4 days ago)
InstallationMedia: Ubuntu 20.04 LTS "Focal Fossa" - Alpha amd64 (20200329)
MachineType: Dell Inc. Dell Precision M3800
ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-5.4.0-21-generic root=UUID=1b7a03b4-95ff-4d1b-9897-848a0dc6f8b9 ro quiet splash vt.handoff=7
SourcePackage: xorg-server
UpgradeStatus: No upgrade log present (probably fresh install)
dmi.bios.date: 05/25/2018
dmi.bios.vendor: Dell Inc.
dmi.bios.version: A12
dmi.board.name: Dell Precision M3800
dmi.board.vendor: Dell Inc.
dmi.board.version: A12
dmi.chassis.type: 8
dmi.chassis.vendor: Dell Inc.
dmi.chassis.version: Not Specified
dmi.modalias: dmi:bvnDellInc.:bvrA12:bd05/25/2018:svnDellInc.:pnDellPrecisionM3800:pvrA12:rvnDellInc.:rnDellPrecisionM3800:rvrA12:cvnDellInc.:ct8:cvrNotSpecified:
dmi.product.name: Dell Precision M3800
dmi.product.sku: Dell Precision M3800
dmi.product.version: A12
dmi.sys.vendor: Dell Inc.
version.compiz: compiz N/A
version.libdrm2: libdrm2 2.4.100-4
version.libgl1-mesa-dri: libgl1-mesa-dri 20.0.2-1ubuntu1
version.libgl1-mesa-glx: libgl1-mesa-glx N/A
version.xserver-xorg-core: xserver-xorg-core 2:1.20.7-2ubuntu2
version.xserver-xorg-input-evdev: xserver-xorg-input-evdev N/A
version.xserver-xorg-video-ati: xserver-xorg-video-ati 1:19.1.0-1
version.xserver-xorg-video-intel: xserver-xorg-video-intel 2:2.99.917+git20190815-1
version.xserver-xorg-video-nouveau: xserver-xorg-video-nouveau 1:1.0.16-1

Revision history for this message
Aleksander Miera (amiera) wrote :
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

I'm not sure if this is a Xorg bug or a Gnome Shell (Mutter) bug so let's start with both.

Revision history for this message
Aleksander Miera (amiera) wrote :

I guess the bug on Xorg's end is pretty self-explanatory:
https://gitlab.freedesktop.org/xorg/xserver/-/issues/828
The fix for Xorg's has been smoked-tested recently, seems to be working fine.

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Can you attach a photo/screenshot of the problem? Is it similar to bug 1874856?

Revision history for this message
Aleksander Miera (amiera) wrote :

A recording would preferably be better, a screenshot might not give the full picture. Anyway, sure, I shall post it. The case I'm describing is more extreme, the squares are way bigger and flickering constantly, most of the time effectively preventing usage of the machine, such messy it gets.

Plus, is the other user also using SW cursor? In the case described here it's related purely to that.

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

I think the other bug must be using SW cursor, because otherwise it's impossible for it to affect framebuffer contents.

Revision history for this message
Aleksander Miera (amiera) wrote :

Fair point, but question is if it's software cursor from Xserver's perspective. NVidia driver might be blending the cursor in, while "emulating HW cursor" on the Xorg's end, right?

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Yeah actually I have no idea how:

  Option "SWCursor" "true"

is expected to work with compositors.

Revision history for this message
Aleksander Miera (amiera) wrote :

Adding movie depicting the problem. And it happens without actually moving the mouse, after dragging the window.

Revision history for this message
Aleksander Miera (amiera) wrote :
no longer affects: mutter (Ubuntu)
Changed in xorg-server (Ubuntu):
status: New → Triaged
importance: Undecided → Medium
tags: added: fixed-in-1.20.9 fixed-upstream
Changed in xorg-server:
status: Unknown → Fix Released
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Fixed in focal updates and all later releases.

Changed in xorg-server (Ubuntu):
status: Triaged → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.