lkml.org 
[lkml]   [1999]   [Aug]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: More linker magic..
From
Date
Matthew Kirkwood <weejock@ferret.lmh.ox.ac.uk> writes:

|> On 3 Aug 1999, Andi Kleen wrote:
|>
|> > Would it make sense to add a "priority" argument to __initcall ?
|> > This would allow to express simple dependencies between modules. Of
|> > course this could be emulated by immediate functions that do the
|> > traditional manual initialization.
|>
|> > The standard[1] linker cannot sort constructors, but system startup is
|> > not performance critical, so it is reasonable to sort the init table
|> > at runtime.
|>
|> Sort? Pah, why not just force the priority to be between 0 and 10 and
|> scan the whole thing 11 times :)

Just put the constructors in 11 sections with names like initcall_0
... initcall_10 and setup some symbols to find them, then you can get away
with a single scanning pass.

Andreas.

--
Andreas Schwab "And now for something
schwab@suse.de completely different."
SuSE GmbH, Schanzäckerstr. 10, D-90443 Nürnberg

-
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:53    [W:0.100 / U:1.352 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site