radeon_dma.c:210: radeonRefillCurrentDmaRegion: Assertion `dma_bo->bo->cref == 1' failed.

Bug #459961 reported by Michael Rumpf
180
This bug affects 33 people
Affects Status Importance Assigned to Milestone
Mesa
Won't Fix
Medium
mesa (Ubuntu)
Fix Released
Medium
Unassigned
Nominated for Karmic by Antoine Derache

Bug Description

Binary package hint: rss-glx

I switched from one screensaver to another by pressing cursor-key-down.
The focus was in the screensaver list while I was searching for specific screensaver with which I wanted to reproduce another problem.
Then the screensaver crashed and the Apport application came up.

More information:
This assert was removed upstream 2009-09-20 with commit:
http://cgit.freedesktop.org/mesa/mesa/commit/?id=284a7af274bc148f112bd0ebb40583923ee26b49
and in our mesa 7.6.0-1ubuntu1, but reintroduced in 7.6.0-1ubuntu3 to fix bug 446578. Upstream has applied the same fix (reverting 284a7af27) in 7.6.1, commit:
http://cgit.freedesktop.org/mesa/mesa/commit/?h=mesa_7_6_branch&id=13b5a624b1899c457279907d58046dfb3c95addc

ProblemType: Crash
Architecture: i386
AssertionMessage: lorenz: radeon_dma.c:210: radeonRefillCurrentDmaRegion: Assertion `dma_bo->bo->cref == 1' failed.
Date: Sat Oct 24 21:04:25 2009
DistroRelease: Ubuntu 9.10
ExecutablePath: /usr/lib/xscreensaver/lorenz
Package: rss-glx 0.9.0-2ubuntu3
ProcCmdline: lorenz -r
ProcEnviron:
 PATH=(custom, no user)
 LANG=en_US.UTF-8
ProcVersionSignature: Ubuntu 2.6.31-14.48-generic
Signal: 6
SourcePackage: rss-glx
StacktraceTop:
 __kernel_vsyscall ()
 raise () from /lib/tls/i686/cmov/libc.so.6
 abort () from /lib/tls/i686/cmov/libc.so.6
 __assert_fail () from /lib/tls/i686/cmov/libc.so.6
 radeonRefillCurrentDmaRegion ()
Title: lorenz assert failure: lorenz: radeon_dma.c:210: radeonRefillCurrentDmaRegion: Assertion `dma_bo->bo->cref == 1' failed.
Uname: Linux 2.6.31-14-generic i686
UserGroups: adm admin cdrom dialout lpadmin plugdev sambashare
XsessionErrors:
 (gnome-settings-daemon:1650): GLib-CRITICAL **: g_propagate_error: assertion `src != NULL' failed
 (gnome-settings-daemon:1650): GLib-CRITICAL **: g_propagate_error: assertion `src != NULL' failed
 (nautilus:1676): Eel-CRITICAL **: eel_preferences_get_boolean: assertion `preferences_is_initialized ()' failed
 (polkit-gnome-authentication-agent-1:1716): GLib-CRITICAL **: g_once_init_leave: assertion `initialization_value != 0' failed

Revision history for this message
Michael Rumpf (miru) wrote :
Michael Rumpf (miru)
visibility: private → public
Revision history for this message
Apport retracing service (apport) wrote : Stacktrace.txt (retraced)

StacktraceTop:__kernel_vsyscall ()
*__GI_raise (sig=6)
*__GI_abort () at abort.c:92
*__GI___assert_fail (
radeonRefillCurrentDmaRegion ()

Revision history for this message
Apport retracing service (apport) wrote : ThreadStacktrace.txt (retraced)
Changed in rss-glx (Ubuntu):
importance: Undecided → Medium
tags: removed: need-i386-retrace
Revision history for this message
Dmitry Ivanov (dimss-telecentrs) wrote : Re: lorenz assert failure: lorenz: radeon_dma.c:210: radeonRefillCurrentDmaRegion: Assertion `dma_bo->bo->cref == 1' failed.

I get the same error using Google Earth after switching to ATI x1300.

Revision history for this message
lucas (lucas2) wrote :

same problem playing openarena. The game crash when i am playing.

bo(0xa7ca848, 65536) is mapped (-1) can't valide it.
validated 0xa7ca848 [0xD40F7000, 0xD40F8000]
openarena.i386: radeon_dma.c:210: radeonRefillCurrentDmaRegion: Assertion `dma_bo->bo->cref == 1' failed.
Received signal 6, exiting...
----- CL_Shutdown -----
RE_Shutdown( 1 )
bo(0xa8ef690, 65536) is mapped (-1) can't valide it.
validated 0xa8ef690 [0xD40F7000, 0xD40F8000]

Revision history for this message
Albert J. Nguyen (albertjnguyen) wrote :

Error occurred coming out of the screen saver.

Revision history for this message
Adam Buchbinder (adam-buchbinder) wrote :

It looks like this is in the Radeon driver; the error cites radeon_dma.c, and is triggered by a variety of different software packages.

I can trigger this pretty much immediately by running /usr/lib/xscreensaver/hyperspace (part of rss-glx).

affects: rss-glx (Ubuntu) → xserver-xorg-video-ati (Ubuntu)
Bryce Harrington (bryce)
tags: added: crash
affects: xserver-xorg-video-ati (Ubuntu) → mesa (Ubuntu)
Changed in mesa (Ubuntu):
status: New → Confirmed
summary: - lorenz assert failure: lorenz: radeon_dma.c:210:
- radeonRefillCurrentDmaRegion: Assertion `dma_bo->bo->cref == 1' failed.
+ radeon_dma.c:210: radeonRefillCurrentDmaRegion: Assertion
+ `dma_bo->bo->cref == 1' failed.
Revision history for this message
Tormod Volden (tormodvolden) wrote :

Can you please try and see if you get the same crash with the mesa 7.6.1 package from https://launchpad.net/~ubuntu-x-swat/+archive/x-updates or with the 2.6.32 kernel from Lucid?

Revision history for this message
Pedro Guedes (pedrobotinasguedes) wrote :

After doing what you sugested tried to run googleearth and the only message I got was: BUS error

I rebooted thePC, and I got a disk Corrupted.
After running fsck and fix all problems....I run Googleearth and still I get : Bus Error

Revision history for this message
In , Oibaf (oibaf) wrote :

After the great work of Maciej doom3 now starts fine. However after about 1 minute of play the game trigger this:

*********************************WARN_ONCE*********************************
File radeon_dma.c function radeonReleaseDmaRegions line 348
Leaking dma buffer object!
***************************************************************************

I am using current mesa_7_7_branch + the "radeon_dma.c function radeonReleaseDmaRegions line 348" fix from mesa_7_6_branch (it crashes after the WARN_ONCE without this one).

Also using standard Ubuntu 2.6.31-14.48 kernel without KMS and latest libdrm git including libdrm_radeon.

GL_RENDERER = Mesa DRI R300 (RV530 71C5) 20090101 x86/MMX/SSE2 TCL

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

(In reply to comment #0)
> After the great work of Maciej doom3 now starts fine. However after about 1
> minute of play the game trigger this:
>
> *********************************WARN_ONCE*********************************
> File radeon_dma.c function radeonReleaseDmaRegions line 348
> Leaking dma buffer object!
> ***************************************************************************
>
> I am using current mesa_7_7_branch + the "radeon_dma.c function
> radeonReleaseDmaRegions line 348" fix from mesa_7_6_branch (it crashes after
> the WARN_ONCE without this one).

Does it work without that "fix" for the 7.6 branch?

description: updated
Revision history for this message
Tormod Volden (tormodvolden) wrote :

I am not able to reproduce this on RV410 or RV515. Can all of you seeing this assertion message please report which graphics card you have by pasting in the output from "lspci -nn | grep VGA" and also tell how much video and normal RAM you have. Please also tell when (which version of mesa) you experienced this for the first time.

Changed in mesa (Ubuntu):
status: Confirmed → Incomplete
Revision history for this message
Adam Buchbinder (adam-buchbinder) wrote :

I'm running mesa 7.6.0-1ubuntu4, and have 2GiB of system memory.

$ lspci -nn|grep [V]GA
01:00.0 VGA compatible controller [0300]: ATI Technologies Inc Radeon RV100 QY [Radeon 7000/VE] [1002:5159]

I see this in my Xorg.0.log; let me know if I should be looking elsewhere to count up my video memory:

(II) RADEON(0): Detected total video RAM=32768K, accessible=65536K (PCI BAR=131072K)
(--) RADEON(0): Mapped VideoRAM: 32768 kByte (64 bit DDR SDRAM)

I first experienced this after upgrading to Karmic; the upgrade path was 7.4-0ubuntu3.2 (no problem) to 7.6.0-1ubuntu4 (problem).

Changed in mesa (Ubuntu):
status: Incomplete → Confirmed
Revision history for this message
Moritz Molch (mmolch) wrote :

I tested:
mesa 7.6.0-1ubuntu4
mesa 7.6.1-rc1 git (the one mentioned above)
kernel 2.6.31-14
kernel 2.6.32-020632rc7-generic

System Ram: 1.2 GiB

liberty@acer:~$ lspci -nn | grep VGA
01:00.0 VGA compatible controller [0300]: ATI Technologies Inc M9+ 5C61 [Radeon Mobility 9200 (AGP)] [1002:5c61] (rev 01)

liberty@acer:~$ cat /var/log/Xorg.0.log|grep RAM
(II) RADEON(0): Detected total video RAM=65536K, accessible=131072K (PCI BAR=131072K)
(--) RADEON(0): Mapped VideoRAM: 65536 kByte (128 bit DDR SDRAM)

liberty@acer:~$ glxinfo |grep renderer
OpenGL renderer string: Mesa DRI R200 (RV280 5C61) 20090101 AGP 4x x86/MMX/SSE2 TCL

While running compiz hyperspace terminates immediately after showing the first frame:

liberty@acer:~$ /usr/lib/xscreensaver/hyperspace
bo(0xa30c230, 65536) is mapped (-1) can't valide it.
validated 0xa30c230 [0xB07C2000, 0xB07D2000]
hyperspace: radeon_dma.c:210: radeonRefillCurrentDmaRegion: Assertion `dma_bo->bo->cref == 1' failed.
Aborted

Without compiz hyperspace seems to work normal but as soon as the hyperspace window is completely covered by another window the system freezes.

Openarena seems to work fine here with and without compositing.

In Jaunty (Mesa 7.4) I did NOT encountered this problem.

Revision history for this message
In , Oibaf (oibaf) wrote :

> Does it work without that "fix" for the 7.6 branch?

No, with a clean clone of 7.7 branch it asserts in a similar way to bug #24131 (see below). Apparently the "Leaking dma buffer object!" and the "Assertion `bo_legacy->is_pending <= bo->cref' failed." issues are related, and the commit:
http://cgit.freedesktop.org/mesa/mesa/commit/?h=mesa_7_6_branch&id=13b5a624b1899c457279907d58046dfb3c95addc
only hide the real problem, and make new issues appear:
https://bugs.launchpad.net/bugs/459961

*********************************WARN_ONCE*********************************
File radeon_dma.c function radeonReleaseDmaRegions line 348
Leaking dma buffer object!
***************************************************************************
doom.x86: radeon_bo_legacy.c:207: legacy_is_pending: Assertion `bo_legacy->is_pending <= bo->cref' failed.
signal caught: Aborted
si_code -6
Trying to exit gracefully..
--------- Game Map Shutdown ----------
--------------------------------------
Shutting down sound hardware
----------- Alsa Shutdown ------------
close pcm
dlclose
--------------------------------------
idRenderSystem::Shutdown()
doom.x86: radeon_bo_legacy.c:207: legacy_is_pending: Assertion `bo_legacy->is_pending <= bo->cref' failed.
double fault Aborted, bailing out
shutdown terminal support

Revision history for this message
Alessandro Berselli (a-berselli) wrote :

Launching CELESTIA:

adw@adw-laptop:~$ celestia
tipo di render: 1
bo(0x9c4aa18, 65536) is mapped (-1) can't valide it.
validated 0x9c4aa18 [0xB07C2000, 0xB07D2000]
celestia: radeon_dma.c:210: radeonRefillCurrentDmaRegion: Asserzione 'dma_bo->bo->cref == 1' fallita.
Aborted

Revision history for this message
Roman Yepishev (rye) wrote :

Happens when starting Wonderland ("Second Life"-like Sun project written in Java) shortly after the world is loaded, the VM is crashing with the following printed to the terminal.

bo(0x73cf4f78, 913408) is mapped (-1) can't valide it.
validated 0x73cf4f78 [0xD0408000, 0xD04E7000]
radeonRefillCurrentDmaRegion: Assertion `dma_bo->bo->cref == 1' failed.

01:00.0 VGA compatible controller [0300]: ATI Technologies Inc M52 [Mobility Radeon X1300] [1002:7149]
2770Mb System RAM, 128Mb video RAM.
libgl1-mesa-dri 7.6.0-1ubuntu4

Revision history for this message
Kārlis M. (mikelsk) wrote :

Similar problem here with Dell Inspiron 5100 and Google Earth.
I was going to file this under bug #459153 but since that was marked as duplicate of this one, I'll just leave it here. After this crash, the system becomes either completely unresponsive or pretty much unusable, and cannot even be shut down properly. celestia also causes the warning to appear but it does not hang the system. I do not see any problem with /usr/lib/xscreensaver/hyperspace though. Please let me know if any more information is needed.

user@abacus:~$ uname -a
Linux abacus 2.6.31-14-generic #48-Ubuntu SMP Fri Oct 16 14:04:26 UTC 2009 i686 GNU/Linux
user@abacus:~$ lspci -nn | grep VGA
01:00.0 VGA compatible controller [0300]: ATI Technologies Inc Radeon Mobility M7 LW [Radeon Mobility 7500] [1002:4c57]
user@abacus:~$ cat /var/log/Xorg.0.log|grep RAM
(II) RADEON(0): Detected total video RAM=32768K, accessible=65536K (PCI BAR=131072K)
(--) RADEON(0): Mapped VideoRAM: 32768 kByte (64 bit DDR SDRAM)
(II) Initializing built-in extension XINERAMA
user@abacus:~$ glxinfo | grep renderer
OpenGL renderer string: Mesa DRI R100 (RV200 4C57) 20090101 AGP 4x x86/MMX/SSE2 TCL
user@abacus:~$ celestia
kbuildsycoca running...
render path: 1
user@abacus:~$ *********************************WARN_ONCE*********************************
File radeon_tcl.c function radeon_run_tcl_render line 499
Rendering was 604 commands larger than predicted size. We might overflow command buffer.
***************************************************************************
user@abacus:~$ googleearth
user@abacus:~$ *********************************WARN_ONCE*********************************
File radeon_tcl.c function radeon_run_tcl_render line 499
Rendering was 421 commands larger than predicted size. We might overflow command buffer.
***************************************************************************
drmRadeonCmdBuffer: -22. Kernel failed to parse or rejected command stream. See dmesg for more info.
Google Earth has caught signal 11.

We apologize for the inconvenience, but Google Earth has crashed.
 This is a bug in the program, and should never happen under normal
 circumstances. A bug report and debugging data have been written
 to this text file:

    /home/user/.googleearth/crashlogs/crashlog-4b089fb9.txt

Please include this file if you submit a bug report will to Google.

[1]+ Exit 76 googleearth

Revision history for this message
Tormod Volden (tormodvolden) wrote :

Kārlis, please file your own bug report. Your error messages are different than in this report, please see the title/description.

Revision history for this message
Moritz Molch (mmolch) wrote :

I get those "overflow command"-messages too. But I'm not sure whether they are directly related to the "dmaRefill-thing" though. Notice, that my warning mentions the file r200_swtcl.c (I can trigger this warning wonderfully with hypertorus)

liberty@acer:~$ /usr/lib/xscreensaver/hypertorus
*********************************WARN_ONCE*********************************
File r200_swtcl.c function r200_swtcl_flush line 310
Rendering was 170 commands larger than predicted size. We might overflow command buffer.
***************************************************************************

Revision history for this message
lucas (lucas2) wrote :

Hello, i post my problem in #5.
I use ubuntu 9.10 karmic. The crash of openarena arrive only in this version of ubuntu, never with 8.04, 8.10 or 9.04 with the same computer. The crash of openarena when i am playing arrived when he want. Sometimes i can play one week without crash. I dont use compiz.

1Go of RAM
cat /proc/meminfo
MemTotal: 1026560 kB

lspci -nn | grep VGA
02:00.0 VGA compatible controller [0300]: ATI Technologies Inc RV280 [Radeon 9200 SE] [1002:5964] (rev 01)

cat /var/log/Xorg.0.log|grep RAM
(II) RADEON(0): Detected total video RAM=131072K, accessible=262144K (PCI BAR=262144K)
(--) RADEON(0): Mapped VideoRAM: 131072 kByte (64 bit DDR SDRAM)
(II) Initializing built-in extension XINERAMA

glxinfo |grep renderer
OpenGL renderer string: Mesa DRI R200 (RV280 5C61) 20090101 AGP 4x x86/MMX/SSE2 TCL

OpenGL version string: 1.3 Mesa 7.6

Revision history for this message
Tormod Volden (tormodvolden) wrote :

Is anyone able to reproduce this with the mesa 7.7 packages (you'll need the libdrm packages as well) from https://launchpad.net/~xorg-edgers/+archive/ppa ?

Revision history for this message
drfrogsplat (r-launchpad-thefrog-net) wrote :

I too have this problem:

# /usr/lib/xscreensaver/hyperspace
bo(0x2182ad0, 65536) is mapped (-1) can't valide it.
validated 0x2182ad0 [0xF47C2000, 0xF47D2000]
hyperspace: radeon_dma.c:210: radeonRefillCurrentDmaRegion: Assertion `dma_bo->bo->cref == 1' failed.

Originally saw it in ParaView, but hyperspace reproduces it more easily (in ParaView it seems to happen when I load a dataset over a certain size and try to manipulate the viewport in any way).

error is much the same from ParaView:

bo(0x36401e0, 65536) is mapped (-1) can't valide it.
validated 0x36401e0 [0xF47C2000, 0xF47D2000]
paraview-real: radeon_dma.c:210: radeonRefillCurrentDmaRegion: Assertion `dma_bo->bo->cref == 1' failed.

Some info from my system:

# uname -a
Linux Bilberry 2.6.31-15-generic #50-Ubuntu SMP Tue Nov 10 14:53:52 UTC 2009 x86_64 GNU/Linux
# cat /proc/meminfo | grep MemTotal
MemTotal: 1014032 kB
# lspci -nn | grep VGA
04:02.0 VGA compatible controller [0300]: ATI Technologies Inc Radeon RV100 QY [Radeon 7000/VE] [1002:5159]
# glxinfo | grep renderer
OpenGL renderer string: Mesa DRI R100 (RV100 5159) 20090101 NO-TCL
# glxinfo | grep "version string"
server glx version string: 1.2
client glx version string: 1.4
OpenGL version string: 1.3 Mesa 7.6
# cat /var/log/Xorg.0.log|grep RAM
(II) RADEON(0): Detected total video RAM=65536K, accessible=65536K (PCI BAR=131072K)
(--) RADEON(0): Mapped VideoRAM: 65536 kByte (64 bit DDR SDRAM)

with version 7.6.0-1ubuntu4 of libgl1-mesa-glx (and related mesa packages) installed

I've only just installed Ubuntu 9.10 and had not tested either of these apps before to know if its a new problem or not.

Revision history for this message
drfrogsplat (r-launchpad-thefrog-net) wrote :

Tormod Volden, just wondering if you're saying to try *just* the mesa 7.7 and libdrm packages from https://launchpad.net/~xorg-edgers/+archive/ppa, or if (as the xorg-edgers overview page suggests) I need to update all of X from here to have any hope if it working?

Revision history for this message
Tormod Volden (tormodvolden) wrote :

Yes, only libdrm and mesa packages. There is also a newer xserver and -ati driver there but they should not be needed, the old ones are compatible. Also testing a newer kernel (the lucid kernel) would be interesting, but please try one thing at a time first.

Revision history for this message
Roman Yepishev (rye) wrote : Re: [Bug 459961] Re: radeon_dma.c:210: radeonRefillCurrentDmaRegion: Assertion `dma_bo->bo->cref == 1' failed.

On Tue, 2009-11-24 at 19:25 +0000, Tormod Volden wrote:
> Is anyone able to reproduce this with the mesa 7.7 packages (you'll need
> the libdrm packages as well) from https://launchpad.net/~xorg-
> edgers/+archive/ppa ?

The error is not an assertion failure now:

Wonderland:
bo(0x9566890, 913408) is mapped (-1) can't valide it.
validated 0x9566890 [0xC9AC9000, 0xC9B74000]
*********************************WARN_ONCE*********************************
File radeon_dma.c function radeonReleaseDmaRegions line 348
Leaking dma buffer object!
***************************************************************************
#
# A fatal error has been detected by the Java Runtime Environment:
#
# SIGSEGV (0xb) at pc=0x8c4eedb8, pid=3182, tid=2379803504
#
# JRE version: 6.0_15-b03
# Java VM: Java HotSpot(TM) Server VM (14.1-b02 mixed mode linux-x86 )
# Problematic frame:
# C [r300_dri.so+0x48db8]

And the stack is:

Stack: [0x8dd3e000,0x8dd8f000], sp=0x8dd8d958, free space=318k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code,
C=native code)
C [r300_dri.so+0x48db8]
C [r300_dri.so+0x3b867] r300RunRenderPrimitive+0x357
C [r300_dri.so+0x2c577]
C [r300_dri.so+0xdb816]
C [r300_dri.so+0xdb99e]
C [r300_dri.so+0xd2b7e]
C [libjogl.so+0x56f5e]
Java_com_sun_opengl_impl_GLImpl_glDrawElements0__IIILjava_lang_Object_2I0x64
J com.sun.opengl.impl.GLImpl.glDrawElements0(IIILjava/lang/Object;I)V

Revision history for this message
Moritz Molch (mmolch) wrote :

I tested libdrm, mesa and ati driver from current git and get the same result as Roman while running compiz. Without compositing I do not get an error, but covering the gl window completely freezes the system.

liberty@acer:~$ /usr/lib/xscreensaver/hyperspace
bo(0x97028c8, 65536) is mapped (-1) can't valide it.
validated 0x97028c8 [0xB07C2000, 0xB07D2000]
*********************************WARN_ONCE*********************************
File radeon_dma.c function radeonReleaseDmaRegions line 348
Leaking dma buffer object!
***************************************************************************
Segmentation fault

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

I can confirm this bug.
It happened to me playing to Freespace2 fs2_open 3.6.10 and using the latest community 3.6.10 MediaVPs (3D models and other game related media files). May be related to this, most times X locks hard and I must reset the computer.
Just a note, retail Freespace2 mediaVP files do not trigger this (those?) bug(s).
Freespace2 is a nice opensourced game. The project's website provides full source code and prebuild packages: http://scp.indiegames.us/
Running opensuse 11.1 (xorg 7.4, kernel 2.6.27.37) with Mesa 7.6, Radeon 9550 card.

Revision history for this message
Benny Källström (benny-k) wrote :

Here is some info from my laptop:

benny@bennys-laptop:~$ lspci -nn | grep VGA
01:00.0 VGA compatible controller [0300]: ATI Technologies Inc Device [1002:95c2]

benny@bennys-laptop:~$ cat /var/log/Xorg.0.log|grep RAM
(II) RADEON(0): Start of VRAM area used by Firmware: 0xfffb000
(II) RADEON(0): AtomBIOS requests 20kB of VRAM scratch space
(II) RADEON(0): AtomBIOS VRAM scratch base: 0xfffb000
(II) RADEON(0): Cannot get VRAM scratch space. Allocating in main memory instead
(II) RADEON(0): Detected total video RAM=262144K, accessible=262144K (PCI BAR=262144K)
(--) RADEON(0): Mapped VideoRAM: 262144 kByte (64 bit DDR SDRAM)
(II) Initializing built-in extension XINERAMA

benny@bennys-laptop:~$ glxinfo |grep renderer
IRQ's not enabled, falling back to busy waits: 2 0
OpenGL renderer string: Mesa DRI R600 (RV620 95C2) 20090101 x86/MMX/SSE2 TCL

benny@bennys-laptop:~$ uname -a
Linux bennys-laptop 2.6.32-2-generic #2-Ubuntu SMP Sat Oct 31 17:07:12 UTC 2009 i686 GNU/Linux

I have the https://launchpad.net/~xorg-edgers/+archive/ppa enabled and the latest linux kernel.

Revision history for this message
Oibaf (oibaf) wrote :

I am also able to trigger this bug on a RV530 with current mesa_7_7_branch with the game "Enemy Territory Quake War". However I am not yet able to take a backtrace of it because ETQW also triggers a different crash and I get only this last one when running it under gdb. I suspect that this two may be related to this one:
https://bugs.freedesktop.org/show_bug.cgi?id=24131
https://bugs.freedesktop.org/show_bug.cgi?id=25179

Probably we should ping Dave Airlie (as also suggested by Maciej Cencora) to fix this issue (note that these problems appear only when KMS is disabled so it's not an issue on Fedora). Maybe we should before set up a wiki page with all informations related to this to summarize the issue.

Revision history for this message
ybkosher (bobby-weinmann) wrote :

I was getting this crash in UrbanTerror. It only happens WITHOUT KMS on (radeon.modeset=0). I made this change and it works for me:
diff -r mesa-7.7.0~git20091125+mesa-7-7-branch.7fac8ce7/src/mesa/drivers/dri/radeon/radeon_dma.c mesa-7.7.0~git20091125+mesa-7-7-branch.7fac8ce7-mine/src/mesa/drivers/dri/radeon/radeon_dma.c
351c351,352
< while ((dma_bo->bo = radeon_bo_unref(dma_bo->bo))) {}
---
> /* while ((dma_bo->bo = radeon_bo_unref(dma_bo->bo))) {} */
> radeon_bo_unref(dma_bo->bo);

This code is reused for all of the radeon drivers. If you are going to use reference counting, you can't artificially unref like that. If something else real has a pointer to that bo, it will crash (as we see) when you release the memory. It looked like to me that this line at the end of the file (in releaseRadeonArrays) caused the crash:
        radeon_bo_unref(radeon->tcl.aos[i].bo);
Apparently, it's bo pointer was the same as the one that was unrefed in the above code.

There also seems to be something wrong with the calloc() in bo_allocate(). I changed it to malloc and then memset. I don't remember if you need both of these changes or just the first.

I have attached my patch. One note, I change the variable "bo_legacy" in bo_allocate() to "bol" to make it easier for me. It should not be necessary.

Revision history for this message
ybkosher (bobby-weinmann) wrote :

What I meant to say about the code being reused for all radeon drivers: Just because there is a bug in one that keeps the ref count artificially high, does not mean it is a bug for all of the drivers. Whatever was keeping it high should be fixed. This while loop is too drastic.

Revision history for this message
Tormod Volden (tormodvolden) wrote :

ybkosher, great debugging there. I think you are right and this was what Pauli tried to fix in http://cgit.freedesktop.org/mesa/mesa/commit/?h=mesa_7_6_branch&id=284a7af274bc148f112bd0ebb40583923ee26b49 but it got reverted in http://cgit.freedesktop.org/mesa/mesa/commit/?h=mesa_7_6_branch&id=13b5a624b1899c457279907d58046dfb3c95addc because of https://bugs.freedesktop.org/show_bug.cgi?id=24131

The root cause has not been found and these commits just exposes it at different places. If you find out anything, please post in the upstream bug where the developers see it.

Revision history for this message
ybkosher (bobby-weinmann) wrote :

Tormod,

If I understand this, that while loop was put in because of possible memory leaks, but in bo_allocate, the new bo is made part of a linked list. radeon_bo_legacy_dtor destroys all the bo_legacys in the list. I don't think it is possble to leak the memory.

A very unscientific test, but I ran mplayer with gl2 as the video-output through valgrind. There were no memory leaks.

Revision history for this message
Oibaf (oibaf) wrote :
Revision history for this message
Laurent (l-perlat) wrote :

Hello,

I have the same bug here using SweetHome3D (an open source Java 3D program).
When attempting to draw a 3d scene with a few objects the program crashes and exits.
Here is the output :
bo(0x90fc160, 65536) is mapped (-1) can't valide it.
validated 0x90fc160 [0xF0648000, 0xF4648000]
java: radeon_dma.c :210 : radeonRefillCurrentDmaRegion: L'assertion « dma_bo->bo->cref == 1 » a échoué.
Abandon

$ lspci -nn|grep [V]GA
01:00.0 VGA compatible controller [0300]: ATI Technologies Inc Radeon RV250 If [Radeon 9000] [1002:4966] (rev 01)

This bugs seems pretty serious as it affects many 3D programs, including Google Earth, various games etc. as can be seen from the comments and the duplicates.

It also seems that a patch has been proposed ?

Is it possible to make it available in Ubuntu 9.10 ?

Thanks in advance,

Laurent

Revision history for this message
Jabucko (jabucko) wrote :

Hi,

i have same problem in TrackMania Forever ->> in wine. It started crashing when i set better graphics quality.

OS: Ubuntu 9.10
Ati Radeon x550 Silent (RV370). I use the open-source ati driver.

Last 12 lines of console:

radGetContent(): total_active_weight == 10000, r == 5325
radGetContent() content->id: 22205 content->size: 16512 return: 0
bo(0x79bf3d30, 98304) is mapped (-1) can't valide it.
validated 0x79bf3d30 [0xF0B6A000, 0xF0B77000]
bo(0x79c03000, 98304) is mapped (-1) can't valide it.
validated 0x79c03000 [0xF0B6A000, 0xF0B77000]
m Files\TmNationsForever\TmForever.exe: radeon_dma.c:210: radeonRefillCurrentDmaRegion: Assertion `dma_bo->bo->cref == 1' failed.
AL lib: ALc.c:1368: exit(): closing 1 Device
AL lib: ALc.c:1345: alcCloseDevice(): destroying 1 Context
AL lib: alSource.c:2362: alcDestroyContext(): deleting 75 Source(s)
AL lib: alAuxEffectSlot.c:507: alcDestroyContext(): deleting 1 AuxiliaryEffectSlot(s)
AL lib: alBuffer.c:1079: exit(): deleting 106 Buffer(s)
AL lib: alEffect.c:1167: exit(): deleting 1 Effect(s)

Thanks

(Sorry for my english, maybe is bad ;))

Revision history for this message
Arno Mayrhofer (azrael3000) wrote :

I installed Mesa 7.7 and can confirm that this bug is gone. (Occured while using Blender)

Note however that I now have problems with compiz (extreme cpu load + no window bar) but since I use megacity anyway this is not an issue for me.

Revision history for this message
Julien (julienmbpe) wrote :
Download full text (5.5 KiB)

Same problem using the game "Homewold 2" with Wine.

Information on my system :
julien@julien-laptop:~$ uname -a
Linux julien-laptop 2.6.32-020632-generic #020632 SMP Thu Dec 3 10:58:45 UTC 2009 i686 GNU/Linux

julien@julien-laptop:~$ lspci -nn | grep VGA
01:05.0 VGA compatible controller [0300]: ATI Technologies Inc Radeon Mobility U1 [1002:4336]

julien@julien-laptop:~$ cat /var/log/Xorg.0.log|grep RAM
(II) RADEON(0): Detected total video RAM=65536K, accessible=131072K (PCI BAR=262144K)
(--) RADEON(0): Mapped VideoRAM: 65536 kByte (64 bit DDR SDRAM)
(II) Initializing built-in extension XINERAMA

julien@julien-laptop:~$ glxinfo |grep renderer
OpenGL renderer string: Mesa DRI R100 (RS100 4336) 20090101 AGP 4x x86/MMX+/3DNow!+/SSE NO-TCL

Error message in console :
julien@julien-laptop:~/.wine/drive_c/Program Files/Sierra/Homeworld2/Bin/Release$ wine Homeworld2.exe -nopbuffer
fixme:ntdll:server_ioctl_file Unsupported ioctl 2d1400 (device=2d access=0 func=500 method=0)
wine: Unhandled page fault on write access to 0x00650168 at address 0x7ee59ae3 (thread 001f), starting debugger...
Unhandled exception: page fault on write access to 0x00650168 in 32-bit code (0x7ee59ae3).
Register dump:
 CS:0073 SS:007b DS:007b ES:007b FS:0033 GS:003b
 EIP:7ee59ae3 ESP:0064e690 EBP:0064e738 EFLAGS:00010246( R- -- I Z- -P- )
 EAX:00000001 EBX:7ee5bff4 ECX:00001000 EDX:006500c8
 ESI:00655000 EDI:006581dc
Stack dump:
0x0064e690: 00655000 00001000 00000002 00000000
0x0064e6a0: 00131048 00230000 0064e6c8 7bc34ce1
0x0064e6b0: 0000001d 0064e71c 0064e718 006581dc
0x0064e6c0: 00640000 006500c8 00001000 00650000
0x0064e6d0: 00110014 7bc94ff4 0064e738 7bc448b6
0x0064e6e0: 00110058 0064e714 0064e70c 0064e71c
Backtrace:
=>0 0x7ee59ae3 in winedevice (+0x9ae3) (0x0064e738)
  1 0x7ee59da3 in winedevice (+0x9da3) (0x0064e9c8)
  2 0x7ee5a3c6 in winedevice (+0xa3c6) (0x0064ea18)
  3 0x7ee2e4b4 in advapi32 (+0x2e4b4) (0x0064ea68)
  4 0x7bc6b594 call_thread_func+0xc() in ntdll (0x0064ea78)
  5 0x7bc6b7a0 call_thread_entry_point+0x70() in ntdll (0x0064eb48)
  6 0x7bc739e5 in ntdll (+0x639e5) (0x0064f398)
  7 0xb76a080e (0x0064f498)
  8 0xb76228de (0x00000000)
0x7ee59ae3: movl $0x0,0xa0(%edx)
Modules:
Module Address Debug info Name (30 modules)
PE 650000- 659000 Deferred kmountmg.sys
ELF 438b5000-438d2000 Deferred ld-linux.so.2
ELF 438d4000-43a19000 Deferred libc.so.6
ELF 43a1b000-43a1f000 Deferred libdl.so.2
ELF 43a21000-43a3a000 Deferred libpthread.so.0
ELF 43a3c000-43a62000 Deferred libm.so.6
ELF 44824000-4483b000 Deferred libnsl.so.1
ELF 463c0000-464fb000 Deferred libwine.so.1
ELF 7b800000-7b971000 Deferred kernel32<elf>
  \-PE 7b820000-7b971000 \ kernel32
ELF 7bc00000-7bcb1000 Export ntdll<elf>
  \-PE 7bc10000-7bcb1000 \ ntdll
ELF 7bf00000-7bf04000 Deferred <wine-loader>
ELF 7ec8e000-7eca5000 Deferred hal<elf>
  \-PE 7ec90000-7eca5000 \ hal
ELF 7eca5000-7ed13000 Deferred msvcrt<elf>
  \-PE 7ecc0000-7ed13000 \ msvcrt
ELF 7ed13000-7ed80000 Deferred rpcrt4<elf>
  \-PE 7ed20000-7ed80000 \ rpcrt4
ELF ...

Read more...

Revision history for this message
Julien (julienmbpe) wrote :

Hi!
I formerly wrote that I was affected with games under Wine... now I know that I'm affected under native linux games too.
I encounter that error message with Sauerbrauten today.

Oibaf (oibaf)
description: updated
Robert Hooker (sarvatt)
Changed in mesa (Ubuntu):
status: Confirmed → Fix Committed
Changed in mesa:
status: Unknown → Confirmed
Revision history for this message
In , Kai Wasserbaech (debian-carbon-project) wrote :

I see this bug too when using a 3D application (e.g. playing something in Wine) with the following system:
GPU: R300
Kernel: 2.6.32.8
X.org: 1.7.4
Mesa: 7.6.1
Radeon driver: 6.12.4 + commits up to 712ac98a
Essentially Debian Testing except the Kernel (self-built) and the radeon driver (from Unstable, because it fixes <http://bugs.debian.org/565506>).

Something I've noticed, that I see quite often (when stopping kdm or when I run glxinfo) a lot of messages like „glxinfo:5129 freeing invalid memtype e0102000-e0112000“ (this is one I triggered with glxinfo, the ones I see when stopping kdm are similar except the glxinfo part is then replaced by kdm). I don't know, if this might be related.

Revision history for this message
Bert Driehuis (driehuis) wrote :

I can confirm the presence of the "radeon_dma.c:210: radeonRefillCurrentDmaRegion: Assertion `dma_bo->bo->cref == 1' failed.' assertion on a stock Karmic installation (32 bit, Dell Dimension 3100, Radeon 7000/VR100).

I have installed Mesa 7.8 and the accompanying libdrm from todays xorg-edgers PPA, and it does indeed rectify the issue.
 mesa 7.8.0~git20100210.f88b43e8-0ubuntu0sarvatt~karmic
 libdrm 2.4.17+git20100210.4f0f8717-0ubuntu0sarvatt~karmic

Some random datapoints:
% glxinfo |grep rendere
OpenGL renderer string: Mesa DRI R100 (RV100 5159) 20090101 x86/MMX/SSE2 NO-TCL
% lspci|grep VGA
03:02.0 VGA compatible controller: ATI Technologies Inc Radeon RV100 QY [Radeon 7000/VE]

Problem and workaround verified with both an older and a current copy of googleearth.

Revision history for this message
Timo Aaltonen (tjaalton) wrote :

fixed in lucid which has 7.7.

Changed in mesa (Ubuntu):
status: Fix Committed → Fix Released
Revision history for this message
In , Kai Wasserbaech (debian-carbon-project) wrote :

With the advent of 2.6.33(.1) I've switched to KMS and since then I can't reproduce this problem anymore (at least not so far).

Changed in mesa:
importance: Unknown → Medium
Changed in mesa:
importance: Medium → Unknown
Changed in mesa:
importance: Unknown → Medium
Changed in mesa:
status: Confirmed → Won't Fix
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.