All of lore.kernel.org
 help / color / mirror / Atom feed
From: Joe Perches <joe@perches.com>
To: Steven Rostedt <rostedt@goodmis.org>
Cc: ksummit-discuss@lists.linuxfoundation.org,
	Jason Cooper <jason@lakedaemon.net>,
	Dan Carpenter <dan.carpenter@oracle.com>
Subject: Re: [Ksummit-discuss] checkpatch.pl stuff...
Date: Sat, 11 Jul 2015 06:42:11 -0700	[thread overview]
Message-ID: <1436622131.2711.55.camel@perches.com> (raw)
In-Reply-To: <20150711085119.2f03e6ae@grimm.local.home>

On Sat, 2015-07-11 at 08:51 -0400, Steven Rostedt wrote:
> On Sat, 11 Jul 2015 13:34:47 +0200
> Heiko Carstens <heiko.carstens@de.ibm.com> wrote:
> 
> > The 80 character limit warning is the only thing I really dislike about
> > checkpatch. I've seen so many patches with insane ;) line breaks just to
> > satisfy this rule.
> > Unfortunately even experienced developers think this is a hard limit.
> > Argueing that checkpatch just gives you a hint that something _could_ be
> > improved are most of the time pointless. "But checkpatch says... therefore
> > it has be to like that." ;)
> > 
> > Besides that it I think it works just fine.
> 
> I'll admit, as Dan said, that my patches are somewhat "special". But
> what I really hate, is that argument I have had with people where I
> comment on a patch, and they argue the "but checkpatch says". Yeah,
> that can get annoying.

It can and does.  Especially the "long_lines" message.

It'd be good if somehow checkpatch output could be
viewed more as lighthearted suggestions rather than
iron-clad rules.

Maybe changing the "WARNING" type messages to a new
"SUGGESTION" might be better to let people know that
it's OK to ignore some rules.

Maybe reclassifying some ERROR type messages to
WARNING/SUGGESTION might help.

I'd like to see checkpatch used quite a bit less on
files and perhaps a bit more on actual patches.

I've suggested a few things.

https://lkml.org/lkml/2015/2/11/433

o Only allow checkpatch to be used with the -f/--file
  option for drivers/staging/
o Add an undocumented --force command line option
o Make --strict the default for drivers/staging

I think these checkpatch style-based --type=<foo>
white-space rules are generally reasonable and should
nearly always be followed for basic kernel style
conformance:

o spacing
o space_before_tab
o pointer_location
o trailing_whitespace
o bracket_space
o leading_space

The brace line position rules are generally reasonable:

o open_brace
o braces
o else_after_brace
o while_after_brace

The vertical line rules like "blank line after
declarations" and "consecutive blank lines" are
likely reasonable but may be dubious.

o line_spacing

There are some additional rules active only when
the --strict option is used that some like

o spacing 
  (space after a cast)
  (spaces around operators and arithmetic)
o line spacing
  (blank line after function/struct/union/enum)

These style-based rules are perhaps a bit dubious:

o long_line
o logical_continuations
o parenthesis_alignment

This one I think senseless (minimum 4 line), but
there is an override capability:

o config_description

  reply	other threads:[~2015-07-11 20:49 UTC|newest]

Thread overview: 359+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-07-07 23:21 [Ksummit-discuss] [CORE TOPIC] Recruitment (Reviewers, Testers, Maintainers, Hobbyists) Peter Huewe
2015-07-07 23:49 ` Laurent Pinchart
2015-07-08  0:50   ` Guenter Roeck
2015-07-08  1:40     ` NeilBrown
2015-07-08 19:45       ` Laurent Pinchart
2015-07-09 19:37         ` Darren Hart
2015-07-09 20:11           ` josh
2015-07-09 20:38             ` Luis R. Rodriguez
2015-07-09 21:00               ` josh
2015-07-09 21:03                 ` Luis R. Rodriguez
2015-07-09 21:42                   ` Luck, Tony
2015-07-11  8:32                   ` Fengguang Wu
2015-07-09 21:24                 ` Julia Lawall
2015-07-09 21:46                   ` David Woodhouse
2015-07-09 23:11                   ` josh
2015-07-09 23:30                     ` Luis R. Rodriguez
2015-07-09 23:35                     ` Julia Lawall
2015-07-09 23:49                       ` josh
2015-07-12 21:44                       ` Laurent Pinchart
2015-07-16  9:21                         ` David Woodhouse
2015-07-16  9:26                           ` James Bottomley
2015-07-16  9:39                             ` David Woodhouse
2015-07-16  9:38                           ` Peter Huewe
2015-07-11  4:34                     ` Fengguang Wu
2015-07-10  8:19                 ` Peter Huewe
2015-07-10 17:06                   ` Luck, Tony
2015-07-10  8:54                 ` James Bottomley
2015-07-12  2:02                   ` Fengguang Wu
2015-07-12  5:19                     ` Josh Triplett
2015-07-12  8:19                       ` James Bottomley
2015-07-12 10:48                         ` Fengguang Wu
2015-07-12 18:23                           ` Josh Triplett
2015-07-13 10:48                       ` Mark Brown
2015-07-10 15:32                 ` Steven Rostedt
2015-07-10 16:32                   ` Josh Triplett
2015-07-09 20:43             ` Darren Hart
2015-08-03 12:38             ` Fengguang Wu
2015-08-05  7:48               ` Darren Hart
2015-08-05 23:16                 ` Fengguang Wu
2015-07-09 22:31           ` David Woodhouse
2015-07-09 23:08             ` Julia Lawall
2015-07-09 23:38             ` Darren Hart
2015-07-09 23:41               ` David Woodhouse
2015-07-09 23:59                 ` Theodore Ts'o
2015-07-10  0:55               ` Rafael J. Wysocki
2015-07-10  2:00                 ` Darren Hart
2015-07-10  0:35             ` Mark Brown
2015-07-10  2:07               ` Darren Hart
2015-07-10 12:44                 ` Jason Cooper
2015-07-10 18:24                   ` Mark Brown
2015-07-10 20:40                     ` josh
2015-07-13 10:00                       ` Mark Brown
2015-07-10 19:51                 ` Steven Rostedt
2015-07-10 20:00                   ` David Woodhouse
2015-07-10 20:31                     ` Steven Rostedt
2015-07-10 20:40                       ` David Woodhouse
2015-07-10 20:43                         ` Josh Boyer
2015-07-12 10:23                           ` Geert Uytterhoeven
2015-07-10 23:09                         ` Darren Hart
2015-07-10 23:37                           ` David Woodhouse
2015-07-10 23:54                             ` Darren Hart
2015-07-10 20:56                     ` josh
2015-07-10 21:03                       ` David Woodhouse
2015-07-10 21:07                         ` josh
2015-07-10 23:11                           ` Darren Hart
2015-07-12 10:28                           ` Geert Uytterhoeven
2015-07-12 18:22                             ` Josh Triplett
2015-07-10 23:01                     ` Darren Hart
2015-07-12 10:17                     ` Geert Uytterhoeven
2015-07-12 22:00                     ` Laurent Pinchart
2015-07-13 10:11                       ` Geert Uytterhoeven
2015-07-13 10:21                         ` Laurent Pinchart
2015-07-13 16:18                       ` Guenter Roeck
2015-07-13 17:59                         ` Jonathan Cameron
2015-07-14 15:31                       ` David Woodhouse
2015-07-14 17:05                         ` Jason Cooper
2015-07-10 20:03                   ` Tim Bird
2015-07-10 20:11                     ` Guenter
2015-07-10 20:54                   ` josh
2015-07-10 22:57                     ` Darren Hart
2015-07-11  0:00                     ` Dan Williams
2015-07-10 12:32             ` Jason Cooper
2015-07-10 15:54               ` Darren Hart
2015-07-10 16:22                 ` Jason Cooper
2015-07-10 14:36           ` Dan Carpenter
2015-07-10 16:07             ` Darren Hart
2015-07-10 22:23               ` Greg KH
2015-07-11  0:00                 ` Darren Hart
2015-07-11  0:13                   ` Greg KH
2015-07-11  2:39                     ` Darren Hart
2015-07-11 15:04                       ` Greg KH
2015-07-12 21:27                         ` Peter Hüwe
2015-07-14 23:58                           ` Darren Hart
2015-07-14  2:24                         ` Darren Hart
2015-07-11  5:54                     ` Sudip Mukherjee
2015-07-11 13:29                       ` Julia Lawall
2015-07-11 15:18                         ` Jason Cooper
2015-07-11 16:45                           ` Greg KH
2015-07-11 19:35                             ` Jason Cooper
2015-07-11 22:45                               ` Greg KH
2015-07-12  1:16                                 ` Jason Cooper
2015-07-16  1:20                       ` Steven Rostedt
2015-07-16 13:25                         ` Mark Brown
2015-07-16 13:47                           ` Steven Rostedt
2015-07-16 13:56                             ` Sudip Mukherjee
2015-07-16 15:03                               ` Mark Brown
2015-07-16 14:41                             ` Mark Brown
2015-07-16 14:46                               ` James Bottomley
2015-07-16 15:12                                 ` Mark Brown
2015-07-16 15:27                                   ` Jiri Kosina
2015-07-16 18:39                                     ` Mark Brown
2015-07-16 14:57                               ` Steven Rostedt
2015-07-16 15:18                                 ` Mark Brown
2015-07-16 15:33                                   ` Steven Rostedt
2015-07-16 15:04                             ` Tim Bird
2015-07-16 15:12                               ` Ralf Baechle
2015-07-16 15:26                                 ` Steven Rostedt
2015-07-16 15:34                                 ` Tim Bird
2015-07-16 16:51                                 ` Mark Brown
2015-07-17 16:12                                 ` Guenter Roeck
2015-07-16 15:41                               ` Jonathan Corbet
2015-07-16 15:50                                 ` Steven Rostedt
2015-07-16 15:52                                 ` Tim Bird
2015-07-16 16:10                                   ` Steven Rostedt
2015-07-16 15:57                                 ` Josh Triplett
2015-07-16 15:57                                 ` Olof Johansson
2015-07-17 16:19                                   ` Guenter Roeck
2015-07-16 16:09                                 ` Tim Bird
2015-07-16 16:16                                   ` Steven Rostedt
2015-07-16 16:24                                     ` Tim Bird
2015-07-16 16:52                                       ` Steven Rostedt
2015-07-18  1:42                                         ` NeilBrown
2015-07-18  3:48                                           ` Steven Rostedt
2015-07-31 13:09                                         ` Nicolas Ferre
2015-07-31 14:22                                           ` James Bottomley
2015-08-01 18:16                                             ` Geert Uytterhoeven
2015-08-01 18:19                                               ` James Bottomley
2015-08-01 18:42                                                 ` Geert Uytterhoeven
2015-08-01 22:16                                                   ` NeilBrown
2015-08-01 22:45                                                     ` Jiri Kosina
2015-08-03 15:49                                                       ` Mark Brown
2015-08-03 15:53                                                         ` James Bottomley
2015-08-03 16:01                                                           ` Mark Brown
2015-08-02 12:12                                                     ` Jonathan Corbet
2015-08-02 22:46                                                       ` NeilBrown
2015-07-16 16:28                                     ` Greg KH
2015-07-16 17:36                                       ` Peter Hüwe
2015-07-31 13:17                                       ` Nicolas Ferre
2015-07-17 10:16                                     ` Mel Gorman
2015-07-17 12:21                                       ` Steven Rostedt
2015-07-16 16:24                                 ` James Bottomley
2015-07-16 17:15                                   ` Steven Rostedt
2015-07-16 18:36                                   ` Mark Brown
2015-07-17 16:11                                   ` Jonathan Corbet
2015-07-17 16:59                                     ` Josh Triplett
2015-07-17 17:06                                       ` Steven Rostedt
2015-07-17 18:59                                         ` josh
2015-07-17 17:37                                     ` Steven Rostedt
2015-07-17 17:43                                       ` James Bottomley
2015-07-17 17:53                                         ` Steven Rostedt
2015-07-17 19:30                                           ` Chris Mason
2015-07-17 19:46                                             ` Steven Rostedt
2015-07-17 20:02                                               ` Chris Mason
2015-07-20 17:40                                                 ` Tim Bird
2015-07-20 17:58                                                   ` Chris Mason
2015-07-20 18:26                                                     ` Mark Brown
2015-07-17 18:05                                         ` Guenter Roeck
2015-07-17 19:02                                       ` josh
2015-07-17 19:43                                         ` Steven Rostedt
2015-07-17 20:24                                           ` josh
2015-07-17 20:39                                             ` Steven Rostedt
2015-07-17 20:48                                               ` josh
2015-07-17 20:55                                                 ` Steven Rostedt
2015-07-19 22:19                                                   ` Jiri Kosina
2015-07-19 22:40                                                     ` Josh Triplett
2015-07-19 23:02                                                     ` Steven Rostedt
2015-07-20  2:34                                                     ` Zefan Li
2015-07-20  5:16                                                       ` Josh Triplett
2015-07-20  5:19                                                         ` Guenter Roeck
2015-07-20  7:15                                                         ` James Bottomley
2015-07-20  8:48                                                           ` Josh Triplett
2015-07-20  9:58                                                             ` James Bottomley
2015-07-20 10:15                                                               ` David Woodhouse
2015-07-20 22:35                                                               ` Rafael J. Wysocki
2015-07-21  0:25                                                           ` NeilBrown
2015-07-20  9:08                                                         ` Zefan Li
2015-07-20  7:08                                                     ` James Bottomley
2015-07-20  8:27                                                       ` Julia Lawall
2015-07-20 20:30                                                         ` Greg KH
2015-07-20 22:12                                                           ` Guenter Roeck
2015-07-20 22:32                                                             ` Greg KH
2015-07-20 23:03                                                               ` Guenter Roeck
2015-07-20 23:49                                                                 ` Bjorn Helgaas
2015-07-21  6:08                                                                 ` Julia Lawall
2015-07-21  6:15                                                                   ` Guenter Roeck
2015-07-21  5:57                                                             ` Julia Lawall
2015-07-20  8:44                                                       ` Josh Triplett
2015-07-20  9:23                                                         ` James Bottomley
2015-07-20 10:04                                                           ` David Woodhouse
2015-07-20 10:30                                                             ` James Bottomley
2015-07-20 11:09                                                               ` David Woodhouse
2015-07-21  2:00                                                                 ` Zefan Li
2015-07-21  6:00                                                                   ` Julia Lawall
2015-07-21  8:54                                                                   ` NeilBrown
2015-07-22 13:04                                                                     ` Steven Rostedt
2015-07-22 13:57                                                                       ` Bjorn Helgaas
2015-07-22 14:10                                                                         ` Steven Rostedt
2015-07-22 14:42                                                                           ` James Bottomley
2015-07-22 14:44                                                                             ` James Bottomley
2015-07-22 14:48                                                                             ` Steven Rostedt
2015-07-22 15:41                                                                               ` James Bottomley
2015-07-22 16:29                                                                       ` Josh Triplett
2015-07-21 17:35                                                                 ` Luis R. Rodriguez
2015-07-20 16:34                                                       ` Tim Bird
2015-07-18  6:17                                                 ` David Woodhouse
2015-07-19 22:21                                                   ` Jiri Kosina
2015-07-20  7:18                                                     ` James Bottomley
2015-07-20 11:05                                                       ` David Woodhouse
2015-07-20 12:35                                                   ` Takashi Iwai
2015-07-20 16:12                                       ` Tim Bird
2015-07-16 17:33                                 ` Peter Hüwe
2015-07-17 16:10                           ` Guenter Roeck
2015-07-17 16:23                             ` Steven Rostedt
2015-07-18 12:27                               ` Laurent Pinchart
2015-07-18 10:50                           ` Dan Carpenter
2015-07-18 12:19                             ` Steven Rostedt
2015-07-18 21:29                               ` Mark Brown
2015-07-18 22:59                                 ` Steven Rostedt
2015-07-11 11:11                     ` Julia Lawall
2015-07-10 15:44           ` Steven Rostedt
2015-07-10 16:00             ` Darren Hart
2015-07-10 16:34             ` Josh Triplett
2015-07-10 16:58               ` Darren Hart
2015-07-10 19:27               ` Steven Rostedt
2015-07-10 17:32             ` Christian Couder
2015-07-10 17:49               ` Darren Hart
2015-07-10 19:35                 ` Roberto Tyley
2015-07-10 22:49                   ` Darren Hart
2015-07-10 23:18                     ` Laura Abbott
2015-07-12 10:53                     ` Roberto Tyley
2015-07-11  9:31             ` [Ksummit-discuss] checkpatch.pl stuff Dan Carpenter
2015-07-11 11:34               ` Heiko Carstens
2015-07-11 12:51                 ` Steven Rostedt
2015-07-11 13:42                   ` Joe Perches [this message]
2015-07-08 14:20     ` [Ksummit-discuss] [CORE TOPIC] Recruitment (Reviewers, Testers, Maintainers, Hobbyists) Bjorn Helgaas
2015-07-08 14:34       ` Guenter Roeck
2015-07-08 15:20         ` Bjorn Helgaas
2015-07-08 19:19       ` Daniel Vetter
2015-07-08 19:48         ` Laurent Pinchart
2015-07-09  3:56         ` Michael Ellerman
2015-07-13 11:05           ` Damien Lespiau
2015-07-14  5:41             ` Michael Ellerman
2015-07-14 10:11               ` Damien Lespiau
2015-07-08 16:43   ` Mark Brown
2015-07-08 18:08     ` Jason Cooper
2015-07-08  0:16 ` Greg KH
2015-07-08 18:06   ` Mark Brown
2015-07-08 19:27     ` Laurent Pinchart
2015-07-08 19:35       ` Mark Brown
2015-07-08  1:29 ` Rafael J. Wysocki
2015-07-08  1:14   ` Josh Boyer
2015-07-08  1:49     ` NeilBrown
2015-07-08  3:40       ` Davidlohr Bueso
2015-07-08  7:08       ` Peter Hüwe
2015-07-08  2:03     ` Krzysztof Kozłowski
2015-07-08  7:04       ` Peter Hüwe
2015-07-08  7:52         ` jic23
2015-07-08  9:52           ` Peter Huewe
2015-07-08 12:42         ` Jonathan Corbet
2015-07-08 15:02         ` Jason Cooper
2015-07-08 16:36           ` Guenter Roeck
2015-07-08 18:05             ` Jason Cooper
2015-07-08 19:09           ` Peter Huewe
2015-07-08 19:21             ` Jason Cooper
2015-07-08 19:35               ` Peter Huewe
2015-07-08 15:43         ` John W. Linville
2015-07-12 19:37         ` Laurent Pinchart
2015-07-08  2:11     ` Greg KH
2015-07-08  7:52       ` Dan Carpenter
2015-07-08 11:07       ` Mark Brown
2015-07-08 11:43       ` Josh Boyer
2015-07-08 18:49         ` Steven Rostedt
2015-07-08 19:11           ` Josh Boyer
2015-07-08 19:38             ` Steven Rostedt
2015-07-08  8:18     ` Geert Uytterhoeven
2015-07-08  7:37   ` James Bottomley
2015-07-08  8:00     ` jic23
2015-07-08  9:57       ` Peter Huewe
2015-07-08 18:53       ` Steven Rostedt
2015-07-08 19:56         ` Laurent Pinchart
2015-07-08 20:07           ` Steven Rostedt
2015-07-08 21:31             ` Rafael J. Wysocki
2015-07-09 17:50               ` Frank Rowand
2015-07-08 20:08         ` Guenter Roeck
2015-07-09  4:06           ` Michael Ellerman
2015-07-09 18:28             ` Frank Rowand
2015-07-09 18:53               ` Mark Brown
2015-07-09 19:23               ` Guenter Roeck
2015-07-09 19:47                 ` Darren Hart
2015-07-09 20:13                   ` Theodore Ts'o
2015-07-09 20:50                     ` Guenter Roeck
2015-07-09 21:47                       ` Theodore Ts'o
2015-07-09 23:13                         ` josh
2015-07-09 23:56                           ` Theodore Ts'o
2015-07-10 20:49                           ` Steven Rostedt
2015-07-10 21:04                             ` josh
2015-07-26 23:13                             ` Paul E. McKenney
2015-07-10 18:20                         ` Guenter Roeck
2015-07-10 18:32                           ` Mark Brown
2015-07-10 18:58                           ` Jason Cooper
2015-07-10 20:24                             ` Guenter
2015-07-10 21:14                               ` Luis R. Rodriguez
2015-07-11  0:52                                 ` Guenter
2015-07-13 19:28                                   ` Luis R. Rodriguez
2015-07-11  1:04                               ` Jason Cooper
2015-07-10 21:00                             ` josh
2015-07-11  1:06                               ` Jason Cooper
2015-07-09 20:23                   ` Guenter Roeck
2015-07-09 20:48                     ` Darren Hart
2015-07-09 23:52                   ` Mark Brown
2015-07-09 19:44             ` Darren Hart
2015-07-10 21:01               ` Steven Rostedt
2015-07-09 19:39         ` Darren Hart
2015-07-09 20:21           ` Dmitry Torokhov
2015-07-09 21:41             ` Steven Rostedt
2015-07-10  0:14             ` Theodore Ts'o
2015-07-10  1:04               ` Rafael J. Wysocki
2015-07-10  1:54               ` Darren Hart
2015-07-10  3:13               ` Julia Lawall
2015-07-10 18:14         ` Josh Poimboeuf
2015-07-11  1:00           ` Davidlohr Bueso
2015-07-12  3:48             ` Josh Poimboeuf
2015-07-12  5:23               ` Josh Triplett
2015-07-12 12:28                 ` Josh Poimboeuf
2015-07-13 14:20                   ` Dan Carpenter
2015-07-13 14:33                     ` Jan Kara
2015-07-13 16:28                       ` Dan Carpenter
2015-07-13 17:58                         ` Jonathan Cameron
2015-07-14  4:38                         ` Sudip Mukherjee
2015-07-14  5:56                           ` Jonathan Cameron
2015-07-14  7:00                           ` Dan Carpenter
2015-07-14 15:16                           ` Greg KH
2015-07-14 15:52                             ` Josh Poimboeuf
2015-07-14 18:04                               ` Dan Carpenter
2015-07-14 18:01                             ` Dan Carpenter
2015-07-12 15:35               ` Steven Rostedt
2015-07-08 14:07 ` Jason Cooper
2015-07-08 19:29   ` Peter Huewe
2015-07-08 22:18     ` Jason Cooper
2015-07-08 23:09       ` Rafael J. Wysocki
2015-07-12 19:53         ` Laurent Pinchart
2015-07-09 15:09       ` John W. Linville
2015-07-09 17:45         ` Guenter Roeck
2015-07-09 18:08           ` John W. Linville
2015-07-10 13:07             ` Jason Cooper
2015-07-09 18:37         ` Olof Johansson
2015-07-09 19:02         ` Darren Hart
2015-07-10 13:03         ` Jason Cooper
2015-07-08 17:55 ` Mark Brown

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=1436622131.2711.55.camel@perches.com \
    --to=joe@perches.com \
    --cc=dan.carpenter@oracle.com \
    --cc=jason@lakedaemon.net \
    --cc=ksummit-discuss@lists.linuxfoundation.org \
    --cc=rostedt@goodmis.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.