lkml.org 
[lkml]   [2000]   [Mar]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] towards a /proc-less user space
On Wed Mar 08, 2000 at 10:51:27PM +0000, Matthew Kirkwood wrote:
> On Wed, 8 Mar 2000, Erik Andersen wrote:
>
> > > And devmodules is not necessary even on a normal system. lsmod provides the
> > > same info and is not using proc at all.
> >
> > Umm...
> >
> > [andersen@slag andersen]$ strace lsmod 2>&1 | grep proc
> > open("/proc/modules", O_RDONLY) = 3
> > [andersen@slag andersen]$ dlocate lsmod | grep bin
> > modutils: /sbin/lsmod
>
> matthew@jim:~$ strace /sbin/lsmod 2>&1 | grep proc
> matthew@jim:~$ rpm -qf /sbin/lsmod
> modutils-2.1.121-14

[andersen@slag andersen]$ dpkg -l modutils strace | tail -n2
ii modutils 2.3.9-3 Linux module utilities.
ii strace 4.2-4 A system call tracer.

I just downloaded the source to modutils-2.1.121,
modutils-2.2.2-pre8, and modutils-2.3.9 and every
one of them has:

open("/proc/modules", O_RDONLY)

in insmod/lsmod.c along with the comment

/* We've got no other option but to read /proc. */

I don't know where you got your strace, but I suspect it is broken. If it is
indeed working, I would dearly love to see the interface lsmod used to get the
kernel module information.

-Erik

--
Erik B. Andersen Web: http://www.xmission.com/~andersen/
email: andersee@debian.org
--This message was written using 73% post-consumer electrons--

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:56    [W:0.064 / U:0.520 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site