linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Arend van Spriel" <arend@broadcom.com>
To: "Dan Carpenter" <dan.carpenter@oracle.com>
Cc: linux-wireless@vger.kernel.org, "Julia Lawall" <julia@diku.dk>
Subject: Re: net: wireless: add brcm80211 drivers
Date: Mon, 14 May 2012 11:06:09 +0200	[thread overview]
Message-ID: <4FB0CB01.3000507@broadcom.com> (raw)
In-Reply-To: <20120514083415.GA16999@mwanda>

On 05/14/2012 10:34 AM, Dan Carpenter wrote:
> On Mon, May 14, 2012 at 09:07:55AM +0200, Arend van Spriel wrote:
>> Thanks for running smatch. I will look in the current code base and fix
>> this. Just out of curiosity: Another static checker used regularly is
>> Coccinelle. What are the pros and cons of smatch compared to Coccinelle?
>>
>> Gr. AvS
> 
> That's a tricky question because of my obvious bias as the author
> of Smatch, and I'm not an expert on Coccinelle.  ;)

 ;-)

> Smatch works on the preprocessed code and Coccinelle works on .c
> code.  So some things are easier to check for in Coccinelle.  I've
> generally found hacks to get the information I need in Smatch but
> sometimes it's gnarly.  So a one liner in Coccinelle is twenty lines
> of code in Smatch which require in depth knowledge of Smatch and
> Sparse.
> 
> Smatch doesn't fix the bugs it finds.

+1 for Coccinelle.

> The other advantage for Coccinelle is that you can run it on other
> architecture's code without setting up a cross compile environment.
> 
> What Smatch does that Coccinelle doesn't is that it tries to track
> the values of all the variables.  This means you can detect array
> overflows, for example.  Smatch tries to track values across
> function calls as well, with the recent database work.

I guess Oracle knows a thing or two about databases.

> That's really the long term goal of Smatch, to track the value of
> every variable in the kernel.  But there is still a lot of work to
> do.  :P

Enjoy and thanks for taking time to explain.

Gr. AvS


  reply	other threads:[~2012-05-14  9:06 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-05-13 17:43 net: wireless: add brcm80211 drivers Dan Carpenter
2012-05-14  7:07 ` Arend van Spriel
2012-05-14  8:34   ` Dan Carpenter
2012-05-14  9:06     ` Arend van Spriel [this message]
2012-05-14  9:28       ` Dan Carpenter
2012-05-14 11:45     ` Julia Lawall
  -- strict thread matches above, loose matches on Subject: below --
2012-08-05 19:57 Dan Carpenter
2012-08-06  8:50 ` Arend van Spriel
2016-06-27 13:22 Dan Carpenter
2016-06-27 19:12 ` Dan Carpenter

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=4FB0CB01.3000507@broadcom.com \
    --to=arend@broadcom.com \
    --cc=dan.carpenter@oracle.com \
    --cc=julia@diku.dk \
    --cc=linux-wireless@vger.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).