# X stops responding: [fglrx] ASIC hang happened

## keet

My computer froze about six times today, and this is the first time that this computer has frozen while in Gentoo, as far as I remember.  At first, I thought that it was a problem with Adobe Flash Player, because it happened when that was running.  However, even after I uninstalled that, my computer still froze.  It doesn't freeze completely; I can ssh into it, though the mouse and keyboard do nothing at all.  When I ssh into it, I see that X is using 100% of a core, and I cannot end it, though shutdown -r now works..  This time, I found an error in dmesg:

```
amdcccle[2136]: segfault at 0 ip 00007fe86b9bf291 sp 00007fffbe02f070 error 4 in libQtCore.so.4.7.2[7fe86b92a000+283000]

[ 3091.915366] [fglrx] ASIC hang happened

[ 3091.915368] Pid: 822, comm: X Tainted: P            2.6.39-gentoo-r3 #1

[ 3091.915370] Call Trace:

[ 3091.915398]  [<ffffffffa001460c>] ? firegl_hardwareHangRecovery+0x1c/0x50 [fglrx]

[ 3091.915424]  [<ffffffffa00a1159>] ? _ZN4Asic9WaitUntil15ResetASICIfHungEv+0x9/0x10 [fglrx]

[ 3091.915447]  [<ffffffffa00a110c>] ? _ZN4Asic9WaitUntil15WaitForCompleteEv+0x6c/0xb0 [fglrx]

[ 3091.915471]  [<ffffffffa009c3b4>] ? _ZN15ExecutableUnits10CPRingIdleE15idle_WaitMethod12_QS_CP_RING_+0xe4/0x1a0 [fglrx]

[ 3091.915494]  [<ffffffffa009cf0a>] ? _ZN21ExecutableUnitsCayman14AllCPRingsIdleE15idle_WaitMethod+0x1a/0x90 [fglrx]

[ 3091.915516]  [<ffffffffa009c27b>] ? _ZN15ExecutableUnits7PM4idleE15idle_WaitMethod+0x4b/0x90 [fglrx]

[ 3091.915539]  [<ffffffffa0094cf1>] ? _ZN15QS_PRIVATE_CORE9QsPM4idleE15idle_WaitMethod+0x31/0x60 [fglrx]

[ 3091.915561]  [<ffffffffa008018a>] ? _ZN10QS_PRIVATE11synchronizeEv+0x2a/0x30 [fglrx]

[ 3091.915583]  [<ffffffffa00897f5>] ? _Z8uCWDDEQCmjjPvjS_+0x3b5/0x10c0 [fglrx]

[ 3091.915597]  [<ffffffffa0032d32>] ? firegl_cmmqs_CWDDE_32+0x332/0x440 [fglrx]

[ 3091.915612]  [<ffffffffa0031660>] ? firegl_cmmqs_CWDDE32+0x70/0x100 [fglrx]

[ 3091.915614]  [<ffffffff810c46a8>] ? vma_link+0xa8/0xf0

[ 3091.915628]  [<ffffffffa00315f0>] ? firegl_cmmqs_createdriver+0x170/0x170 [fglrx]

[ 3091.915641]  [<ffffffffa0010218>] ? firegl_ioctl+0x1e8/0xf20 [fglrx]

[ 3091.915649]  [<ffffffffa0001b79>] ? ip_firegl_unlocked_ioctl+0x9/0x10 [fglrx]

[ 3091.915651]  [<ffffffff810f4a0e>] ? do_vfs_ioctl+0x8e/0x4f0

[ 3091.915653]  [<ffffffff810f4eb9>] ? sys_ioctl+0x49/0x80

[ 3091.915655]  [<ffffffff816570bb>] ? system_call_fastpath+0x16/0x1b

[ 3091.915657] pubdev:0xffffffffa0261900, num of device:1 , name:fglrx, major 8, minor 88.

[ 3091.915659] device 0 : 0xffff880234d24000 .

[ 3091.915660] Asic ID:0x6719, revision:0x1, MMIOReg:0xffffc90010200000.

[ 3091.915661] FB phys addr: 0xc0000000, MC :0xf800000000, Total FB size :0x80000000.

[ 3091.915663] gart table MC:0xf80f8ff000, Physical:0xcf8ff000, size:0x400000.

[ 3091.915664] mc_node :FB, total 1 zones

[ 3091.915665]     MC start:0xf800000000, Physical:0xc0000000, size:0xfd00000.

[ 3091.915667]     Mapped heap -- Offset:0x0, size:0xf8ff000, reference count:96, mapping count:0,

[ 3091.915668]     Mapped heap -- Offset:0x0, size:0x1000000, reference count:1, mapping count:0,

[ 3091.915670]     Mapped heap -- Offset:0xf8ff000, size:0x401000, reference count:1, mapping count:0,

[ 3091.915671] mc_node :INV_FB, total 1 zones

[ 3091.915672]     MC start:0xf80fd00000, Physical:0xcfd00000, size:0x70300000.

[ 3091.915673]     Mapped heap -- Offset:0x702f4000, size:0xc000, reference count:1, mapping count:0,

[ 3091.915675] mc_node :GART_USWC, total 2 zones

[ 3091.915676]     MC start:0xffb0100000, Physical:0x0, size:0x4ff00000.

[ 3091.915677]     Mapped heap -- Offset:0x0, size:0x2000000, reference count:6, mapping count:0,

[ 3091.915678] mc_node :GART_CACHEABLE, total 3 zones

[ 3091.915679]     MC start:0xff80400000, Physical:0x0, size:0x2fd00000.

[ 3091.915680]     Mapped heap -- Offset:0x4700000, size:0x400000, reference count:1, mapping count:0,

[ 3091.915682]     Mapped heap -- Offset:0x4f00000, size:0x400000, reference count:1, mapping count:0,

[ 3091.915683]     Mapped heap -- Offset:0x3c00000, size:0x400000, reference count:1, mapping count:0,

[ 3091.915684]     Mapped heap -- Offset:0x4b00000, size:0x400000, reference count:2, mapping count:0,

[ 3091.915686]     Mapped heap -- Offset:0x4300000, size:0x400000, reference count:3, mapping count:0,

[ 3091.915687]     Mapped heap -- Offset:0x3900000, size:0x300000, reference count:10, mapping count:0,

[ 3091.915689]     Mapped heap -- Offset:0x3600000, size:0x300000, reference count:7, mapping count:0,

[ 3091.915690]     Mapped heap -- Offset:0x3400000, size:0x200000, reference count:12, mapping count:0,

[ 3091.915691]     Mapped heap -- Offset:0x2e00000, size:0x600000, reference count:15, mapping count:0,

[ 3091.915693]     Mapped heap -- Offset:0x2200000, size:0x600000, reference count:7, mapping count:0,

[ 3091.915694]     Mapped heap -- Offset:0x1d00000, size:0x500000, reference count:4, mapping count:0,

[ 3091.915695]     Mapped heap -- Offset:0x2800000, size:0x600000, reference count:11, mapping count:0,

[ 3091.915697]     Mapped heap -- Offset:0x1400000, size:0x900000, reference count:5, mapping count:0,

[ 3091.915698]     Mapped heap -- Offset:0xb00000, size:0x900000, reference count:7, mapping count:0,

[ 3091.915700]     Mapped heap -- Offset:0x200000, size:0x900000, reference count:6, mapping count:0,

[ 3091.915701]     Mapped heap -- Offset:0x0, size:0x200000, reference count:13, mapping count:0,

[ 3091.915703]     Mapped heap -- Offset:0xef000, size:0x11000, reference count:1, mapping count:0,

[ 3091.915705] GRBM : 0xf04e3828, SRBM : 0x200000c0 .

[ 3091.915707] CP_RB_BASE : 0xffb01000, CP_RB_RPTR : 0x10048 , CP_RB_WPTR :0x10060.

[ 3091.915709] CP_IB1_BUFSZ:0x0, CP_IB1_BASE_HI:0xff, CP_IB1_BASE_LO:0xb07c3000.

[ 3091.915711] last submit IB buffer -- MC :0xffb07c3000,phys:0x228d68000.

[ 3091.915712] Dump the trace queue.

[ 3091.915713] End of dump
```

I found a couple similar threads (https://forums.gentoo.org/viewtopic-t-879513-highlight-asic.html and https://forums.gentoo.org/viewtopic-t-845393-highlight-asic.html, but neither seemed to have a resolution.  I am downgrading ati-drivers from 11.8 to 11.6 to see whether that helps.  Also, maybe changing my version of qt-core (upgrading?) might help.

----------

## yardbird

Hey keet,

had a similar hang today with a radeon hd card. I've been using it for a couple of months with zero problems so far, so I'm also thinking the latest binary driver update has something to do with this. I'm gonna try the open source drivers next and see how it goes.

So no solution yet, just a "me too"  :Smile: 

----------

## keet

I found and commented on a similar post in http://ati.cchtml.com/show_bug.cgi?id=230.  I downgraded to ati-drivers 11.6, and it is working well now.

By the way, would you comment on how the open-source drivers work for you?  What kind of card do you have?

----------

## yardbird

 *keet wrote:*   

> I found and commented on a similar post in http://ati.cchtml.com/show_bug.cgi?id=230.  I downgraded to ati-drivers 11.6, and it is working well now.
> 
> By the way, would you comment on how the open-source drivers work for you?  What kind of card do you have?

 

Cool, nice to know that reverting back to the previous version solves the problem.

I have a Radeon HD6870, and unfortunately the open-source driver is not working fine. I'm experiencing exactly the same problem described here:

https://bugs.freedesktop.org/show_bug.cgi?id=39576

It's a pity, as before locking up everything works really nice performance-wise (with KMS, Gallium, etc.). I'm probably going to revert to the previous binary driver version and watch how the situation with the open-source driver evolves.

----------

## keet

Unfortunately, by the time that the open-source driver supports our cards properly, 8xxx or 9xxx cards will be current, and we'll need the binary driver to use those properly.  Maybe that won't be the case, though.

I used to have a Radeon 9600 (maybe it was a 9500 or 9700) years ago.  Now I have a 6950.  How did the lower number card end up being faster?  :Smile: 

----------

## yardbird

 *keet wrote:*   

> Unfortunately, by the time that the open-source driver supports our cards properly, 8xxx or 9xxx cards will be current, and we'll need the binary driver to use those properly.  Maybe that won't be the case, though.
> 
> I used to have a Radeon 9600 (maybe it was a 9500 or 9700) years ago.  Now I have a 6950.  How did the lower number card end up being faster? 

 

Eh eh  :Smile: 

I still have some hope though, seeing that many distros are going to ship the open-source driver as default, and that support for newer cards is appearing sooner than it used to (albeit with bugs and problems). Many people are raving about KMS+Gallium on the OSS driver, so I truly hope this issue is going to be solved soon.

----------

## wang_yanqing

Although I have used gentoo  for four years, but it is the first time to come here,HOHO, I meat some trouble with the issue mention here, it is nice to see revert ati binary drivers will workaround it.Thanks you, and Thanks gentoo bring us the best distribution in the world!

----------

