[x1250] X server crashes on rotation in xf86ResizeOffscreenLinear+0x3b

Bug #276782 reported by Jim Gettys
4
Affects Status Importance Assigned to Milestone
xserver-xorg-driver-ati
Invalid
High
xserver-xorg-video-ati (Ubuntu)
Fix Released
High
Unassigned

Bug Description

Fresh bits installed 9/30 from daily image of Intrepid, onto a Dell Latitude XT (ATI x1250 GPU, IIRC).

   xrandr -o left; xrandr -o normal; xrandr -o left

Crashes the X server.

Revision history for this message
In , Jg-freedesktop (jg-freedesktop) wrote :

And as the system is very new, and doesn't have personal files on it yet, I can easily create an account if someone needs to debug remotely...

Revision history for this message
In , agd5f (agd5f) wrote :

I suspect there's in issue with the xrandr 1.1 compatibility stuff in the xserver since you are using xrandr -o and your laptop has several outputs. Do you still get the crash if you specify the rotation with xrandr 1.2 API calls?

xrandr --output LVDS --rotate left

Revision history for this message
In , Jg-freedesktop (jg-freedesktop) wrote :

Still dies with a sequence of

xrandr --output LVDS --rotate left
xrandr --output LVDS --rotate right
xrandr --output LVDS --rotate normal
xrandr --output LVDS --rotate inverted

After some number of these, the X server is still crashing...

Revision history for this message
In , agd5f (agd5f) wrote :

Can you start the xserver in gdb rather than attaching to the running process? It'd be nice to get a backtrace. Unfortunately, I can't reproduce it here. It looks like it may be related the dixLookupPrivate changes.

Revision history for this message
In , Jg-freedesktop (jg-freedesktop) wrote :
Download full text (4.7 KiB)

OK, that worked. Here's the backtrace...

#0 dixLookupPrivate (privates=0x198, key=0x81df2d8)
    at ../../dix/privates.c:131
 rec = <value optimized out>
 ptr = <value optimized out>
#1 0x080c871b in xf86ResizeOffscreenLinear (resize=0x96a7c58, size=1024000)
    at ../../../../hw/xfree86/common/xf86fbman.c:199
No locals.
#2 0xb79f0f77 in radeon_allocate_memory (pScrn=0x968bf58,
    mem_struct=0x96a6480, size=4096000, align=4096)
    at ../../src/radeon_memory.c:61
 linear = <value optimized out>
 pScreen = (ScreenPtr) 0x96a8458
 info = <value optimized out>
 offset = <value optimized out>
#3 0xb7a1615e in radeon_crtc_shadow_allocate (crtc=0x96a62a0, width=1280,
    height=800) at ../../src/radeon_crtc.c:421
 pScrn = (ScrnInfoPtr) 0x198
 rotate_offset = <value optimized out>
#4 0x080f40c8 in xf86CrtcRotate (crtc=0x96a62a0, mode=0xbfa89870, rotation=4)
    at ../../../../hw/xfree86/modes/xf86Rotate.c:607
 shadowData = <value optimized out>
 shadow = (PixmapPtr) 0x0
 width = 1280
 height = 800
 old_width = 0
 old_height = 0
 pScrn = <value optimized out>
 pScreen = (ScreenPtr) 0x96a8458
 crtc_to_fb = {matrix = {{-65536, 0, 83886080}, {0, -65536, 52428800}, {
      0, 0, 65536}}}
 fb_to_crtc = {matrix = {{-65536, 0, 83886080}, {0, -65536, 52428800}, {
      0, 0, 65536}}}
#5 0x080eb243 in xf86CrtcSetMode (crtc=0x96a62a0, mode=0xbfa89870,
    rotation=408, x=0, y=0) at ../../../../hw/xfree86/modes/xf86Crtc.c:312
 scrn = (ScrnInfoPtr) 0x968bf58
 i = <value optimized out>
 ret = <value optimized out>
 didLock = 0
 adjusted_mode = (DisplayModePtr) 0x9897d40
 saved_mode = {prev = 0x0, next = 0x0, name = 0x0, status = MODE_OK,
  type = 0, Clock = 71450, HDisplay = 1280, HSyncStart = 1301,
  HSyncEnd = 1333, HTotal = 1460, HSkew = 0, VDisplay = 800, VSyncStart = 804,
  VSyncEnd = 808, VTotal = 816, VScan = 0, Flags = 10, ClockIndex = 0,
  SynthClock = 0, CrtcHDisplay = 1280, CrtcHBlankStart = 1280,
  CrtcHSyncStart = 1301, CrtcHSyncEnd = 1333, CrtcHBlankEnd = 1460,
  CrtcHTotal = 1460, CrtcHSkew = 0, CrtcVDisplay = 800, CrtcVBlankStart = 800,
   CrtcVSyncStart = 804, CrtcVSyncEnd = 808, CrtcVBlankEnd = 816,
  CrtcVTotal = 816, CrtcHAdjusted = 0, CrtcVAdjusted = 0, PrivSize = 0,
  Private = 0x0, PrivFlags = 0, HSync = 0, VRefresh = 0}
 saved_x = 0
 saved_y = 0
 saved_rotation = 1
#6 0x080f2582 in xf86RandR12CrtcSet (pScreen=0x96a8458, randr_crtc=0x96a90a8,
    randr_mode=0x96a9930, x=0, y=0, rotation=408, num_randr_outputs=1,
    randr_outputs=0xbfa89a30) at ../../../../hw/xfree86/modes/xf86RandR12.c:769
 mode = {prev = 0x0, next = 0x0, name = 0x0, status = MODE_OK,
  type = 0, Clock = 71450, HDisplay = 1280, HSyncStart = 1301,
  HSyncEnd = 1333, HTotal = 1460, HSkew = 0, VDisplay = 800, VSyncStart = 804,
  VSyncEnd = 808, VTotal = 816, VScan = 0, Flags = 10, ClockIndex = 0,
  SynthClock = 0, CrtcHDisplay = 1280, CrtcHBlankStart = 1280,
  CrtcHSyncStart = 1301, CrtcHSyncEnd = 1333, CrtcHBlankEnd = 1460,
  CrtcHTotal = 1460, CrtcHSkew = 0, CrtcVDisplay = 800, CrtcVBlankStart = 800,
  CrtcVSyncStart = 804, CrtcVSyncEnd = 808, CrtcVBlankEnd = 816,
  CrtcVTotal = 816, CrtcHAdjusted = 0, CrtcVAdjusted = 0, PrivSize = 0,
  Privat...

Read more...

Revision history for this message
Jim Gettys (jg-laptop) wrote : X server crashes on rotation with ATI driver.

Fresh bits installed 9/30 from daily image of Intrepid, onto a Dell Latitude XT (ATI x1250 GPU, IIRC).

   xrandr -o left; xrandr -o normal; xrandr -o left

Crashes the X server.

Revision history for this message
Jim Gettys (jg-laptop) wrote :
Revision history for this message
Bryce Harrington (bryce) wrote : Re: X server crashes on rotation in xf86ResizeOffscreenLinear+0x3b

Hi Jim, thanks.

Backtrace:
0: /usr/X11R6/bin/X(xf86SigHandler+0x79) [0x80c3069]
1: [0xb806b400]
2: /usr/X11R6/bin/X(xf86ResizeOffscreenLinear+0x3b) [0x80c871b]
3: /usr/lib/xorg/modules/drivers//radeon_drv.so [0xb7ad7f77]
4: /usr/lib/xorg/modules/drivers//radeon_drv.so [0xb7afd15e]
5: /usr/X11R6/bin/X(xf86CrtcRotate+0x328) [0x80f40c8]
6: /usr/X11R6/bin/X(xf86CrtcSetMode+0x403) [0x80eb243]
7: /usr/X11R6/bin/X [0x80f2582]
8: /usr/X11R6/bin/X(RRCrtcSet+0x96) [0x816ce96]
9: /usr/X11R6/bin/X(ProcRRSetScreenConfig+0x4db) [0x8171f1b]
10: /usr/X11R6/bin/X [0x816b5a5]
11: /usr/X11R6/bin/X(Dispatch+0x34f) [0x808c91f]
12: /usr/X11R6/bin/X(main+0x47d) [0x8071d8d]
13: /lib/tls/i686/cmov/libc.so.6(__libc_start_main+0xe5) [0xb7c75685]
14: /usr/X11R6/bin/X [0x8071171]
Saw signal 11. Server aborting.
(II) PS/2 Generic Mouse: Close
(II) UnloadModule: "evdev"
(II) Video Bus: Close
(II) UnloadModule: "evdev"
(II) Video Bus: Close
(II) UnloadModule: "evdev"
(II) UnloadModule: "wacom"
(II) AT Translated Set 2 keyboard: Close
(II) UnloadModule: "evdev"
(II) Macintosh mouse button emulation: Close
(II) UnloadModule: "evdev"
Output 23 disable success
Blank CRTC 0 success
Disable CRTC 0 success
Blank CRTC 1 success
Disable CRTC 1 success
(II) RADEON(0): RADEONRestoreMemMapRegisters() :
(II) RADEON(0): MC_FB_LOCATION : 0x7fff7000 0x7fff7000
(II) RADEON(0): MC_AGP_LOCATION : 0x00000000
(II) RADEON(0): avivo_restore !
Enable CRTC 0 success
Unblank CRTC 0 success

Changed in xserver-xorg-video-ati:
importance: Undecided → High
status: New → Triaged
Revision history for this message
Bryce Harrington (bryce) wrote :

I did not reproduce the issue on a Dell XPS 1640 with an HD 3670 [1002:95:93]

There's two places in the -ati source where xf86ResizeOffscreenLinear gets called. It would be very useful to see a full backtrace on this crash, to see what values are getting passed across and which of the two paths are getting executed.

Would you mind reproducing this crash and collecting a full backtrace? Directions to do this are at http://wiki.ubuntu.com/X/Backtracing. Basically, install xserver-xorg-video-ati-dbg andxserver-xorg-core-dbg, run Xorg from either the console or an ssh session, and do 'backtrace full' at the gdb prompt after making it crash. Thanks ahead of time!

Changed in xserver-xorg-video-ati:
assignee: nobody → bryceharrington
Revision history for this message
Jim Gettys (jg-laptop) wrote :

Unfortunately, having set up for debugging, I get a crash if running normally, and a black screen (but the X server living on) when running attached from gdb...

Sigh... I tried...

Revision history for this message
Bryce Harrington (bryce) wrote :

Hi Jim,

I've forwarded the bug upstream to https://bugs.freedesktop.org/show_bug.cgi?id=17859. Would you mind subscribing to that bug in case they need additional information or wish you to test something?

Worse comes to worse, we can just patch up the driver with some print statements to see what's going on, but let's see what upstream has to say; they may already be able to discern the issue based on the limited backtrace.

Revision history for this message
In , Jg-freedesktop (jg-freedesktop) wrote :

FWIW: this time, before crashing, it put some trash on the screen; clearly pixmaps that don't belong on the screen....

Something is trashing memory allocation.

Changed in xserver-xorg-driver-ati:
status: Unknown → Confirmed
Revision history for this message
Wouter Stomp (wouterstomp-deactivatedaccount) wrote : Re: X server crashes on rotation in xf86ResizeOffscreenLinear+0x3b

I don't know if it is the same, but on my system with an HD3200 only running xrandr -o left freezes the whole system.

Revision history for this message
In , Michel-tungstengraphics (michel-tungstengraphics) wrote :

Does this also happen with EXA rather than XAA?

Revision history for this message
Bryce Harrington (bryce) wrote : Re: X server crashes on rotation in xf86ResizeOffscreenLinear+0x3b

Here's a version of the driver with some print statements. This might help give us more info - it prints out to Xorg.0.log. Install it, restart X, reproduce the crash, and post the resulting Xorg.0.log here.

http://www.bryceharrington.org/ubuntu/Ati/ *bug276782*deb

Revision history for this message
In , Jg-freedesktop (jg-freedesktop) wrote :

Yes. Still crashes.

Revision history for this message
Jim Gettys (jg-laptop) wrote : Re: X server crashes on rotation in xf86ResizeOffscreenLinear+0x3b

OK, here it is.

Note, in one rotation, before crashing, (xrandr -o right), the frame buffer origin was in the wrong
location. (top left origin of the screen was most of the way across the screen).

Revision history for this message
Bryce Harrington (bryce) wrote :

Thanks, unfortunately that log doesn't have the crash nor any of the new debug statements; perhaps there's another log?

Try grep xf86ResizeOffscreenLinear /var/log/X*

Revision history for this message
Wouter Stomp (wouterstomp-deactivatedaccount) wrote :

Do you also have 64 bit packages? Or should I open a different bug?

Revision history for this message
Bryce Harrington (bryce) wrote :

@Wouter - Here you are:

http://www.bryceharrington.org/ubuntu/Ati/ *~bug276782_amd64.deb

Revision history for this message
Wouter Stomp (wouterstomp-deactivatedaccount) wrote :

Ok, here are my log files with the debug debs and a screenshot of when the pc freezes.

Revision history for this message
Wouter Stomp (wouterstomp-deactivatedaccount) wrote :
Revision history for this message
Wouter Stomp (wouterstomp-deactivatedaccount) wrote :
Revision history for this message
Wouter Stomp (wouterstomp-deactivatedaccount) wrote :

grep xf86ResizeOffscreenLinear /var/log/X* returns nothing for me.

Revision history for this message
In , agd5f (agd5f) wrote :

if you are running a git based version of ati can you try again with 6.9.0?

Revision history for this message
Bryce Harrington (bryce) wrote : Re: X server crashes on rotation in xf86ResizeOffscreenLinear+0x3b

Wouter, were you ever getting the crash in xf86ResizeOffscreenLinear error that jg was? If not, then maybe you're seeing a different bug.

Revision history for this message
Wouter Stomp (wouterstomp-deactivatedaccount) wrote :

As the whole system freezes and I don't get any output at all, I can't tell. I don't see that error message in xorg.0.log so I guess I should open a different bug then.

Revision history for this message
goto (gotolaunchpad) wrote :

Wouter: I have an onboard radeon hd3200 and here it freezes the whole system, too. Let's open a new bug.

Revision history for this message
goto (gotolaunchpad) wrote :

Ah, there is already a bug. Only for the log: Bug 277831

Bryce Harrington (bryce)
Changed in xserver-xorg-video-ati:
assignee: bryceharrington → nobody
Revision history for this message
Flemming Bjerke (flem) wrote :

I have a similar problem:
...
II) RADEON(0): Output: DVI-0, Detected Monitor Type: 0
(II) RADEON(0): Output: S-video, Detected Monitor Type: 0

Backtrace:
0: /usr/bin/X(xf86SigHandler+0x79) [0x80c3009]
1: [0xffffe420]
2: [0xffffe420]
3: /usr/bin/X(WriteToClient+0x128) [0x8133668]
4: /usr/bin/X(ProcGetImage+0x5d1) [0x808a7d1]
5: /usr/bin/X(Dispatch+0x34f) [0x808c89f]
6: /usr/bin/X(main+0x47d) [0x8071d1d]
7: /lib/tls/i686/cmov/libc.so.6(__libc_start_main+0xe5) [0xb7b30685]
8: /usr/bin/X [0x8071101]
Saw signal 11. Server aborting.

Revision history for this message
Flemming Bjerke (flem) wrote :
Revision history for this message
Flemming Bjerke (flem) wrote :
Revision history for this message
Flemming Bjerke (flem) wrote :
Revision history for this message
Flemming Bjerke (flem) wrote :
Bryce Harrington (bryce)
tags: added: crash
Bryce Harrington (bryce)
tags: added: intrepid
Revision history for this message
In , agd5f (agd5f) wrote :

Is this still an issue with xf86-video-ati from git master or a newer xserver?

Revision history for this message
Bryce Harrington (bryce) wrote :

[This is an automatic notification.]

Hi Jim,

This bug was reported against an earlier version of Ubuntu, can you
test if it still occurs on Lucid?

Please note we also provide technical support for older versions of
Ubuntu, but not in the bug tracker. Instead, to raise the issue through
normal support channels, please see:

    http://www.ubuntu.com/support

If you are the original reporter and can still reproduce the issue on
Lucid, please run the following command to refresh the report:

  apport-collect 276782

If you are not the original reporter, please file a new bug report, so
we can work with you as the original reporter instead (you can reference
bug 276782 in your report if you think it may be related):

  ubuntu-bug xorg

If by chance you can no longer reproduce the issue on Lucid or if you
feel it is no longer relevant, please mark the bug report 'Fix Released'
or 'Invalid' as appropriate, at the following URL:

  https://bugs.launchpad.net/ubuntu/+bug/276782

Changed in xserver-xorg-video-ati (Ubuntu):
status: Triaged → Incomplete
tags: added: needs-retested-on-lucid-by-june
Revision history for this message
Jim Gettys (jg-laptop) wrote :

Bryce,

When I tried Beta 1 on this machine, I was able to install with kms disabled only. Didn't think to try rotation.

Beta 2 wouldn't even install either ums or kms.

I haven't tried to install the final release. I might or might not be able to try to do that next week (I'm travelling, and don't have that machine with me); won't be back before the weekend.

Revision history for this message
Maarten Wisse (wisseaanen) wrote :

I'm not sure where to post this, but I've been switching yesterday from Karmic to Lucid (upgrade of Kubuntu) and I have a X1250 on a Medion E1315 netbook (1366x768). I noticed serious instability after upgrading. VT switching crashed X and trying to run KRandR crashed X immediately on startup of KRandR. On Karmic, I had KMS swithed on (at least I never did anything to switch it off), and no regular crashes, but on Lucid, X was too unstable. I switched kernel mode setting off by adding options radeon modesetting=0 in /etc/modprobe.d/radeon-kms.conf and running update-initramfs -u afterwards. This solved all the stability problems. I've not seen a single crash after that. It seems that X is even faster than before.

What I wonder about is why KMS is enabled on ATI if there are still so many problems with it. X on an Ubuntu desktop should be (almost) completely crash-free. You know, the very reason why I use Linux and not Windows is that Windows always crashed in the video drivers...

Revision history for this message
Jim Gettys (jg-laptop) wrote :

Bryce,

A cursory test showed rotation working on the Dell Latitude XT with the 10.04 release.

The RS600 in the Dell does not work with KMS; at least I'm back to where I was in Beta 1, and was able to install, but also with working rotation. I'll probably give it a better workout over the weekend than the trivial testing I did.

My daughter is now using that machine much more than I would, so at least it will get a work out.

Bryce Harrington (bryce)
tags: added: hardy
Changed in xserver-xorg-driver-ati:
importance: Unknown → High
Changed in xserver-xorg-driver-ati:
importance: High → Unknown
status: Confirmed → Invalid
Changed in xserver-xorg-driver-ati:
importance: Unknown → High
Revision history for this message
Timo Aaltonen (tjaalton) wrote :

closing, since it appears to be fixed.

Changed in xserver-xorg-video-ati (Ubuntu):
status: Incomplete → 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.