LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
From: "Robert P. J. Day" <rpjday@mindspring.com>
To: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: Linux kernel mailing list <linux-kernel@vger.kernel.org>
Subject: Re: identifying CONFIG variable typoes in the source tree
Date: Wed, 24 Jan 2007 05:33:13 -0500 (EST) [thread overview]
Message-ID: <Pine.LNX.4.64.0701240511300.23168@CPE00045a9c397f-CM001225dbafb6> (raw)
In-Reply-To: <Pine.LNX.4.62.0701240917530.30467@pademelon.sonytel.be>
On Wed, 24 Jan 2007, Geert Uytterhoeven wrote:
> On Tue, 23 Jan 2007, Robert P. J. Day wrote:
> > let's check these:
> >
> > $ grep -r 53C700_BE_BUS .
> > ./drivers/scsi/53c700.h:#ifdef CONFIG_53C700_BE_BUS
>
> This is the core support for big endian 53c700 SCSI busses. It's
> needed for various m68k machines, patch to be submitted when the
> m68k support is ready for submission.
>
> Gr{oetje,eeting}s,
just to be clear, all that script is doing is identifying variables
of the form "CONFIG_fubar" that are being tested in *some*
preprocessor directive somewhere in the tree, but for which there is
apparently no corresponding entry in a Kconfig file anywhere that
could cause that variable to be configured.
naturally, as geert suggests, this might represent a feature that's
in progress so it's clearly not a mistake. but it's a good way to
trap potential problems, as in finding "GALILLEO_GT64240_ETH" which,
superficially, would seem like an obvious typo no matter what:
$ grep -r GALILLEO_GT64240_ETH .
./arch/mips/momentum/ocelot_g/prom.c:#ifdef CONFIG_GALILLEO_GT64240_ETH
./arch/mips/momentum/ocelot_g/prom.c:#ifdef CONFIG_GALILLEO_GT64240_ETH
./arch/mips/momentum/ocelot_g/setup.c:#ifdef CONFIG_GALILLEO_GT64240_ETH
./arch/mips/momentum/ocelot_g/setup.c:#ifdef CONFIG_GALILLEO_GT64240_ETH
$
as well as what is *obviously* dead code:
$ grep -rw CONFIG_KERNELD .
./sound/core/timer.c:#ifdef CONFIG_KERNELD
$ grep -rw KERNELD .
./net/core/dev.c: * Bjorn Ekwall : Added KERNELD hack.
the script isn't perfect -- it will generate false positives if the
variable is being set elsewhere -- perhaps hardcoded in the file or
defined in a Makefile. but if you're curious, just run it against
your favourite subdirectory and see what comes up.
rday
prev parent reply other threads:[~2007-01-24 10:33 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-01-23 21:13 Robert P. J. Day
2007-01-23 23:35 ` Oleg Verych
2007-01-24 2:02 ` Robert P. J. Day
2007-01-24 8:21 ` Geert Uytterhoeven
2007-01-24 10:33 ` Robert P. J. Day [this message]
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=Pine.LNX.4.64.0701240511300.23168@CPE00045a9c397f-CM001225dbafb6 \
--to=rpjday@mindspring.com \
--cc=geert@linux-m68k.org \
--cc=linux-kernel@vger.kernel.org \
--subject='Re: identifying CONFIG variable typoes in the source tree' \
/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
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).