Re: Linux-1.3.71..

Sidewinder (J.M.Box@dcs.warwick.ac.uk)
Wed, 13 Mar 1996 20:55:25 +0000 (GMT)


> However, the "get_free_pages()" function is one of the most called
> functions in the kernel, _and_ it is very susceptible to pointer
> corruption. If some part of the kernel used a pointer that isn't valid
> any more (for example, a pointer to a memory block that had been free'd
> earlier), and corrupted the linked list of free pages, you'll see
> problems in get_free_page().
>
> This also makes that kind of bug very hard to find: by the time you get
> the kernel Oops the thing that corrupted the list is long gone already.

I agree with you, and having had this kind of bug before in my programs,
I know how much I hate them. I have some kernel oopses from 1.3.73 below
to try and help, but I don't know if they will be much help. I had just
compiled 1.3.73 and was booting it the first time, and it fell over just
before I could log in! Somehow init was still able to spawn an agetty and
I did manage to login, but there was not much I could do...

By the way, I recommend that everyone should get and install sysklogd 1.3.
This is the first major crash I've had using it, and its very helpful
having klogd doing the ksymoops for me :) I got it from a sunsite mirror,
in the Incoming dir.

I'm not sure if the crashes are anything to do with modules, but I do use
them with kerneld. In modules I have binfmt_aout, isofs, minix, msdos and
nfs. The first oops is from gpm_root, but that shouldn't have needed to
load a module since the binary is ELF on my mainly ELF system.

Here are the oops, from my syslog but 'cut' to reduce the width:
Unable to handle kernel paging request at virtual address c7200724
current->tss.cr3 = 00080000, @r3 = 00080000
*pde = 00000000
Oops: 0002
CPU: 0
EIP: 0010:[__get_free_pages+170/432]
EFLAGS: 00010086
eax: 07200720 ebx: 00050000 ecx: 00000000 edx: 001d9ab4
esi: 00000003 edi: 00000001 ebp: 00000293 esp: 00081f24
ds: 0018 es: 0018 fs: 002b gs: 002b ss: 0018
Process gpm-root (pid: 148, process nr: 19, stackpage=00081000)
Stack: 00000000 004df5a0 00007000 40010000 0011caca 00000003 00000000 ffffffff
00000000 0072b414 00504c58 0011a26a 00504c58 40010000 00000000 00504c58
40010000 00081fbc ffff0004 00300040 00300000 0005c025 0005d065 0005d067
Call Trace: [filemap_nopage+170/576] [do_no_page+762/928] [do_page_fault+403/768] [do_page_fault+0/768] [fast_IRQ14_interrupt+63/112] [error_code+75/96]
Code: 89 50 04 89 d8 c1 e8 0c 8d 56 01 89 d1 d3 e8 8b 14 b5 6c 9c
Unable to handle kernel paging request at virtual address c7200720
current->tss.cr3 = 00309000, @r3 = 00309000
*pde = 00000000
Oops: 0000
CPU: 0
EIP: 0010:[__get_free_pages+166/432]
EFLAGS: 00010082
eax: 001d9ab4 ebx: 07200720 ecx: 00000000 edx: 001d9ab4
esi: 00000003 edi: 00000001 ebp: 00000293 esp: 002a1f3c
ds: 0018 es: 0018 fs: 002b gs: 002b ss: 0018
Process agetty (pid: 157, process nr: 25, stackpage=002a1000)
Stack: 0029c498 400b5698 002a1fbc 400b5698 00119a16 00000003 00000000 ffffffff
0029c498 400b5698 002a1fbc 00000007 08008000 08004000 08007000 08006718
00000000 00238067 0010ff4e 003fc810 0029c498 400b5698 00000002 0010fde0
Call Trace: [do_wp_page+22/576] [do_page_fault+366/768] [do_page_fault+0/768] [error_code+75/96]
Code: 8b 03 89 02 89 50 04 89 d8 c1 e8 0c 8d 56 01 89 d1 d3 e8 8b
Unable to handle kernel paging request at virtual address c7200720
current->tss.cr3 = 0038e000, @r3 = 0038e000
*pde = 00000000
Oops: 0000
CPU: 0
EIP: 0010:[__get_free_pages+166/432]
EFLAGS: 00010082
eax: 001d9ab4 ebx: 07200720 ecx: 00000000 edx: 001d9ab4
esi: 00000003 edi: 00000001 ebp: 00000293 esp: 007caf3c
ds: 0018 es: 0018 fs: 002b gs: 002b ss: 0018
Process agetty (pid: 155, process nr: 19, stackpage=007ca000)
Stack: 0029c098 400809e8 007cafbc 400809e8 00119a16 00000003 00000000 ffffffff
0029c098 400809e8 007cafbc ffff0007 ffff0004 003d4200 003d4000 007e0025
002b2065 002b2067 0010ff4e 0072b414 0029c098 400809e8 00000002 0010fde0
Call Trace: [do_wp_page+22/576] [do_page_fault+366/768] [do_page_fault+0/768] [sys_munmap+15/32] [error_code+75/96]
Code: 8b 03 89 02 89 50 04 89 d8 c1 e8 0c 8d 56 01 89 d1 d3 e8 8b
Unable to handle kernel paging request at virtual address c7200720
current->tss.cr3 = 00291000, @r3 = 00291000
*pde = 00000000
Oops: 0000
CPU: 0
EIP: 0010:[__get_free_pages+166/432]
EFLAGS: 00010082
eax: 001d9ab4 ebx: 07200720 ecx: 00000000 edx: 001d9ab4
esi: 00000003 edi: 00000001 ebp: 00000293 esp: 0023ff3c
ds: 0018 es: 0018 fs: 002b gs: 002b ss: 0018
Process agetty (pid: 158, process nr: 26, stackpage=0023f000)
Stack: 0029c158 40093700 0023ffbc 40093700 00119a16 00000003 00000000 ffffffff
0029c158 40093700 0023ffbc ffff0007 ffff0004 0021b0e8 0021b000 007c9025
002b2065 002b2067 0010ff4e 0029e018 0029c158 40093700 00000002 0010fde0
Call Trace: [do_wp_page+22/576] [do_page_fault+366/768] [do_page_fault+0/768] [error_code+75/96]
Code: 8b 03 89 02 89 50 04 89 d8 c1 e8 0c 8d 56 01 89 d1 d3 e8 8b
Unable to handle kernel paging request at virtual address c7200720
current->tss.cr3 = 003c6000, @r3 = 003c6000
*pde = 00000000
Oops: 0000
CPU: 0
EIP: 0010:[__get_free_pages+166/432]
EFLAGS: 00010082
eax: 001d9ab4 ebx: 07200720 ecx: 00000000 edx: 001d9ab4
esi: 00000003 edi: 00000001 ebp: 00000293 esp: 002a1f64
ds: 0018 es: 0018 fs: 002b gs: 002b ss: 0018
Process init (pid: 159, process nr: 25, stackpage=002a1000)
Stack: 00001000 0000176f 08004892 ffffffdc 0012b9df 00000003 00000000 ffffffff
003fc810 0800c300 00000902 bffffbc8 00000002 0800602f 00121dbd 08004891
002a1fb4 003fc810 0800c319 00000902 002a1fbc 0010a609 08004891 00000902
Call Trace: [getname+287/400] [sys_open+29/96] [system_call+89/160]
Code: 8b 03 89 02 89 50 04 89 d8 c1 e8 0c 8d 56 01 89 d1 d3 e8 8b
Unable to handle kernel paging request at virtual address c7200720
current->tss.cr3 = 00013000, @r3 = 00013000
*pde = 00000000
Oops: 0000
CPU: 0
EIP: 0010:[__get_free_pages+166/432]
EFLAGS: 00010082
eax: 001d9ab4 ebx: 07200720 ecx: 00000000 edx: 001d9ab4
esi: 00000003 edi: 00000001 ebp: 00000293 esp: 00007f54
ds: 0018 es: 0018 fs: 002b gs: 002b ss: 0018
Process init (pid: 1, process nr: 1, stackpage=00007000)
Stack: 00098018 00000001 00000000 00284018 00111c53 00000003 00000000 ffffffff
00098018 00000001 00000000 00007fb4 00095018 00098001 00174e8b 00000001
00095018 00095018 fffffff4 00174e20 00109da2 00000011 bffffbcc 00007fbc
Call Trace: [do_fork+51/2064] [multwrite_intr+107/160] [multwrite_intr+0/160] [sys_fork+18/32] [system_call+89/160]
Code: 8b 03 89 02 89 50 04 89 d8 c1 e8 0c 8d 56 01 89 d1 d3 e8 8b
Unable to handle kernel paging request at virtual address c7200720
current->tss.cr3 = 006f5000, @r3 = 006f5000
*pde = 00000000
Oops: 0000
CPU: 0
EIP: 0010:[__get_free_pages+166/432]
EFLAGS: 00010082
eax: 001d9ab4 ebx: 07200720 ecx: 00000000 edx: 001d9ab4
esi: 00000003 edi: 00000001 ebp: 00000293 esp: 0038ece0
ds: 0018 es: 0018 fs: 0018 gs: 002b ss: 0018
Process init (pid: 160, process nr: 19, stackpage=0038e000)
Stack: 00001000 0038ed88 001fd059 ffffffdc 0012b9df 00000003 00000000 ffffffff
00000013 0038ed88 001fd058 00390038 00000000 001fd02f 0012bf98 001fd058
0038ed2c 00000013 0000002b 000000d4 001302ec 001fd058 0038ed88 001bc168
Call Trace: [getname+287/400] [namei+24/80] [load_elf_binary+748/2704] [add_blkdev_randomness+66/80] [multwrite_intr+0/160] [multwrite_intr+107/160] [multwrite_intr+0/160]
[ide_intr+80/112] [do_fast_IRQ+35/48] [load_elf_binary+20/2704] [search_binary_handler+59/336] [do_execve+325/448] [do_execve+362/448] [load_elf_binary+20/2704] [sys_execve+50/96]
[system_call+89/160]
Code: 8b 03 89 02 89 50 04 89 d8 c1 e8 0c 8d 56 01 89 d1 d3 e8 8b
Unable to handle kernel paging request at virtual address c7200720
current->tss.cr3 = 002bc000, @r3 = 002bc000
*pde = 00000000
Oops: 0000
CPU: 0
EIP: 0010:[__get_free_pages+166/432]
EFLAGS: 00010082
eax: 001d9ab4 ebx: 07200720 ecx: 00000000 edx: 001d9ab4
esi: 00000003 edi: 00000001 ebp: 00000293 esp: 00086ec0
ds: 0018 es: 0018 fs: 002b gs: 002b ss: 0018
Process agetty (pid: 156, process nr: 23, stackpage=00086000)
Stack: 00012000 001e13f0 fffffff4 001e13b4 0017eab6 00000003 00000000 ffffffff
001d4b48 001e13f0 fffffff4 0017baa9 0017bcb4 00012000 00000000 00000000
00732bd0 004d84b0 00000004 00000003 00000000 00000000 001d4d40 00000000
Call Trace: [n_tty_open+70/288] [init_dev+409/1424] [init_dev+932/1424] [tty_open+126/464] [chrdev_open+49/64] [do_open+238/384] [sys_open+50/96]
[system_call+89/160]
Code: 8b 03 89 02 89 50 04 89 d8 c1 e8 0c 8d 56 01 89 d1 d3 e8 8b
Unable to handle kernel paging request at virtual address c7200720
current->tss.cr3 = 0023f000, @r3 = 0023f000
*pde = 00000000
Oops: 0000
CPU: 0
EIP: 0010:[__get_free_pages+166/432]
EFLAGS: 00010082
eax: 001d9ab4 ebx: 07200720 ecx: 00000002 edx: 001d9ab4
esi: 00000003 edi: 00000004 ebp: 00000293 esp: 0029eecc
ds: 0018 es: 0018 fs: 002b gs: 002b ss: 0018
Process agetty (pid: 161, process nr: 25, stackpage=0029e000)
Stack: ffffffff 00003ff0 00000003 001bb550 0011e0d5 00000003 00000002 ffffffff
00000004 00000010 00000004 0001ba50 00000144 00000000 001bb694 00003ff0
00000009 ffaa0055 ffffffff 00000246 0017f771 00003de0 00000003 00000004
Call Trace: [kmalloc+293/576] [vc_allocate+65/224] [con_open+27/96] [tty_open+198/464] [chrdev_open+49/64] [do_open+238/384] [sys_open+50/96]
[system_call+89/160]
Code: 8b 03 89 02 89 50 04 89 d8 c1 e8 0c 8d 56 01 89 d1 d3 e8 8b
Unable to handle kernel paging request at virtual address c7200720
current->tss.cr3 = 002a2000, @r3 = 002a2000
*pde = 00000000
Oops: 0000
CPU: 0
EIP: 0010:[__get_free_pages+166/432]
EFLAGS: 00010082
eax: 001d9ab4 ebx: 07200720 ecx: 00000000 edx: 001d9ab4
esi: 00000003 edi: 00000001 ebp: 00000293 esp: 0069ff3c
ds: 0018 es: 0018 fs: 002b gs: 002b ss: 0018
Process sh (pid: 163, process nr: 27, stackpage=0069f000)
Stack: 003f2058 08053080 0069ffbc 08053080 00119a16 00000003 00000000 ffffffff
003f2058 08053080 0069ffbc 00000007 08055000 08053000 08054000 08054000
00000000 007c4067 0010ff4e 0072bc0c 003f2058 08053080 00000002 0010fde0
Call Trace: [do_wp_page+22/576] [do_page_fault+366/768] [do_page_fault+0/768] [error_code+75/96]
Code: 8b 03 89 02 89 50 04 89 d8 c1 e8 0c 8d 56 01 89 d1 d3 e8 8b
Unable to handle kernel paging request at virtual address c7200720
current->tss.cr3 = 00766000, @r3 = 00766000
*pde = 00000000
Oops: 0000
CPU: 0
EIP: 0010:[__get_free_pages+166/432]
EFLAGS: 00010082
eax: 001d9ab4 ebx: 07200720 ecx: 00000000 edx: 001d9ab4
esi: 00000003 edi: 00000001 ebp: 00000293 esp: 00791f3c
ds: 0018 es: 0018 fs: 002b gs: 002b ss: 0018
Process _login (pid: 153, process nr: 4, stackpage=00791000)
Stack: 003f2e58 400b2000 00791fbc 400b2000 00119a16 00000003 00000000 ffffffff
003f2e58 400b2000 00791fbc ffff0007 001e6000 00105000 006ee2c4 007ca025
007ca065 007ca067 0010ff4e 0008dc0c 003f2e58 400b2000 00000002 0010fde0
Call Trace: [do_wp_page+22/576] [do_page_fault+366/768] [do_page_fault+0/768] [error_code+75/96]
Code: 8b 03 89 02 89 50 04 89 d8 c1 e8 0c 8d 56 01 89 d1 d3 e8 8b
Unable to handle kernel paging request at virtual address c7200720
current->tss.cr3 = 0007e000, @r3 = 0007e000
*pde = 00000000
Oops: 0000
CPU: 0
EIP: 0010:[__get_free_pages+166/432]
EFLAGS: 00010082
eax: 001d9ab4 ebx: 07200720 ecx: 00000000 edx: 001d9ab4
esi: 00000003 edi: 00000001 ebp: 00000293 esp: 007ddf3c
ds: 0018 es: 0018 fs: 002b gs: 002b ss: 0018
Process bash (pid: 168, process nr: 26, stackpage=007dd000)
Stack: 003f2e58 08050a40 007ddfbc 08050a40 00119a16 00000003 00000000 ffffffff
003f2e58 08050a40 007ddfbc ffff0007 001e6000 0005a000 007fc154 002a4025
002a4065 002a4067 0010ff4e 007a4018 003f2e58 08050a40 00000002 0010fde0
Call Trace: [do_wp_page+22/576] [do_page_fault+366/768] [do_page_fault+0/768] [error_code+75/96]
Code: 8b 03 89 02 89 50 04 89 d8 c1 e8 0c 8d 56 01 89 d1 d3 e8 8b
Unable to handle kernel NULL pointer dereference at virtual address c000010c
current->tss.cr3 = 00101000, @r3 = 00101000
*pde = 00102067
*pte = 00000027
Oops: 0002
CPU: 0
EIP: 0010:[exit_notify+296/496]
EFLAGS: 00010006
eax: 00000000 ebx: 00098414 ecx: 0040611c edx: 007a4018
esi: 0072c810 edi: 0000000b ebp: 007ddf00 esp: 007dde8c
ds: 0018 es: 0018 fs: 0000 gs: 0000 ss: 0018
Process bash (pid: 168, process nr: 26, stackpage=007dd000)
Stack: 001fd1f8 00115ece 0009002b 00000014 007de000 0010abd2 0000000b 001a5e69
00000000 c7200720 007ddf00 00000000 0000008b 01800000 01000000 001a0018
001100cf 001a6634 007ddf00 00000000 0010fde0 00000003 00000001 00000293
Call Trace: [do_exit+382/448] [die_if_kernel+706/736] [<01800000>] [<01000000>] [sb16_dsp_ioctl+392/480] [do_page_fault+751/768] [do_page_fault+0/768]
[error_code+75/96] [__get_free_pages+166/432] [do_wp_page+22/576] [do_page_fault+366/768] [do_page_fault+0/768] [error_code+75/96]
Code: 89 98 0c 01 00 00 8b 83 04 01 00 00 89 98 08 01 00 00 8b 03
Unable to handle kernel paging request at virtual address c7200720
current->tss.cr3 = 00292000, @r3 = 00292000
*pde = 00000000
Oops: 0000
CPU: 0
EIP: 0010:[__get_free_pages+166/432]
EFLAGS: 00010082
eax: 001d9ab4 ebx: 07200720 ecx: 00000000 edx: 001d9ab4
esi: 00000003 edi: 00000001 ebp: 00000293 esp: 00213f3c
ds: 0018 es: 0018 fs: 002b gs: 002b ss: 0018
Process dircolors (pid: 173, process nr: 29, stackpage=00213000)
Stack: 0009a818 08003000 00213fbc 08003000 00119a16 00000003 00000000 ffffffff
0009a818 08003000 00213fbc ffff0007 ffff0004 00762058 00762000 007da025
00213fbc bffffb9c 0010ff4e 003fcc0c 0009a818 08003000 00000002 0010fde0
Call Trace: [do_wp_page+22/576] [do_page_fault+366/768] [do_page_fault+0/768] [error_code+75/96]
Code: 8b 03 89 02 89 50 04 89 d8 c1 e8 0c 8d 56 01 89 d1 d3 e8 8b
Unable to handle kernel paging request at virtual address c7200720
current->tss.cr3 = 00766000, @r3 = 00766000
*pde = 00000000
Oops: 0000
CPU: 0
EIP: 0010:[__get_free_pages+166/432]
EFLAGS: 00010082
eax: 001d9ab4 ebx: 07200720 ecx: 00000000 edx: 001d9ab4
esi: 00000003 edi: 00000001 ebp: 00000293 esp: 00615f3c
ds: 0018 es: 0018 fs: 002b gs: 002b ss: 0018
Process fortune (pid: 175, process nr: 26, stackpage=00615000)
Stack: 003f2dd8 08006000 00615fbc 08006000 00119a16 00000003 00000000 ffffffff
003f2dd8 08006000 00615fbc ffff0007 00095018 00095018 001e08ec 00174e20
08004000 001d32f4 0010ff4e 0072bc0c 003f2dd8 08006000 00000002 0010fde0
Call Trace: [do_wp_page+22/576] [multwrite_intr+0/160] [do_page_fault+366/768] [do_page_fault+0/768] [error_code+75/96]
Code: 8b 03 89 02 89 50 04 89 d8 c1 e8 0c 8d 56 01 89 d1 d3 e8 8b
Unable to handle kernel paging request at virtual address c7200720
current->tss.cr3 = 0060d000, @r3 = 0060d000
*pde = 00000000
Oops: 0000
CPU: 0
EIP: 0010:[__get_free_pages+166/432]
EFLAGS: 00010082
eax: 001d9ab4 ebx: 07200720 ecx: 00000000 edx: 001d9ab4
esi: 00000003 edi: 00000001 ebp: 00000293 esp: 0060ff38
ds: 0018 es: 0018 fs: 002b gs: 002b ss: 0018
Process crond (pid: 58, process nr: 7, stackpage=0060f000)
Stack: 40018a48 0009536c 0072bc0c 0072bc0c 00118c35 00000003 00000000 ffffffff
40018a48 0009536c 00095cec 00000246 001120e9 0011216c 0072bc0c 007a4414
0800dfc0 00000000 0060ffb4 0010ff4e 007a4414 007a401c 400b5620 00000002
Call Trace: [new_page_tables+21/176] [do_fork+1225/2064] [do_fork+1356/2064] [do_page_fault+366/768] [sys_fork+18/32] [system_call+89/160]
Code: 8b 03 89 02 89 50 04 89 d8 c1 e8 0c 8d 56 01 89 d1 d3 e8 8b
Unable to handle kernel paging request at virtual address c7200720
current->tss.cr3 = 0063c000, @r3 = 0063c000
*pde = 00000000
Oops: 0000
CPU: 0
EIP: 0010:[__get_free_pages+166/432]
EFLAGS: 00010082
eax: 001d9ab4 ebx: 07200720 ecx: 00000000 edx: 001d9ab4
esi: 00000003 edi: 00000001 ebp: 00000293 esp: 006cbf3c
ds: 0018 es: 0018 fs: 002b gs: 002b ss: 0018
Process ps (pid: 178, process nr: 29, stackpage=006cb000)
Stack: 00727218 08008610 006cbfbc 08008610 00119a16 00000003 00000000 ffffffff
00727218 08008610 006cbfbc 00000007 00732ea0 00000400 08011000 bffffcb4
00732ea0 31000400 0010ff4e 007a4810 00727218 08008610 00000002 0010fde0
Call Trace: [do_wp_page+22/576] [do_page_fault+366/768] [do_page_fault+0/768] [error_code+75/96]
Code: 8b 03 89 02 89 50 04 89 d8 c1 e8 0c 8d 56 01 89 d1 d3 e8 8b
Unable to handle kernel paging request at virtual address c7200720
current->tss.cr3 = 00638000, @r3 = 00638000
*pde = 00000000
Oops: 0000
CPU: 0
EIP: 0010:[__get_free_pages+166/432]
EFLAGS: 00010082
eax: 001d9ab4 ebx: 07200720 ecx: 00000000 edx: 001d9ab4
esi: 00000003 edi: 00000001 ebp: 00000293 esp: 006cbf64
ds: 0018 es: 0018 fs: 002b gs: 002b ss: 0018
Process reboot (pid: 180, process nr: 29, stackpage=006cb000)
Stack: 0000052c 0000052c bffffad5 fffffff2 0012b9df 00000003 00000000 ffffffff
007a4810 7273752f 00000000 bffffac4 00000000 c000002f 00121dbd bffffad4
006cbfb4 007a4810 bffffc24 bffffad4 006cbfbc 0010a609 bffffad4 00000000
Call Trace: [getname+287/400] [sys_open+29/96] [system_call+89/160]
Code: 8b 03 89 02 89 50 04 89 d8 c1 e8 0c 8d 56 01 89 d1 d3 e8 8b

^^^ Even /sbin/reboot didn't work... good job sync does.

Hope this helps,
James

-- 
James M. Box                     Email: jmbox@dcs.warwick.ac.uk
Computer Systems Engineering     Email: esuec@csv.warwick.ac.uk
University of Warwick, UK        WWW: http://www.dcs.warwick.ac.uk/~jmbox/
---+++ Finger jmbox@stone.dcs.warwick.ac.uk for PGP Public Key +++---