lkml.org 
[lkml]   [1997]   [Sep]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Subject2.1.57 /proc problem
Date

My module registers a /proc/egg regular file (with automatic
inode numbering) during initialization and unregisters it
at cleanup. Sounds quite normal, doesn't it ;-)

This worked fine with kernel up to 2.0.30-preX using
proc_register_dynamic and proc_unregister.


In 2.1.57 it seemed to work using proc_register and proc_unregister.

But strange results occured after proc_unregiste (module unload):

"ls -l /proc/e*" doesn't show /proc/egg.
"ls -l /proc/egg" shows it!
"cat /proc/egg" segfaults :-(


Is this a bug or a feature ;-) ?



/var/log/messages extract of segfault:
--------------------------------------
Sep 28 23:44:48 hmsysv kernel: Code: <1>Unable to handle kernel paging request at virtual address 00018124
Sep 28 23:44:48 hmsysv kernel: current->tss.cr3 = 023a2000, hr3 = 023a2000
Sep 28 23:44:48 hmsysv kernel: *pde = 00000000
Sep 28 23:44:48 hmsysv kernel: Oops: 0000
Sep 28 23:44:48 hmsysv kernel: CPU: 0
Sep 28 23:44:48 hmsysv kernel: EIP: 0010:[<c0109746>]
Sep 28 23:44:48 hmsysv kernel: EFLAGS: 00010082
Sep 28 23:44:48 hmsysv kernel: eax: 00000010 ebx: 0000002b ecx: 00018124 edx: 00000010
Sep 28 23:44:48 hmsysv kernel: esi: 00000000 edi: c189a000 ebp: c1899f2c esp: c1899eb8
Sep 28 23:44:48 hmsysv kernel: ds: 0018 es: 0018 ss: 0018
Sep 28 23:44:48 hmsysv kernel: Process cat (pid: 14392, process nr: 59, stackpage=c1899000)
Sep 28 23:44:48 hmsysv kernel: Stack: c01b002b c1899f2c 00018124 c1899f2c c3bebd40 c4800000 c5000000 c4800000
Sep 28 23:44:48 hmsysv kernel: c01f0018 c01097c0 c1899f2c c01bdfb3 c01beb02 00000000 00000000 c010df22
Sep 28 23:44:48 hmsysv kernel: c01beb02 c1899f2c 00000000 c1898000 c31b5da0 c1689000 00000000 08048000
Sep 28 23:44:48 hmsysv kernel: Call Trace: [<c01b002b>] [<c4800000>] [<c5000000>] [<c4800000>] [<c01097c0>] [<c01bdfb3>] [<c01beb02>]
Sep 28 23:44:48 hmsysv kernel: [<c010df22>] [<c01beb02>] [<c0119241>] [<c01093d2>] [<c0143384>] [<c482cf30>] [<c0121ddf>] [<c010925a>]
Sep 28 23:44:48 hmsysv kernel: Code: 64 8a 04 0e 0f a1 88 c2 81 e2 ff 00 00 00 89 54 24 10 52 68

Cheers, Heinz

--

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Heinz Mauelshagen Deutsche Telekom
mge@ez-darmstadt.telekom.de Entwicklungszentrum Darmstadt
Otto-Roehm-Strasse 71c
Postfach 10 05 41
64205 Darmstadt
Germany
+49 6151 886-425
FAX-386
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

\
 
 \ /
  Last update: 2005-03-22 13:40    [from the cache]
©2003-2011 Jasper Spaans