Hi, few weeks ago i've upgraded kernel to 2.6.15 and ati driver to 8.20.8, but the system crash with kernel panic. I've erased the agpgart module and the system work fine, but without DRI.
Today i've seen the new x.org version, i've upgraded all but the problem reappear.
I've recompiled 2.6.14.5 and the system work fine, with agpgart loaded and dri enable.
system log:
Jan 16 13:44:28 robyt kernel: Bad page state at free_hot_cold_page (in process 'X', page c1344280)
Jan 16 13:44:28 robyt kernel: Bad page state at free_hot_cold_page (in process 'X', page c1344280)
Jan 16 13:44:28 robyt kernel: flags:0x80000414 mapping:00000000 mapcount:0 count:0
Jan 16 13:44:28 robyt kernel: flags:0x80000414 mapping:00000000 mapcount:0 count:0
Jan 16 13:44:28 robyt kernel: Backtrace:
Jan 16 13:44:28 robyt kernel: Backtrace:
Jan 16 13:44:28 robyt kernel: [bad_page+132/188] bad_page+0x84/0xbc
Jan 16 13:44:28 robyt kernel: [free_hot_cold_page+85/353] free_hot_cold_page+0x55/0x161
Jan 16 13:44:28 robyt kernel: [__pagevec_free+22/30] __pagevec_free+0x16/0x1e
Jan 16 13:44:28 robyt kernel: [release_pages+353/374] release_pages+0x161/0x176
Jan 16 13:44:28 robyt kernel: [free_pages_and_swap_cache+93/131] free_pages_and_swap_cache+0x5d/0x83
Jan 16 13:44:28 robyt kernel: [unmap_region+312/335] unmap_region+0x138/0x14f
Jan 16 13:44:28 robyt kernel: [do_munmap+271/377] do_munmap+0x10f/0x179
Jan 16 13:44:28 robyt kernel: [sys_munmap+69/102] sys_munmap+0x45/0x66
Jan 16 13:44:28 robyt kernel: [syscall_call+7/11] syscall_call+0x7/0xb
Jan 16 13:44:28 robyt kernel: Trying to fix it up, but a reboot is needed
Jan 16 13:44:28 robyt kernel: Trying to fix it up, but a reboot is needed
Jan 16 13:44:28 robyt kernel: ------------[ cut here ]------------
Jan 16 13:44:28 robyt kernel: kernel BUG at mm/swap.c:215!
Jan 16 13:44:28 robyt kernel: kernel BUG at mm/swap.c:215!
Jan 16 13:44:28 robyt kernel: invalid operand: 0000 [#1]
Jan 16 13:44:28 robyt kernel: invalid operand: 0000 [#1]
Jan 16 13:44:28 robyt kernel: PREEMPT SMP
Jan 16 13:44:28 robyt kernel: Modules linked in: fglrx agpgart vmnet vmmon snd_intel8x0 snd_ac97_codec snd_ac97_bus bsd_comp ppp_gen
eric slhc
Jan 16 13:44:28 robyt kernel: CPU: 0
Jan 16 13:44:29 robyt kernel: EIP: 0060:[release_pages+361/374] Tainted: P B VLI
Jan 16 13:44:29 robyt kernel: EFLAGS: 00013257 (2.6.15)
Jan 16 13:44:29 robyt kernel: EIP is at release_pages+0x169/0x176
Jan 16 13:44:29 robyt kernel: eax: 00000000 ebx: c1344280 ecx: 00000000 edx: c1344280
Jan 16 13:44:29 robyt kernel: esi: 00000001 edi: 00000000 ebp: 00000000 esp: cee59ecc
Jan 16 13:44:29 robyt kernel: ds: 007b es: 007b ss: 0068
Jan 16 13:44:29 robyt kernel: Process X (pid: 20607, threadinfo=cee58000 task=c1bb9530)
Jan 16 13:44:29 robyt kernel: Stack: d313d6a4 00000000 00000000 b772f000 cee59f2c 00000000 b772efff c4dbc64c
Jan 16 13:44:29 robyt kernel: c4dbc678 d4842580 d313d6a4 b732efff c4dbc668 d313d6cc c4dbc64c 00000000
Jan 16 13:44:29 robyt kernel: 00000000 c1344280 00000001 00000001 c1807910 c015425c c1807910 00000001
Jan 16 13:44:30 robyt kernel: Call Trace:
Jan 16 13:44:30 robyt kernel: [free_pages_and_swap_cache+93/131] free_pages_and_swap_cache+0x5d/0x83
Jan 16 13:44:30 robyt kernel: [unmap_region+312/335] unmap_region+0x138/0x14f
Jan 16 13:44:30 robyt kernel: [do_munmap+271/377] do_munmap+0x10f/0x179
Jan 16 13:44:30 robyt kernel: [sys_munmap+69/102] sys_munmap+0x45/0x66
Jan 16 13:44:30 robyt kernel: [syscall_call+7/11] syscall_call+0x7/0xb
Jan 16 13:44:30 robyt kernel: Code: db 75 14 83 c4 44 5b 5e 5f 5d c3 83 af a4 02 00 00 01 e9 73 ff ff ff 8d 44 24 04 89 04 24 e8 b3
a2 ff ff 83 c4 44 5b 5e 5f 5d c3 <0f> 0b d7 00 ca 0f 3d c0 e9 dd fe ff ff 53 83 ec 0c 8b 5c 24 14
Jan 16 13:44:30 robyt kernel: <6>note: X[20607] exited with preempt_count 1
Jan 16 13:44:30 robyt kernel: scheduling while atomic: X/0x00000001/20607
Jan 16 13:44:30 robyt kernel: scheduling while atomic: X/0x00000001/20607
Jan 16 13:44:30 robyt kernel: [schedule+2537/3405] schedule+0x9e9/0xd4d
Jan 16 13:44:30 robyt kernel: [call_console_drivers+103/315] call_console_drivers+0x67/0x13b
Jan 16 13:44:30 robyt kernel: [release_console_sem+123/186] release_console_sem+0x7b/0xba
Jan 16 13:44:30 robyt kernel: [vprintk+410/690] vprintk+0x19a/0x2b2
Jan 16 13:44:30 robyt kernel: [rwsem_down_read_failed+136/379] rwsem_down_read_failed+0x88/0x17b
Jan 16 13:44:30 robyt kernel: [.text.lock.exit+39/132] .text.lock.exit+0x27/0x84
Jan 16 13:44:30 robyt kernel: [do_exit+241/1034] do_exit+0xf1/0x40a
Jan 16 13:44:30 robyt kernel: [do_trap+0/285] do_trap+0x0/0x11d
Jan 16 13:44:30 robyt kernel: [do_invalid_op+0/171] do_invalid_op+0x0/0xab
Jan 16 13:44:30 robyt kernel: [do_invalid_op+162/171] do_invalid_op+0xa2/0xab
Jan 16 13:44:30 robyt kernel: [release_pages+361/374] release_pages+0x169/0x176
Jan 16 13:44:30 robyt kernel: [pg0+945377927/1068585984] drm_free+0xb7/0x150 [fglrx]
Jan 16 13:44:30 robyt kernel: [__copy_to_user_ll+106/132] __copy_to_user_ll+0x6a/0x84
Jan 16 13:44:30 robyt kernel: [pg0+945419700/1068585984] firegl_aperture_free+0x1e4/0x220 [fglrx]
Jan 16 13:44:30 robyt kernel: [page_remove_rmap+47/61] page_remove_rmap+0x2f/0x3d
Jan 16 13:44:30 robyt kernel: [error_code+79/84] error_code+0x4f/0x54
Jan 16 13:44:30 robyt kernel: [release_pages+361/374] release_pages+0x169/0x176
Jan 16 13:44:30 robyt kernel: [free_pages_and_swap_cache+93/131] free_pages_and_swap_cache+0x5d/0x83
Jan 16 13:44:31 robyt kernel: [unmap_region+312/335] unmap_region+0x138/0x14f
Jan 16 13:44:31 robyt kernel: [do_munmap+271/377] do_munmap+0x10f/0x179
Jan 16 13:44:31 robyt kernel: [sys_munmap+69/102] sys_munmap+0x45/0x66
Jan 16 13:44:31 robyt kernel: [syscall_call+7/11] syscall_call+0x7/0xb
Jan 16 13:46:15 robyt kernel: ------------[ cut here ]------------
linux 2.6.15, xorg 6.9, distro slackware, kernel compiled with gcc 3.4.4 and libc 2.3.6.
SVGA Ati 9250, CPU P4 3 GHz, 1 Gb ram
There's a known fix for this
Go to line 2624 of firegl_public.c
Ignore all the warning messages in the comments.
Replace the #ifdef 0 with #if LINUX_VERSION_CODE >= 0x02060f
Recompile the ATI module, reinstall it, and reboot.
Hello, Could you please ex
Hello,
Could you please explain better your solution ?
I've two files firegl_public.c:
/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c
/lib/modules/fglrx/build_mod/firegl_public.c
Which one is to edit ? (There isn't difference between the files)
At line 2624 I have:
#if 0
// WARNING WARNINIG WARNNING WARNNING WARNNING WARNNING WARNNING WARNNING
// Don't increment page usage count, cause ctx pages are allocated
// with drm_alloc_pages, which marks all pages as reserved. Reserved
// pages' usage count is not decremented by the kernel during unmap!!!
get_page(pMmPage); /* inc usage count of page */
#endif
#if LINUX_VERSION_CODE >= 0x020400
__KE_DEBUG3("vm-address 0x%08lx => kernel-page-address 0x%p\n",
address, page_address(pMmPage));
return pMmPage;
Must I replace #if 0 with #if LINUX_VERSION_CODE >= 0x02060f ?
Thanks a lot.
BR,
Fabrizio
Ops, sorry. The first is a li
Ops, sorry. The first is a link to the other file, but #ifdef 0 there isn't..
Thanks again
yes, replace the #if 0
That's what I meant. It works for me...I found it on a few other web sites but I forget where right now and don't have time to look again.
And yes the one file is a symbolic link, so it shouldn't matter which one you open in your editor.
You looking for this patch I
You looking for this patch I think. Make the below a diff ;)
--- fglrx.orig/build_mod/firegl_public.c 2005-12-05 15:47:41.000000000 +0000
+++ fglrx/build_mod/firegl_public.c 2005-12-05 17:18:12.000000000 +0000
@@ -2586,7 +2586,7 @@ static __inline__ vm_nopage_ret_t do_vm_
pMmPage = virt_to_page(kaddr);
-#if 0
+#if LINUX_VERSION_CODE >= 0x02060f
// WARNING WARNINIG WARNNING WARNNING WARNNING WARNNING WARNNING WARNNING
// Don't increment page usage count, cause ctx pages are allocated
// with drm_alloc_pages, which marks all pages as reserved. Reserved
I can confirm that this solves many problems including the strange hangs in many x apps.
-dw
Sorry about no code formatting, but for some reason doesn't process the above correctly.