linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* fun or real: proc interface for module handling?
@ 2003-07-31 12:12 Nico Schottelius
  2003-07-31 12:34 ` Måns Rullgård
                   ` (2 more replies)
  0 siblings, 3 replies; 10+ messages in thread
From: Nico Schottelius @ 2003-07-31 12:12 UTC (permalink / raw)
  To: Linux Kernel Mailing List; +Cc: scholz

[-- Attachment #1: Type: text/plain, Size: 872 bytes --]

Hello!

I was just joking around here, but what do you think about this idea:

A proc interface for module handling:
   /proc/mods/
   /proc/mods/<module-name>/<link-to-the-modules-use-us>

So we could try to load a module with
   mkdir /proc/mods/ipv6
and remove it and every module which uses us with
   rm -r /proc/mods/ipv6

Modul options could be passed my
   echo "psmouse_noext=1" > /proc/mods/psmouse/options
which would also make it possible to change module options while running..

It's just an idea, perhaps someone likes this..
perhaps if there is enough feedback I even could think about
implementing it.


Greetings'

Nico

ps: please CC, the majordomo isn't answering my subscribe requests..

-- 
echo God bless America | sed 's/.*\(A.*\)$/Why \1?/'
pgp: new id: 0x8D0E27A4 | ftp.schottelius.org/pub/familiy/nico/pgp-key.new

[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 10+ messages in thread
* Re: fun or real: proc interface for module handling?
@ 2003-07-31 13:51 John Bradford
  0 siblings, 0 replies; 10+ messages in thread
From: John Bradford @ 2003-07-31 13:51 UTC (permalink / raw)
  To: linux-kernel, mru; +Cc: nico-kernel

> > I was just joking around here, but what do you think about this idea:
> >
> > A proc interface for module handling:
> >    /proc/mods/
> >    /proc/mods/<module-name>/<link-to-the-modules-use-us>
> >
> > So we could try to load a module with
> >    mkdir /proc/mods/ipv6
> > and remove it and every module which uses us with
> >    rm -r /proc/mods/ipv6
>
> So far, so good.
>
> > Modul options could be passed my
> >    echo "psmouse_noext=3D1" > /proc/mods/psmouse/options
> > which would also make it possible to change module options while runn=
> ing..
>
> How would options be passed when loading?  Some modules require that
> to load properly.  Also, there are lots of options that can't be
> changed after loading.  To enable this, I believe the whole option
> handling would need to be modified substantially.  Instead of just
> storing the values in static variables, there would have to be some
> means of telling the module that its options changed.  Then there's
> the task of hacking all modules to support this...

Or you could just cause the module to be unloaded and reloaded
whenever options changed.

Not that I like this idea anyway, but then I don't use modules :-).

John.

^ permalink raw reply	[flat|nested] 10+ messages in thread
* RE: fun or real: proc interface for module handling?
@ 2003-08-01 13:54 Downing, Thomas
  0 siblings, 0 replies; 10+ messages in thread
From: Downing, Thomas @ 2003-08-01 13:54 UTC (permalink / raw)
  To: 'Stuart Longland', linux-kernel

> -----Original Message-----
> From: Stuart Longland [mailto:stuartl@longlandclan.hopto.org]
> On Thu, Jul 31, 2003 at 02:34:01PM +0200, Måns Rullgård wrote:
> 
> | Nico Schottelius <nico-kernel@schottelius.org> writes:
> | > Modul options could be passed my
> | >   echo "psmouse_noext=1" > /proc/mods/psmouse/options
> | > which would also make it possible to change module options while
> running..
> |
> | How would options be passed when loading?  Some modules require that
> | to load properly.
> 
> Possibility, why not just have a file, /proc/mods/initial, that you
> write the initial kernel module options to, e.g.
> 
> # echo "ne2000 io=0x300 irq=11" > /proc/mods/initial
> 
> Then you load the module using:
> 
> # mkdir /proc/mods/ne2000/
> 
> although you could skip this necessity and just load the module when
> someone writes to /proc/mods/initial.
> 
> Just a thought.

>From an newbie:

How about having a dir for each available module created earliest moment
in boot process, (point where depmod is done now I guess).  Each dir has
files 'options' and 'load'.  then you could:

# echo "io=0x300 irq=11" > /proc/mods/ne2000/options

followed by

# echo "1" > /proc/mods/ne2000/load

Of course, I am probably missing the point or something :-(

td

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2003-08-01 13:55 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-07-31 12:12 fun or real: proc interface for module handling? Nico Schottelius
2003-07-31 12:34 ` Måns Rullgård
2003-07-31 13:03   ` Gábor Lénárt
2003-07-31 23:15   ` jw schultz
2003-08-01  5:55     ` Stuart Longland
2003-07-31 13:13 ` Yaroslav Rastrigin
2003-07-31 13:29   ` Nico Schottelius
2003-07-31 23:59 ` Grant Miner
2003-07-31 13:51 John Bradford
2003-08-01 13:54 Downing, Thomas

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).