Re: 2.6.16-rc1-mm5

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Feb 03, 2006 at 12:07:04AM -0800, Andrew Morton wrote:
> 
> Known problems:
> 
> - Sam has added a new check in the kbuild tree.  It detects multiple
>   instances of EXPORT_SYMBOL(foo) across separate .o files.
> 
>   It catches a _lot_ of problems.   You'll see something like this:

Sigh. I did a 'make allmodconfig' on x86_64 and found to my suprise only
a sinlge symbol being exported more than one time.

This is purely a consistency check introduced by commit:
http://www.kernel.org/git/?p=linux/kernel/git/sam/kbuild.git;a=commit;h=cd1f125e5808203d3bf58f1d04a9cbd33f60fdb6

I can rip it out again if the noise/value ratio is too high.

 
>   Patches would be nice, but be warned that fixing these is not as trivial
>   as one might think:
> 
>   - If one export is in generic code and the other is in arch code then
> 
>     - If you remove the export in generic code, you need to check all
>       architectures for breakage.
We should IMO try to keep the exports in generic code.
The exports should go with the function definition - right after closing
'{'.
All other ways of exporting function is a call for inconsistency.
A gret deal of effort has been put into getting rid of ksym files
- good. But exports should not be scattered far away form the function
definition.
  
>     - If you remove the export in arch code then you need to be sure
>       that the generic .o file a) always compiles in the offending function
>       and b) is always linked into vmlinux.
Placing the export just below the function definition should cover this
in 90% of the cases. The rest is macros..

> 
>   If possible, the best approach is to put the EXPORT_SYMBOL
>   immediately after the symbol which is being exported.  And if it's
>   a function, pleeeze don't put a blank line between the end of the
>   function and the export - I've no idea why people do that...
Agreed.

	Sam
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux