Re: dead CONFIG_ variables: net/ipv4/

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

 



On Tue, 29 May 2007, David Miller wrote:

> From: "Robert P. J. Day" <[email protected]>
> Date: Wed, 2 May 2007 17:15:01 -0400 (EDT)
>
> >
> >   again, this list contains some CONFIG_ variables that aren't
> > technically dead, but *really* should be renamed to not be confused
> > with Kconfig variables.  there are, however, legitimately dead ones in
> > the following in places:
> >
> > $ ../dead_config.sh net/ipv4
> > ========== IP_FIB_TRIE_STATS ==========
> > net/ipv4/fib_trie.c:#undef CONFIG_IP_FIB_TRIE_STATS
> > net/ipv4/fib_trie.c:#ifdef CONFIG_IP_FIB_TRIE_STATS
> > net/ipv4/fib_trie.c:#ifdef CONFIG_IP_FIB_TRIE_STATS
> > net/ipv4/fib_trie.c:#ifdef CONFIG_IP_FIB_TRIE_STATS
> > net/ipv4/fib_trie.c:#ifdef CONFIG_IP_FIB_TRIE_STATS
> > net/ipv4/fib_trie.c:#ifdef CONFIG_IP_FIB_TRIE_STATS
> > net/ipv4/fib_trie.c:#ifdef CONFIG_IP_FIB_TRIE_STATS
> > net/ipv4/fib_trie.c:#ifdef CONFIG_IP_FIB_TRIE_STATS
> > net/ipv4/fib_trie.c:#ifdef CONFIG_IP_FIB_TRIE_STATS
> > net/ipv4/fib_trie.c:#ifdef CONFIG_IP_FIB_TRIE_STATS
> > net/ipv4/fib_trie.c:#ifdef CONFIG_IP_FIB_TRIE_STATS
> > net/ipv4/fib_trie.c:#ifdef CONFIG_IP_FIB_TRIE_STATS
> > net/ipv4/fib_trie.c:#endif /*  CONFIG_IP_FIB_TRIE_STATS */
>
> Robert Olsson uses this for statistics collection by turning
> that #undef there into a #define and other developers could
> use this too.
>
> Therefore I'm reluctant to remove this for now.

there's lots of that sort of thing in the kernel -- the only point i'd
make is that it seems typical to reserve the prefix "CONFIG_" strictly
for those variables that are set via Kconfig files.  it just makes the
namespace cleaner, that's all.  otherwise, that variable is going to
come up continually in any script like mine that's searching for
possible dead Kconfig variables.

> > ========== IP_PIMSM ==========
> > net/ipv4/ipmr.c:#define CONFIG_IP_PIMSM 1

as is this one, etc, etc.

rday
-- 
========================================================================
Robert P. J. Day
Linux Consulting, Training and Annoying Kernel Pedantry
Waterloo, Ontario, CANADA

http://fsdev.net/wiki/index.php?title=Main_Page
========================================================================
-
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