linux-i2c.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Dan Carpenter <dan.carpenter@oracle.com>
To: Wolfram Sang <wsa@the-dreams.de>
Cc: linux-i2c@vger.kernel.org, linux-kernel@vger.kernel.org,
	Erico Nunes <erico.nunes@datacom.ind.br>,
	kernel-janitors@vger.kernel.org, LKP <lkp@01.org>
Subject: Re: [PATCH] Revert "i2c: dev: switch from register_chrdev to cdev API"
Date: Mon, 30 May 2016 10:05:47 +0300	[thread overview]
Message-ID: <20160530070547.GA18199@mwanda> (raw)
In-Reply-To: <20160528160458.GA1614@katana>

On Sat, May 28, 2016 at 06:04:58PM +0200, Wolfram Sang wrote:
> 
> > These kinds of use after frees don't always cause a runtime problem.  I
> > found it using static analysis, but I bet you could detect it if you
> > enabled kasan.  The other option is to enable PAGE_POISONING?
> 
> Thanks, PAGE_POISONING did trigger the issue. So, I now picked up your
> patch instead of the revert because I could verify the problem and the
> proper solution. Thanks again.
> 
> What I still wonder: Which analysis reported the problem to you? I
> always run sparse, smatch, cppcheck, and coccicheck on the patches when
> applying and no-one reported the issue.

It's a Smatch warning but you have to build the cross function db to
detect this.  It takes a while (a few hours) but the command is simple
enough.

	./smatch_scripts/build_kernel_data.sh

regards,
dan carpenter

      reply	other threads:[~2016-05-30  7:06 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-05-28  9:07 [PATCH] Revert "i2c: dev: switch from register_chrdev to cdev API" Wolfram Sang
2016-05-28  9:15 ` Dan Carpenter
2016-05-28 16:04   ` Wolfram Sang
2016-05-30  7:05     ` Dan Carpenter [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=20160530070547.GA18199@mwanda \
    --to=dan.carpenter@oracle.com \
    --cc=erico.nunes@datacom.ind.br \
    --cc=kernel-janitors@vger.kernel.org \
    --cc=linux-i2c@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lkp@01.org \
    --cc=wsa@the-dreams.de \
    /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).