Bug 97619

Summary: Rotated Display Output Fractured
Product: xorg Reporter: klsu
Component: Driver/RadeonAssignee: xf86-video-ati maintainers <xorg-driver-ati>
Status: RESOLVED FIXED QA Contact: Xorg Project Team <xorg-team>
Severity: normal    
Priority: medium    
Version: unspecified   
Hardware: x86 (IA32)   
OS: Linux (All)   
Whiteboard:
i915 platform: i915 features:
Attachments:
Description Flags
Output of sudo lspci -vv for one machine with the described problem.
none
Most recent Xorg log file
none
XUbuntu Boot Splash screen (note broken mouse).
none
XUbuntu Logon Screen shows the problem even with a solid background.
none
Desktop after loging on.
none
Desktop after logging on, as seen by Print Screen. none

Description klsu 2016-09-06 22:51:35 UTC
Created attachment 126256 [details]
Output of sudo lspci -vv for one machine with the described problem.

Because this one is hard to describe, it has taken a long time to find anyone else with the problem, but here it is:
http://askubuntu.com/questions/783358/visual-glitches-when-rotating-display-ati-radeon

The problem appeared after upgrading to XUbuntu 16.04 on 2 32-bit Pentium 4 machines. Any display that is rotated becomes unintelligible because it is not delivered to the display properly, and I cannot send a screen shot because the screen shot records what should be on the screen, not what is displayed. On this machine I have 2 monitors, one 1920x1080 horizontal, and one to the right, 1280x1024 rotated 90 degrees clockwise with the picture must be rotated left. The horizontal monitor displays normally, the picture on the rotated one is divided into 128 vertical bands, 8 pixels wide, and the vertical bands appear to be divided into 40 segments 32 pixels high. The vertical bands do not always contain information that belongs with the bands adjacent to them, but possibly with the bands one band away on each side (reminds me of an interlace pattern). The vertical blocks containing information that might belong to blocks above and below them are also alternated with blocks containing other information, and appear to be stretched vertically (2x?). Knowing what the background picture is, I recognized 8x32 pixel pieces, but the picture is so fractured as to be unrecognizable. If I open a window on the rotated display, it is so fractured and stretched that I cannot tell where the top of the window is, and if I slide an open window from the left desktop to the rotated one so the "x" (in the close window button) appears on the rotated screen, the "x" first appears on the second 8 pixel vertical band from the left. If I slowly move the window down, the "X" moves down twice as fast and skips 32 pixel vertical blocks on the way down. When it leaves the bottom of the screen, it appears at the top in the left most 8 pixel band and moves down without skipping blocks (but still at twice the speed the windows is moving down). As soon as any part of the window appears on the rotated screen, moving the window is no longer smooth. The mouse does NOT behave strangely on the rotated screen, and if a window opens on the rotated screen, and I move the mouse slowly down the screen until it changes shape (as it crosses the top edge) and then changes back, I can click and drag the window to the left display where I can work with it. The mouse arrow does NOT move down the rotated display twice as fast as it would on the left display, so when it changes shape as I cross onto a window, any recognizable elements of that window are twice as far down the display as the mouse arrow. As I said, a screen shot shows the rotated monitor as it would be if the driver were working properly.

This is not a hardware problem; the other machine only has one display, but when I use xrandr to rotate it, the display fractures as described above (for all --rotate options but "normal"). Inverting the display does not change the orientation of the 8x32 bit blocks; they still look like interlacing with the 8-bit wide bands parallel to the normal top/bottom of the display. Both machines work fine with Windows XP and worked fine until 16.04 was installed. A 64 bit installation with an NVIDIA video card does not have the problem.

I recognize that this may be a bug for the people at ATI/Radeon, but have no idea where to submit it; and I'm guessing bugs.freedesktop.org knows. I'm not even sure there's any point in providing the results of sudo lspci -vv, because since 'Print Screen' works, this has all the signs of being a problem with how the virtual desktop in memory is being sent to the display. However, for what it's worth, I've attached a copy.
Comment 1 Michel Dänzer 2016-09-07 01:47:24 UTC
Please attach the corresponding Xorg log file.

Anyway, this is probably fixed by https://cgit.freedesktop.org/xorg/driver/xf86-video-ati/commit/?id=6d91fb4fc701895473ff675f440a8eef655e80ca . Can you try a PPA which contains an xf86-video-ati Git snapshot?
Comment 2 klsu 2016-09-07 02:41:09 UTC
Created attachment 126258 [details]
Most recent Xorg log file

The attached Xord.0.log is the only Xorg log on the machine with 2 displays, and has a date stamp of the same day, so I assume it's most recent.

I'll see if I can figure out your other comments.
Comment 3 klsu 2016-09-07 03:54:38 UTC
Created attachment 126261 [details]
XUbuntu Boot Splash screen (note broken mouse).
Comment 4 klsu 2016-09-07 03:56:58 UTC
Herr Dänzer,

Using the link you provided and one I found looking for a "PPA which contains an xf86-video-ati Git snapshot":
https://cgit.freedesktop.org/xorg/driver/xf86-video-ati/commit/?id=38797a33117222dadbc89e5f21ed8cd5deef9bea

...present me with 1 and 3 files (respectively) that appear to be C (or C++) program files. It has been a good 20 years since I've compiled anything, and have never had to compile anything on a linux machine, nor have I ever had anything to do with video drivers. I understand a bit about mapping a virtual desktop to display memory, because of something I did in the late 1980s, therefore, I suspect that if whoever wrote the drivers for this sees the desktop, they'll know what's wrong. Therefore I'm attaching photos during boot, at the login screen and at the desktop, plus a screen shot of the same desktop using Print Screen.

I am not afraid to try to do whatever needs to be done, but have yet to find clear instructions on how to compile and install code on a linux machine, so I guess I'll just have to wait until the drivers in the Ubuntu PPAs for 16.04 have been updated.
Comment 5 klsu 2016-09-07 03:58:29 UTC
Created attachment 126263 [details]
XUbuntu Logon Screen shows the problem even with a solid background.
Comment 6 klsu 2016-09-07 03:59:31 UTC
Created attachment 126264 [details]
Desktop after loging on.
Comment 7 klsu 2016-09-07 04:01:42 UTC
Created attachment 126265 [details]
Desktop after logging on, as seen by Print Screen.
Comment 8 Michel Dänzer 2016-09-07 06:29:30 UTC
The commit referenced in comment 1 most likely fixes this. Please reopen this report if it doesn't.

You can try either of these PPAs: (doesn't involve compiling anything)

https://launchpad.net/~paulo-miguel-dias/+archive/ubuntu/mesa/
https://launchpad.net/~oibaf/+archive/ubuntu/graphics-drivers
Comment 9 klsu 2016-09-07 18:07:39 UTC
2 minor corrections to my previous posts: A 64 bit installation with a Radeon (not NVIDIA) video card does not have the problem. Attachment 126261 [details] XUbuntu Boot Splash screen is the wrong description; the splash occurs after logging on before the desktop is displayed.

Thank you Herr Dänzer; the solution corrects the problem on this machine. The instructions on the first link tell how to add the PPA but not what to do after that. The instructions on the second link were better; but "...update your Ubuntu with the package herein" doesn't say what the name of the package is.

sudo add-apt-repository ppa:oibaf/graphics-drivers
sudo apt-get install mesa-vdpau-drivers
...didn't install any depends or upgrades, and did not solve the problem.

So I followed the instructions for reverting to the original drivers. In a terminal I ran:
sudo add-apt-repository ppa:oibaf/graphics-drivers
Then I started the Synaptic package manager, forced it to update its package list, searched for mesa-v and found one that was shown as requiring upgrade. Marked for upgrade it and everything else that could be upgraded, and let Synaptic make the changes. After re-boot, the rotated screen displayed properly. Shouldn't the UBuntu Xenial repository be updated with this fix?

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.