linux-kselftest.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Brendan Higgins <brendanhiggins@google.com>
To: Joe Perches <joe@perches.com>
Cc: shuah <shuah@kernel.org>,
	Dan Carpenter <dan.carpenter@oracle.com>,
	David Gow <davidgow@google.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	Kees Cook <keescook@chromium.org>,
	"open list:KERNEL SELFTEST FRAMEWORK" 
	<linux-kselftest@vger.kernel.org>,
	KUnit Development <kunit-dev@googlegroups.com>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH linux-kselftest/test v6] lib/list-test: add a test for the 'list' doubly linked list
Date: Thu, 31 Oct 2019 01:51:29 -0700	[thread overview]
Message-ID: <20191031085129.GA217570@google.com> (raw)
In-Reply-To: <fad58e4f48237894de0d511adf1d663a42a2eee7.camel@perches.com>

On Wed, Oct 30, 2019 at 10:18:44AM -0700, Joe Perches wrote:
> On Wed, 2019-10-30 at 09:35 -0700, Brendan Higgins wrote:
> > Agreed. I can see the point of not wanting to write an exception into
> > checkpatch for every exception of it's general rules; however, it
> > would be nice if there was a way to maybe have a special comment or
> > something that could turn off a checkpatch error. That way, a
> > checkpatch error/warning always means some action should be taken, and
> > if a rule is being ignored, there is always documentation as to why.
> 
> That couldn't work when a comment which may exist
> in a file is out of scope of the patch context.

Sorry, I don't understand exactly what you mean. Can you elaborate?

If it wasn't obvious, I am not proposing that David should make the
changed I described now for this patch. I know what I proposed would not
be an easy thing to implement, especially given the opinions that it is
likely to solicit.

Nevertheless, in the long term, I have seen other projects allow a
comment that would cause style checkers or static analysis tools to
ignore the designated line. Maybe we could implement this as a line
comment that suppresses a checkpatch warning of a certain kind on the
line. So here, we might have something like:

static void list_test_list_for_each_prev(struct kunit *test) /* checkpatch: disable=for-each-format */

We would also probably want to require an explanation either in the
checkpatch comment or the line above, but then you have to worry about
that comment not being included in a patch that only updates the
offending line.

Anyway, it's just an idea. I know that we don't currently assume that
all checkpatch errors/warnings require some action, but it might be cool
if they did.

Cheers

  reply	other threads:[~2019-10-31  8:51 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-10-24 22:46 [PATCH linux-kselftest/test v6] lib/list-test: add a test for the 'list' doubly linked list David Gow
2019-10-29 13:00 ` shuah
2019-10-30  8:02   ` David Gow
2019-10-30 10:42     ` Dan Carpenter
2019-10-30 16:27       ` shuah
2019-10-30 16:35         ` Brendan Higgins
2019-10-30 17:18           ` Joe Perches
2019-10-31  8:51             ` Brendan Higgins [this message]
2019-10-31 10:07               ` Joe Perches
2019-10-31 10:20               ` Dan Carpenter
2019-10-30 18:46         ` Dan Carpenter
2019-10-30 19:15           ` Joe Perches
2019-10-31  6:59             ` Dan Carpenter
2019-11-01 10:50             ` Rasmus Villemoes
2019-10-30 19:12         ` Dan Carpenter
2019-10-30 19:23           ` Joe Perches
2019-10-31  7:12             ` David Gow
2019-10-31  7:42               ` Dan Carpenter
2019-11-01 16:49             ` shuah
2019-10-30 16:31       ` Joe Perches
2019-10-31 18:50 ` Kees Cook
2019-11-01 10:25   ` David Gow

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=20191031085129.GA217570@google.com \
    --to=brendanhiggins@google.com \
    --cc=akpm@linux-foundation.org \
    --cc=dan.carpenter@oracle.com \
    --cc=davidgow@google.com \
    --cc=joe@perches.com \
    --cc=keescook@chromium.org \
    --cc=kunit-dev@googlegroups.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-kselftest@vger.kernel.org \
    --cc=shuah@kernel.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 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).