From: Keith Owens <kaos@ocs.com.au>
To: David Woodhouse <dwmw2@infradead.org>
Cc: Ingo Oeser <ingo.oeser@informatik.tu-chemnitz.de>,
Alan Cox <alan@lxorguk.ukuu.org.uk>,
List Linux-Kernel <linux-kernel@vger.kernel.org>
Subject: Re: Where did vm_operations_struct->unmap in 2.4.0 go?
Date: Fri, 12 Jan 2001 22:55:41 +1100 [thread overview]
Message-ID: <31327.979300541@ocs3.ocs-net> (raw)
In-Reply-To: Your message of "Fri, 12 Jan 2001 10:27:34 -0000." <Pine.LNX.4.30.0101121005140.19393-100000@imladris.demon.co.uk>
On Fri, 12 Jan 2001 10:27:34 +0000 (GMT),
David Woodhouse <dwmw2@infradead.org> wrote:
>On Fri, 12 Jan 2001, Keith Owens wrote:
>> A typical graph would have scsi disk depends on scsi host adaptor group
>> which depends on pci.
>
>No. sd will happily take over any existing devices when as and when they
>arrive. It doesn't have to be loaded last. Likewise, in theory at least,
>host adaptor drivers using the new PCI driver code would respond correctly
>to the PCI code being initialised (and calling their ->probe routine)
>later, although that doesn't happen now.
You just proved my point. It is extremely difficult to deduce the
required initialisation order by reading an undocumented Makefile where
the init order is implemented as a side effect of selection order. The
existing method implies link order when none is required.
>> Most of the objects have fairly simple execution dependencies, e.g.
>> all file systems depend on core fs code having already executed.
>
>Er... Why? They call register_filesystem() which uses a lock which is
>staticly initialised. Don't order stuff for the sake of it. If there are
>filesystems which _do_ require the VFS to be initialised first, those
>filesystems can be marked as such. I'm not aware of any.
I was using scsi and fs as examples, no need to pick holes in the
examples. But ...
fs/buffer.c:module_init(bdflush_init)
fs/pipe.c:module_init(init_pipe_fs)
fs/fcntl.c:module_init(fasync_init)
fs/locks.c:module_init(filelock_init)
fs/dnotify.c:module_init(dnotify_init)
I'm no filesystem expert but it appears that some of those core
initialisation routines must be executed before most filesystems can
start. In particular, filelock_init() must be executed before any
filesystem that supports locks is initialised.
>All I want is a way to staticly add entries to the
>inter_module_xxx tables at compile time, because I _have_ done the
>analysis, and I'm saying that's when they should be made available.
Firstly inter_module_xxx is only used by that very small subset of code
where there are no constraints on whether the caller and callee can be
in kernel, in modules or a mixture _and_ some of the objects are
optional. It is a special case because most code handles this problem
through CONFIG options. If X needs (Y, Z) and X is built into the
kernel then (Y, Z) must also be built into the kernel. If Y or Z are
optional then control the calls to those functions with CONFIG options.
Almost all of the kernel handles it properly though CONFIG, so
inter_module_xxx is already a process to handle a few special cases.
Secondly you want static inter_module_xxx tables for a small subset of
these special cases, where the source has no other initialisation code.
This is piling special cases on special cases. Adding static
inter_module_xxx tables requires
* changes to linux/modules.h to define the new table format and
* changes to vmlinux.lds for _every_ architecture to bring all the
static tables together in vmlinux and
* new initialisation code in module.c to read and load all the static
tables at boot time and
* extra code in modutils to find any static tables in modules and
* an extension to struct modules to let modutils pass information about
the static tables to the kernel and
* the kernel code will only work with an upgraded modutils.
That is a lot of work for a very few special cases. OTOH, you could
just swap the order of 3 lines in drivers/mtd/Makefile. Guess which
alternative I am going for?
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/
next prev parent reply other threads:[~2001-01-12 11:56 UTC|newest]
Thread overview: 41+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-01-10 3:27 Where did vm_operations_struct->unmap in 2.4.0 go? Allen Unueco
2001-01-10 3:50 ` Keith Owens
2001-01-11 5:38 ` Antony Suter
2001-01-11 6:05 ` Keith Owens
2001-01-11 11:42 ` David Woodhouse
2001-01-11 12:12 ` Keith Owens
2001-01-11 12:32 ` David Woodhouse
2001-01-11 12:46 ` Keith Owens
2001-01-11 13:09 ` Alan Cox
2001-01-11 13:14 ` Keith Owens
2001-01-12 2:12 ` Ingo Oeser
2001-01-12 2:30 ` Keith Owens
2001-01-12 10:27 ` David Woodhouse
2001-01-12 11:55 ` Keith Owens [this message]
2001-01-12 13:40 ` David Woodhouse
2001-01-12 12:01 ` Daniel Phillips
2001-01-12 12:18 ` Keith Owens
2001-01-14 10:16 ` Kai Henningsen
2001-01-11 13:25 ` David Woodhouse
[not found] <3A5EFC56.F1A5BCE0@mira.net>
2001-01-12 19:11 ` Christian Zander
2001-01-13 1:11 ` Keith Owens
2001-01-13 10:46 ` David Woodhouse
2001-01-13 12:06 ` Keith Owens
2001-01-13 15:09 ` David Woodhouse
2001-01-13 19:03 ` Russell King
2001-01-14 0:21 ` Keith Owens
2001-01-14 9:43 ` David Woodhouse
2001-01-14 10:05 ` Keith Owens
2001-01-14 10:45 ` David Woodhouse
2001-01-14 4:04 ` Linus Torvalds
2001-01-14 17:46 ` David Woodhouse
2001-01-14 19:12 ` Linus Torvalds
2001-01-14 20:02 ` David Woodhouse
2001-01-14 20:15 ` Linus Torvalds
2001-01-14 21:15 ` David Woodhouse
2001-01-14 21:47 ` Linus Torvalds
2001-01-14 21:57 ` David Woodhouse
2001-01-14 23:00 ` Keith Owens
2001-01-15 9:09 ` David Woodhouse
2001-01-13 11:46 ` Christian Zander
2001-01-13 12:23 ` Keith Owens
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=31327.979300541@ocs3.ocs-net \
--to=kaos@ocs.com.au \
--cc=alan@lxorguk.ukuu.org.uk \
--cc=dwmw2@infradead.org \
--cc=ingo.oeser@informatik.tu-chemnitz.de \
--cc=linux-kernel@vger.kernel.org \
/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