public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Andy Whitcroft <apw@shadowen.org>
To: jschopp <jschopp@austin.ibm.com>
Cc: Andrew Morton <akpm@osdl.org>,
	Randy Dunlap <rdunlap@xenotime.net>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] update checkpatch.pl to version 0.03
Date: Tue, 05 Jun 2007 19:45:20 +0100	[thread overview]
Message-ID: <4665AF40.5020800@shadowen.org> (raw)
In-Reply-To: <46644A48.4090300@austin.ibm.com>

jschopp wrote:
>> The original suggestion was to count them and only complain if there
>> were "lots".  I had thought though that the general consensus was that
>> #ifdef in C files was pretty much frowned upon.  I must admit to working
>> to the "you must be able to justify all winges in the output" rather
>> than expecting the result to be empty necessarily.
> 
> I really think we should work towards, "if you see an error the odds are
> overwhelming that we aren't wasting your time and you should fix this."
> rather than, "every time you send a patch you will get a couple false
> positives that you will have to think about and justify to yourself,
> slowing down your sending the patch out and making more work for you". 
> I'm not saying we have to have 100% accuracy, but I want it well in the
> 90s.

Yeah I tend to agree and most of my work to date has been squashing
false positives.

> Now back to the ifdef's.  I don't think we can really even say a lot or
> a little is broken (short patch can do 1 ifdef that is stupid, long
> patch could do several that are good).  I think we'll either have to let
> that one go or put it under a non-default flag.    We do still have
> humans reviewing code who can make judgement calls like if you #ifdefs
> are good or not.
> 
> What we can check for is #if 0 code.  I hate that one.

For now I've disabled this one.  Put it in the freezer with the
StudlyCaps one.

I like the idea of checking for #if 0 as that is very likely bogus in a
patch meant for inclusion.

>> We've not talked about how the tool might grow.  My thought was that
>> soon we would enable the robot replies on linux-mm (say) and use the
>> feedback from that to tune what we do and do not report.  I have been
>> pushing all of the contributions to -mm for sometime through it and
>> cirtainly the #ifdef one once of the more common ones (other than white
>> space dammage and >80 character lines).
> 
> If you have reasonably good SPAM filters on your list and make the robot
> so it is very good about only picking up mail that really are patches
> then this could be a very good idea. Just be careful.  I could send out
> a bunch of mail with fake headers saying it was from say Andy Whitcroft,
> then the robot replies and you got a bunch of junk mail.

All very good points.  It does only reply to emails which are clearly
unidiff patches and silently drops all else.  But the potential for spam
is worrysome ... will think on this some and see if we can come up with
a safety net.

> User feedback is really useful, both for us and for the user.  Based on
> user feedback from the very small number of users I had I tweaked a lot
> of regular expressions, added some new checks, and removed some I could
> never get right.

I am getting a fair bit of feedback, most of it copied to Joel and Randy
so at least that bit is working.

-apw

  reply	other threads:[~2007-06-05 18:45 UTC|newest]

Thread overview: 45+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-06-04  9:46 [PATCH] update checkpatch.pl to version 0.03 Andy Whitcroft
2007-06-04  9:55 ` [PATCH] update feature-removal-schedule.txt to include deprecated functions Andy Whitcroft
2007-06-04 15:49 ` [PATCH] update checkpatch.pl to version 0.03 jschopp
2007-06-04 16:51   ` Andy Whitcroft
2007-06-04 17:22     ` jschopp
2007-06-05 18:45       ` Andy Whitcroft [this message]
2007-06-05  9:56   ` Andy Whitcroft
2007-06-04 16:25 ` Jan Engelhardt
2007-06-04 18:41 ` Andrew Morton
2007-06-04 19:08   ` Andy Whitcroft
2007-06-04 19:08     ` Rene Herman
2007-06-04 20:04       ` Randy Dunlap
2007-06-05 18:39         ` Andy Whitcroft
2007-06-08  9:31       ` Andy Whitcroft
2007-06-08 10:08         ` Rene Herman
2007-06-05  8:14 ` Heiko Carstens
2007-06-06  9:05 ` Jesper Juhl
2007-06-07 14:28   ` Jan Engelhardt
2007-06-07 14:39     ` Jesper Juhl
2007-06-07 19:34     ` Adrian Bunk
2007-06-07 22:22       ` Alan Cox
2007-06-07 23:21         ` Adrian Bunk
2007-06-07 23:41           ` Alan Cox
2007-06-08  0:04             ` Adrian Bunk
2007-06-08  4:37               ` Jon Masters
2007-06-08  8:58               ` Jan-Benedict Glaw
2007-06-08 10:52               ` Alan Cox
2007-06-08 12:39                 ` Adrian Bunk
2007-06-08 14:34                   ` Jesper Juhl
2007-06-08 14:42                     ` Adrian Bunk
2007-06-08 15:16                       ` Jan Engelhardt
2007-06-08 15:37                         ` Jon Masters
2007-06-08 15:42                         ` Alan Cox
2007-06-08 16:39                           ` Adrian Bunk
2007-06-08 18:43                             ` Jan Engelhardt
2007-06-08 16:03                     ` Roland Dreier
2007-06-07 23:49           ` Adrian Bunk
2007-06-07 19:32   ` Adrian Bunk
2007-06-07 22:18     ` Alan Cox
2007-06-06 11:49 ` Jesper Juhl
2007-06-07 11:46   ` Andy Whitcroft
2007-06-07 11:52     ` Jesper Juhl
2007-06-07 15:16       ` checkpatch.pl: should be executable Andy Whitcroft
2007-06-07 15:33         ` jschopp
2007-06-07 14:22     ` [PATCH] update checkpatch.pl to version 0.03 Jan Engelhardt

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=4665AF40.5020800@shadowen.org \
    --to=apw@shadowen.org \
    --cc=akpm@osdl.org \
    --cc=jschopp@austin.ibm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rdunlap@xenotime.net \
    /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