From: Greg KH <gregkh@suse.de>
To: tyler@agat.net, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] Kmod optimization
Date: Thu, 13 Apr 2006 16:13:30 -0700 [thread overview]
Message-ID: <20060413231330.GA6760@suse.de> (raw)
In-Reply-To: <20060413190412.GA30541@Starbuck>
On Thu, Apr 13, 2006 at 09:04:12PM +0200, tyler@agat.net wrote:
> On Thu, Apr 13, 2006 at 11:50:14AM -0700, Greg KH wrote:
> > On Thu, Apr 13, 2006 at 08:36:17PM +0200, tyler@agat.net wrote:
> > > On Thu, Apr 13, 2006 at 11:24:01AM -0700, Greg KH wrote:
> > > > On Thu, Apr 13, 2006 at 08:03:45PM +0200, tyler@agat.net wrote:
> > > > > Hi,
> > > > >
> > > > > the request_mod functions try to load automatically a module by running
> > > > > a user mode process helper (modprobe).
> > > > >
> > > > > The user process is launched even if the module is already loaded. I
> > > > > think it would be better to test if the module is already loaded.
> > > >
> > > > Does this cause a problem somehow? request_mod is called _very_
> > > > infrequently from a normal kernel these days, so I really don't think
> > > > this is necessary.
> > >
> > > Yes I agree it _should_ be very infrequently called but it _will_ be very
> > > infrequently called just if the user space configuration is done properly.
> >
> > What do you mean by this? Almost all 2.6 distros use udev today, which
> > prevents this code from ever getting called. So odds are, you are
> > optimising something that no one will ever use :)
> Well perhaps I don't understand the mechanism :) But let's take an
> example.
> On all kernels (even recent), if the module smbfs is loaded, it's not
> handled by udev and request_module could be called.
>
> Let"s take another example to see to illustrate why I think
> it depends on the user configuration :
> module A depends on module B
>
> if we have a script which do "insmod moduleA.ko ; insmod moduleB.ko",
> there will be a call to request_module.
No, that script will fail. Try it out :)
The kernel will not call out to try to resolve the symbols, that's up to
userspace to handle. Hint, try running 'modprobe moduleA.ko' instead,
it will handle the dependancies correctly.
I still don't see where this is really needed...
thanks,
greg k-h
next prev parent reply other threads:[~2006-04-13 23:15 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-04-13 18:03 [PATCH] Kmod optimization tyler
2006-04-13 18:19 ` Randy.Dunlap
2006-04-13 18:57 ` Jan Engelhardt
2006-04-13 18:24 ` Greg KH
2006-04-13 18:36 ` tyler
2006-04-13 18:50 ` Greg KH
2006-04-13 19:04 ` tyler
2006-04-13 22:53 ` Roman Zippel
2006-04-13 23:13 ` Greg KH [this message]
2006-04-14 10:57 ` tyler
2006-04-13 19:10 ` Paulo Marques
2006-04-13 19:17 ` tyler
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20060413231330.GA6760@suse.de \
--to=gregkh@suse.de \
--cc=linux-kernel@vger.kernel.org \
--cc=tyler@agat.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox