linux-i2c.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Wolfram Sang <wsa@the-dreams.de>
To: Peter Rosin <peda@axentia.se>
Cc: linux-i2c@vger.kernel.org
Subject: Re: [PATCH v6 0/3] i2c: mux: pca954x: Add interrupt controller support
Date: Sat, 11 Feb 2017 03:40:48 +0100	[thread overview]
Message-ID: <20170211024048.GA1441@katana> (raw)
In-Reply-To: <3632e933-6bc9-4d40-f489-1af958f0fd4b@axentia.se>

[-- Attachment #1: Type: text/plain, Size: 1671 bytes --]


> No trouble at all, and I'll certainly have a look at the script, so
> please send it my way. Thanks!

Some notes first:: sparse and smatch are probably the most useful for
kernel builds. spatch (=coccinelle) is nice, too, but needs quite a bit
more time for checking. cppcheck occasionally finds something that the
others don't, flawfinder not really. There are some false positives,
too, so you need to get a bit used to read the output. So, here you go:

=== ninja-check
#!/bin/sh -u
# wrapper to call various static checkers for kernel builds.
# Use: make C=1 CHECK='ninja-check' ...
# done by Wolfram Sang in 2012-14, version 20140514 - WTFPLv2

check_for()
{
	command -v $1 > /dev/null
	ret=$?
	[ $ret -eq 0 ] && echo "    $1" | tr a-z A-Z
	return $ret
}

# Get filename (last argument)
eval file_to_check=\${$#}

check_for sparse && sparse -Wsparse-all "$@"

check_for smatch && smatch --two-passes --project=kernel "$@" 1>&2

# Don't provide include-dirs since number of code paths increases drastically (#defines!) and '-f' checks all of them. Just suppress the warning.
check_for cppcheck && cppcheck -f -q --platform=unix64 --template=gcc --enable=all --language=c --suppress=missingInclude --suppress=clarifyCalculation --suppress=unmatchedSuppression --suppress=variableScope "$file_to_check"

check_for spatch && MODE=report scripts/coccicheck "$file_to_check" 1>&2

check_for flawfinder && flawfinder --minlevel=0 --quiet --dataonly --singleline "$file_to_check" 1>&2

# RATS mainly checks for dangerous functions. Not so useful for kernel analysis. flawfinder does string checking, too.
#check_for rats && rats --resultsonly -w 3 "$file_to_check" 1>&2


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

      reply	other threads:[~2017-02-11  2:47 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-25  1:31 [PATCH v6 0/3] i2c: mux: pca954x: Add interrupt controller support Phil Reid
     [not found] ` <1485307868-5408-1-git-send-email-preid-qgqNFa1JUf/o2iN0hyhwsIdd74u8MsAO@public.gmane.org>
2017-01-25  1:31   ` [PATCH v6 1/3] i2c: mux: pca954x: Add missing pca9542 definition to chip_desc Phil Reid
2017-01-25  1:31 ` [PATCH v6 2/3] dt: bindings: i2c-mux-pca954x: Add documentation for interrupt controller Phil Reid
2017-01-25  1:31 ` [PATCH v6 3/3] i2c: mux: pca954x: Add interrupt controller support Phil Reid
     [not found]   ` <1485307868-5408-4-git-send-email-preid-qgqNFa1JUf/o2iN0hyhwsIdd74u8MsAO@public.gmane.org>
2017-02-09 16:21     ` Peter Rosin
2017-02-10  8:02 ` [PATCH v6 0/3] " Peter Rosin
2017-02-10 12:52   ` Wolfram Sang
2017-02-10 21:46     ` Peter Rosin
2017-02-11  2:40       ` Wolfram Sang [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=20170211024048.GA1441@katana \
    --to=wsa@the-dreams.de \
    --cc=linux-i2c@vger.kernel.org \
    --cc=peda@axentia.se \
    /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).