Display stops refreshing after rotating screen

Bug #132065 reported by cornbread on 2007-08-12
This bug affects 3 people
Affects Status Importance Assigned to Milestone
Fix Released
compiz (Ubuntu)
mesa (Ubuntu)

Bug Description

Lenovo x60 Tablet:

Rotate doesn't work out of the box when turning screen.

When I go into display resolution and rotate the screen while running compiz-fusion the screen stops refreshing and will rotate and I can see the cursor move but any clicks or drawing does not show up until rotated back to original orientation.

00:00.0 Host bridge [0600]: Intel Corporation Mobile 945GM/PM/GMS/940GML and 945GT Express Memory Controller Hub [8086:27a0] (rev 03)
            Subsystem: Lenovo Thinkpad R60e model 0657 [17aa:2017]
00:02.0 VGA compatible controller [0300]: Intel Corporation Mobile 945GM/GMS/940GML Express Integrated Graphics Controller [8086:27a2] (rev 03) (prog-if 00 [VGA])
            Subsystem: Lenovo Thinkpad R60e model 0657 [17aa:201a]

Serge (serge-de-souza) wrote :

On same hardware and under gutsy tribe-4 with all updates, I see the same thing. switching to vt1 and back to 7 leaves me with a black screen, but the mouse still moves.

After disabling compiz (add intel driver to blacklist in /sur/bin/compiz) xrandr transforms such as xrandr -o left leave the screen in a normal usable state.

Bryce Harrington (bryce) wrote :

Can you please attach your /etc/X11/xorg.conf, /var/log/Xorg.0.log, /var/log/Xorg.0.log.old files? Also the output from lspci -nnvv

Changed in compiz:
status: New → Incomplete

I am attaching the requested files. I am thankful for your attention to this issue. xorg.conf is all standard except for the emulate mouse option so the scroll button works.

cornbread (corn13read) wrote :
cornbread (corn13read) wrote :

Thanks again. anything else you need let me know.

Same thing on a Toshiba Portege M400
I have tried starting and re-starting compiz but to no avail.

attrezzo (attrezzopox) wrote :
attrezzo (attrezzopox) wrote :
attrezzo (attrezzopox) wrote :
attrezzo (attrezzopox) wrote :

the problem seems to be entirely between compiz and xrandr. When I kill compiz after screen refreshing all comes back.

Changed in compiz:
importance: Undecided → Low
status: Incomplete → Confirmed
Serge (serge-de-souza) wrote :

Using compiz 1:0.5.2+git20070918-0ubuntu5 the screen refreshes more, but if you move a window, it leaves a trail due to areas on the desktop not refreshing in places where the window used to be.

Andrew Stromme (astromme) wrote :

I'm having the same problem on a Toshiba R10 Tablet PC using the intel driver and compiz. I've had the same problem since Edgy (and Beryl).

Andrew Stromme (astromme) wrote :

I guess I can't edit my previous comment. I wanted to add that I am now running the Ubuntu Gutsy RC and the problem is still here.

zonyl (zonyl) wrote :

Same problem here with 7.10 release, HP TC4200 laptop, and Intel driver.

Just wondering why this is low? there are quite a few tablets out there and when compiz fusion is on by default you would think that this would be higher on the list...

Apart from being able to confirm the issue with gutsy on an X60 Tablet, I'd also vote for a higher importance. :) But I can see that You still have a usable machine with this, so I won't complain.

I can confirm this on a Thinkpad X41 tablet. Very annoying. I would vote for a medium importance as well.

If the mx500 back and forward buttons is high importance then this is critical. There are quite a few tablet users out there and most have intel chipsets. If compiz is enabled by default on these systems and rotate doesn't work this is major issue.

I'd vote for medium myself. The tablet IS usable just not rotated. Very annoying but we can use it. As for the mx500 ???? High??? What are they smoking????

Ryan Jarvis (cabalist) wrote :

I can also confirm this on an X41 Tablet. If compiz settings are off everything works fine. When they are on the screen appears to resize but it has two bottom panels and neither respond. I hope this gets fixed!

coulix (coulix) wrote :

Same here mac book intel 945G

I would vote this at least high if not critical status. This means that anyone with intel tablet trying to use built-in feature for Gutsy will have this issue with rotation. This issue basically affects all tablet users that want advanced desktop management features.

Judging vote for higher status based on following bugs:

148247 Compiz not supported for G965 *Critical*
22976 Live CD boots to a black screen on Blueberry G3 iMac *High*
23475 Cannot create a user "håkan" *High*

i've run into this on my X60 notebook.

compiz, rotation, screen draws: choose two.

Jesse B. Hannah (jbhannah) wrote :

Once again, confirmed on a Thinkpad X60 tablet with a fully-updated Ubuntu Gutsy. I'm amazed this is still a low-priority bug; at least within Compiz it should be high or critical.

mrnohj (mr-zigalis) wrote :

I have an Fujitsu T4215 with the Intel GMA950 and I seem to have the same problem when I send the following commands

xsetwacom set stylus Rotate cw
xrandr -o right


xsetwacom set stylus Rotate half
xrandr -o inverted


xsetwacom set stylus Rotate ccw
xrandr -o left

The screen rotates (sometimes menu bar dose not redraw) and the stylus rotates and still works except for any clicking action seems to be ignored

Changed in compiz:
status: Confirmed → Triaged
Changed in compiz:
status: Unknown → In Progress
Vincenzo Ciancia (vincenzo-ml) wrote :

I edited tom's program to rotate stylus when rotating xrandr to just run metacity when screen is rotated. See


The modified C file is:

Please note that Tom's program is a viable solution, while mine is a hack on his solution :) So you could need to modify the C file to suit your needs. However, I now just run the modified version at every login and added a randr applet to my panel, and finally can switch from normal to rotated and back, keep compiz for my everyday work, and enjoy full functionality of my tablet pc.

Tom Jaeger (thjaeger) wrote :

I've identified the problem and submitted a patch to the compiz bugtracker. For your convenience, I'm attaching an updated compiz-core package here.

Same problems with a X61T. This bug makes the tablet features unusable...

Travis Watkins (amaranth) wrote :

The proper place for this to be fixed is in mesa. Can any of you test the patch supplied in the upstream mesa bug?

Changed in compiz:
importance: Low → Medium
Changed in mesa:
importance: Undecided → High
status: New → Triaged
Tom Jaeger (thjaeger) wrote :

Instead of testing the patch directly (which would require a current mesa build environment and sounds like a major PITA), I backported the patch to the version of mesa that ubuntu is using (fwiw, I'm attaching the patch). Unfortunately, it doesn't get rid of the problem. The question now is if that's because the patch doesn't work or if there's some static linking going on and I still need to recompile other packages like the intel driver or the x server?

Travis Watkins (amaranth) wrote :

Probably both.

Tom Jaeger (thjaeger) wrote :

I recompiled both of them, but still no luck.

Changed in mesa:
status: Unknown → Confirmed
ianni67 (ianni67) wrote :

Hi everyone, I just want to provide a positive feedback:
Fujitsu-siemens convertible (both tabletpc and notebook, rotating screen) model T4220.
Ubuntu 8.04 Hardy beta.
Compiz fusion, out-of-the-box. Got artefacts when rotating the screen (to rotate the screen I use the fscd deamon to make the fujitsu buttons work).
Everything goes *fine* after installing the package posted above by Tom Jaeger (http://launchpadlibrarian.net/12687531/compiz-core_0.7.2-0ubuntu2_i386.deb).


It would be *GREAT* (I would say, _mandatory_) to add this to the official compiz distribution.

Vincenzo Ciancia (vincenzo-ml) wrote :

As usual I can't but say that the fixed posted by Tom works for me too.

cornbread (corn13read) wrote :

Fix by tom fixes no refresh problem. Compiz then runs but not near as fast. glxgears output normal aspect was 4340 frames in 5.0 seconds = 867.993 FPS and in rotated state was 595 frames in 5.0 seconds = 118.995 FPS.

Travis Watkins (amaranth) wrote :

That is to be expected, the driver has to rotate the image which slows it down.

Tom Jaeger (thjaeger) wrote :

I think that's a bug in the intel driver; from looking at the source it seemed that rotation should be hardware-accelerated as well. Hopefully this will get fixed when they move to the new infrastructure.

TechnocratiK (pdiez) wrote :

I'm running Ubuntu 8.04 beta on a Fujitsu LifeBook T4215 with and Intel 945GM. I did some unkosher testing and was able to confirm that this is not a compiz bug: using the screenshot tool (see: Applications -> Accessories -> Take Screenshot) on a 10-second delay along with a terminal window executing the command

xrandr -o right && sleep 20 && xrandr -o normal

yields a beautiful image (see attachment) of compiz running in 768x1024. So Tom's compiz fix is cool (though I haven't had the chance to recompile compiz to test it myself), but I have to agree that the solution to this problem will ultimately lie in mesa or the intel driver. If anyone's had the same problem with an ATI or nVidia card, I think that would close the book on where the fix needs to be done.

cornbread (corn13read) wrote :

when will they move to the new architecture? there was just an update to compiz core and now rotation is broken again... I'd rather have it working even if it is a hack, than to have it broken. Tom can you post instructions to recompiling with your fix? TIA

Tom Jaeger (thjaeger) wrote :

DRI2 depends on TTM, which isn't going to be integrated in the kernel before 2.6.26; so it'll probably be a while before this hits the distributions.

Building a package from source (untested):

sudo apt-get build-dep compiz-core
apt-get source compiz-core
cd compiz-co<TAB>
patch -p1 < /path/to/compizrotate.patch
dpkg-buildpackage -rfakeroot -us -uc

TechnocratiK (pdiez) wrote :

OK, so I just tried out Tom's patching method on Ubuntu 7.10. The good news: the patch works like a charm, and Tom's method for building the package is correct. The bad news: it doesn't work "out-of-the-box". I'll be brief:

- the base directory of the patch is wrong (it should be applicable to source trees in folders called something other than "compiz-0.7.0")
- compiz-0.6.0 (and I'm going to take a guess and say compiz < 0.7.0) doesn't use core.tmpRegion (see the fourth-last line of the patch file)
- applying this patch may break one of the debian compiz patches

As a warning to people wanting to try this, the build dependencies for compiz-core add up to 270 MiB installed. If you happen to be running Gutsy, I've attached the replacement package for compiz-core_0.6.0+git20071008-0ubuntu1.1_i386.deb.

Thanks a million Tom.

can you build a package for the latest compiz-core version in the Hardy RC?
Currently I have the Version: 1:0.7.4-0ubuntu5 installed.
When I have tried to install your package I got a error that the currently installed package is newer.


Tom Jaeger (thjaeger) wrote :

Revised instructions:

sudo apt-get build-dep compiz-core
apt-get source compiz-core
cd compiz<TAB>
patch -p2 < /path/to/compizrotate.patch
dpkg-buildpackage -rfakeroot -us -uc

An updated compiz-core package is attached.

ianni67 (ianni67) wrote :

Tom, the package worked perfcclly and I wish to thank you again. Let's hope that your fix gets added to the main distribution asap. :)

Tanks for this great patch and especially for the packaging :)
Works awesome...
That is what I call a "Bugfix" :) :) :)
Now I can use my Tablet....

tlawson (lawsontd) wrote :

Tom, is it possible to compile a version of this for Hardy AMD64?

cornbread (corn13read) wrote :


Tom posted the steps three comments back.

cornbread (corn13read) wrote :


Tom posted the steps three comments back.

Also just to let you guys know I have an idea that would solve these types of things from happening in the future.




After the latest compiz-core update the rotate doesn't work anymore :(
Why don't include the maintainers Toms fix in the official repository as it is a Bugfix.
It driving me nuts and I don't want to build this package everytime by myself as I need 100 of development libaries to compile....
So Tom, again, would be really cool if you can post a patched package for 1:0.7.4-0ubuntu6.
Thanks... :)

ianni67 (ianni67) wrote :

<this is not a fix>
deathrow, Synaptics allows you to force a specific version for each package (through the "package" menu, after clicking on the specific package), so why don't you force the compiz version and prevent synaptics from continuing to update your compiz, until the problem is fixed? I did it and it works for me.
<end of my 2cents>

My tablet's security chip decided to lock me out and my old computer is
still running gutsy, so I currently have no way of building an updated
package. Sorry.

deathrow wrote:
> After the latest compiz-core update the rotate doesn't work anymore :(
> 1:0.7.4-0ubuntu6
> Why don't include the maintainers Toms fix in the official repository as it is a Bugfix.
> It driving me nuts and I don't want to build this package everytime by myself as I need 100 of development libaries to compile....
> So Tom, again, would be really cool if you can post a patched package for 1:0.7.4-0ubuntu6.
> Thanks... :)

Tom: now that hardy is out we can set up a toshiba-tablet team having its own ppa, and containing all your fixes. The tabuntu distribution could then benefit of these packages. Here it is:


Please anybody who can contribute code join the team. The ppa is really easy to use and allows to provide fixes for everybody.

Thanks for working on the patch for this. I hope it will be included in the core soon.

Since you're having computer troubles, I compiled the patched version of compiz-core on the latest source (v1:0.7.4).

Here it is.

tlawson (lawsontd) wrote :

Here's an updated amd64 workaround package for compiz 0.7.4.

Brandon (brandon-dubois) wrote :

I originally stumbled across this bug a few months ago with my Thinkpad x60t when running Gutsy. I'm currently running Mandriva 2008.1, however, and am having the same issue.

Is there any way I can get a similar patch for Mandriva?

Thanks all.

Created an attachment (id=16790)
CopySubBuffer damage fix.

Compiz uses MesaCopySubBuffer to do partial screen updates. The damage that is created by this function to update the right screen region during randr rotation is wrong. The attached patch converts the y coordinate from gl coordinates to xserver coordinates to fix this problem.

Changed in compiz:
status: In Progress → Invalid

commit 377016d728ace47c9eeb3ac2f01191608ab060f6
Author: Dennis Kasprzyk <email address hidden>
Date: Thu May 29 11:24:16 2008 +0200

    Report correct damage rectangle in CopySubBuffer.

Well, the patch would work even if you run mandriva, but you'll have to find the sourcecode yourself and compile it all with this patch. I don't know exactly how mandriva works, but in ubuntu it isn't allways fun not to use the package system.

I also think that this patch should not find way to the package system, as it disables compiz, and this isn't the right way out of the problem (no offence Tom, I think it is very great that you have made this patch, and I am myself using it).



Tom Jaeger (thjaeger) wrote :

Just for clarification, the patch does not disable compiz.

This is supposed to be fixed in mesa git now ( http://gitweb.freedesktop.org/?p=mesa/mesa.git;a=commit;h=377016d728ace47c9eeb3ac2f01191608ab060f6 ), let's hope that this is actually the case this time.

can somebody post a fixed package for 1:0.7.4-0ubuntu7?
Is there maybe a ppa with fixed packages available?

Tom Jaeger (thjaeger) wrote :

The issue is fixed in intrepid now, but note bug #245888.

Jon Arnold (jonarnoldsemail) wrote :

deathrow: here is the i386 version of the package.

I don't know how to make the 64-bit version so if someone can tell me the command, i still have the source directory up and just went through a hellacious process of installing the dependents.

Thanks for the patch, Tom. Hopefully, this will not be necessary in Intrepid.

Jon Arnold (jonarnoldsemail) wrote :

I think I figured out the command to compile for amd64. This deb should work for that version.

Andrew Lofthouse (loftyhauser) wrote :

This is still a bug in intrepid. I have intrepid (fully updated as of today) installed on an HP TC4200. With compiz enabled, I rotate the display right, then back to normal and the x-server crashes. I do the same thing with compiz disabled, and there are no crashes.

Tom Jaeger (thjaeger) wrote :

The issue described here does not occur in intrepid and should be marked as fixed. What you're describing is a different bug, which appears to be fixed in the 2.5 branch of the intel driver (I don't know about 2.4.2, though).

schmolch (saschaheid) wrote :

Im using 2 X60Ts (intel 945) and i can confirm that the screen is now updating properly when rotated.

Unfortunately though the newer versions of the intel driver make a rotated screen so slow that its useless.
It does not have to be slow, it was lightning fast in Hardy with compiz and dri off.
But now its slow, its a bug:


Plz share your experiences about this if you can.

Tom Jaeger (thjaeger) wrote :

I've added package tracking the current status of the 2.5 intel driver git branch to my PPA. This fixes random X server crashes on rotate on i965 (unfortunately, the bug is not fixed in 2.4.2). Can you check if your issue is fixed in the 2.5 branch?


Vincenzo Ciancia (vincenzo-ml) wrote :

Tom: I added your ppa for hardy but in apt (from synaptic selecting your archive) I only see easystroke (very cool software for tablets!) and cellwriter, no intel driver, do you know what's up?

Vincenzo Ciancia (vincenzo-ml) wrote :

I tried to install xserver-xorg-video-intel directly from the package on the ppa page but it requires libpciaccess0 which is not availabe in hardy it seems. libdrm2 installs correctly instead.

It might be because the ppa source is for intrepid and is not supposed
to work for hardy. You will therefore have to wait until the stable
ubuntu release is out.


Vincenzo Ciancia wrote:
> I tried to install xserver-xorg-video-intel directly from the package on
> the ppa page but it requires libpciaccess0 which is not availabe in
> hardy it seems. libdrm2 installs correctly instead.

My screen properly rotates in the latest Intrepid (64-bit, kernel 2.6.27-7-generic), but I get screen artifacts. See attachment. If you can tell, I'm using Maximus and the Window Picker applet; when I unmaximize a window and drag it (I have Wobbly enabled), I get little white lines in the title area as it's being moved (which disappear once I stop dragging it).

The screen artifacts disappear after like a second, and if a window is open while screen rotating (taking up the whole screen, as I'm using Maximus) the windows properly adjust, and I get no artifacts.

Sara (sfauzia) wrote :

Also, when I'm switching windows that haven't been opened recently, I get artifacts. I tried disabling screen effects, and I had the same problem (through Appearance, not through xorg, if that counts). This is with using Tom's PPA archive packages.

Sara (sfauzia) wrote :

Correction: Minimizing compiz effects (by using Normal instead of Extra) doesn't help the problem, but disabling compiz *does*. Enabling the composite manager in Metacity works, though I would prefer compiz (and will use Metacity until this problem is resolved).

Sara (sfauzia) wrote :

Spoke too soon. I get artifacts (for a split second) when opening applications, so it's definitely not worth it to use metacity (I prefer compiz). Here is the output of my lspci, which might help troubleshoot my issue with this bug:

00:00.0 Host bridge: Intel Corporation Mobile PM965/GM965/GL960 Memory Controller Hub (rev 0c)
00:02.0 VGA compatible controller: Intel Corporation Mobile GM965/GL960 Integrated Graphics Controller (rev 0c)
00:02.1 Display controller: Intel Corporation Mobile GM965/GL960 Integrated Graphics Controller (rev 0c)
00:03.0 Communication controller: Intel Corporation Mobile PM965/GM965 MEI Controller (rev 0c)
00:03.2 IDE interface: Intel Corporation Mobile PM965/GM965 PT IDER Controller (rev 0c)
00:03.3 Serial controller: Intel Corporation Mobile PM965/GM965 KT Controller (rev 0c)
00:19.0 Ethernet controller: Intel Corporation 82566MM Gigabit Network Connection (rev 03)
00:1a.0 USB Controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #4 (rev 03)
00:1a.1 USB Controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #5 (rev 03)
00:1a.7 USB Controller: Intel Corporation 82801H (ICH8 Family) USB2 EHCI Controller #2 (rev 03)
00:1b.0 Audio device: Intel Corporation 82801H (ICH8 Family) HD Audio Controller (rev 03)
00:1c.0 PCI bridge: Intel Corporation 82801H (ICH8 Family) PCI Express Port 1 (rev 03)
00:1c.1 PCI bridge: Intel Corporation 82801H (ICH8 Family) PCI Express Port 2 (rev 03)
00:1d.0 USB Controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #1 (rev 03)
00:1d.1 USB Controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #2 (rev 03)
00:1d.7 USB Controller: Intel Corporation 82801H (ICH8 Family) USB2 EHCI Controller #1 (rev 03)
00:1e.0 PCI bridge: Intel Corporation 82801 Mobile PCI Bridge (rev f3)
00:1f.0 ISA bridge: Intel Corporation 82801HBM (ICH8M-E) LPC Interface Controller (rev 03)
00:1f.1 IDE interface: Intel Corporation 82801HBM/HEM (ICH8M/ICH8M-E) IDE Controller (rev 03)
00:1f.2 SATA controller: Intel Corporation 82801HBM/HEM (ICH8M/ICH8M-E) SATA AHCI Controller (rev 03)
00:1f.3 SMBus: Intel Corporation 82801H (ICH8 Family) SMBus Controller (rev 03)
03:00.0 Network controller: Intel Corporation PRO/Wireless 4965 AG or AGN [Kedron] Network Connection (rev 61)
05:00.0 CardBus bridge: Ricoh Co Ltd RL5c476 II (rev ba)
05:00.1 FireWire (IEEE 1394): Ricoh Co Ltd R5C832 IEEE 1394 Controller (rev 04)
05:00.2 SD Host controller: Ricoh Co Ltd R5C822 SD/SDIO/MMC/MS/MSPro Host Adapter (rev 21)

Mid while this is a real show stopper.
Today I had a presentation. I plugged in the vga- cable and the XServer crashed.
After that I logged in again and tried to put the PDF File in Fullscreen mode with evince.
Server crashed again.
There should be more effort dedicated to this Bug as it make Ubuntu unusable for presentations etc.

Bryce Harrington (bryce) on 2009-01-16
description: updated
Vincenzo Ciancia (vincenzo-ml) wrote :

Compiz is slow when screen is rotated, but for me it rotates correctly in jaunty and intrepid. Can someone confirm the bug in jaunty?

summary: - screen stops refreshing after rotating screen when running compiz fusion
+ Display stops refreshing after rotating screen
schmolch (saschaheid) wrote :

Working fine for me in current Karmic

Bryce Harrington (bryce) wrote :

Thanks for letting us know the issue is resolved.

Changed in mesa (Ubuntu):
status: Triaged → Fix Released
Changed in compiz (Ubuntu):
status: Triaged → Invalid
Changed in mesa:
status: Confirmed → Unknown
Changed in mesa:
status: Unknown → Fix Released
Changed in mesa:
importance: Unknown → Medium
Changed in mesa:
importance: Medium → Unknown
Changed in mesa:
importance: Unknown → Medium
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Remote bug watches

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