Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Message from discussion devm_kfree

Received: by 10.68.213.99 with SMTP id nr3mr17510844pbc.2.1324916402535;
        Mon, 26 Dec 2011 08:20:02 -0800 (PST)
Path: lh20ni66885pbb.0!nntp.google.com!news2.google.com!goblin3!goblin.stu.neva.ru!gin-ad1-unet1.teleglobe.net!news.asdasd.it!bofh.it!news.nic.it!robomod
From: Mark Brown <broo...@opensource.wolfsonmicro.com>
Newsgroups: linux.kernel
Subject: Re: devm_kfree
Date: Mon, 26 Dec 2011 17:20:01 +0100
Message-ID: <iclrj-4CQ-9@gated-at.bofh.it>
References: <ibhpM-3v4-3@gated-at.bofh.it> <ichxn-6t4-1@gated-at.bofh.it> <icj6b-tT-11@gated-at.bofh.it> <icjIR-1Gt-15@gated-at.bofh.it> <iclrj-4CQ-1@gated-at.bofh.it>
X-Original-To: Julia Lawall <julia.law...@lip6.fr>
MIME-Version: 1.0
X-Cookie: You are fairminded, just and loving.
User-Agent: Mutt/1.5.21 (2010-09-15)
Sender: robo...@news.nic.it
List-ID: <linux-kernel.vger.kernel.org>
X-Mailing-List: linux-kernel@vger.kernel.org
Approved: robo...@news.nic.it
Lines: 12
Organization: linux.* mail to news gateway
X-Original-Cc: Samuel Ortiz <sa...@linux.intel.com>,
	kernel-janit...@vger.kernel.org, linux-ker...@vger.kernel.org
X-Original-Date: Mon, 26 Dec 2011 16:19:14 +0000
X-Original-Message-ID: <20111226161913.GJ8722@opensource.wolfsonmicro.com>
X-Original-References: <1324661974-17281-1-git-send-email-ju...@diku.dk>
 <20111226120855.GB17...@sirena.org.uk>
 <alpine.DEB.2.02.1112261440450.1...@localhost6.localdomain6>
 <20111226142354.GI8...@opensource.wolfsonmicro.com>
 <alpine.DEB.2.02.1112261716310.1...@localhost6.localdomain6>
X-Original-Sender: linux-kernel-ow...@vger.kernel.org
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline

On Mon, Dec 26, 2011 at 05:17:26PM +0100, Julia Lawall wrote:
> And I guess that eg using kfree to free something allocated using
> devm_kzalloc would be completely wrong, leading to a dangling
> pointer?

I'd expect that matching kfree() with devm_kzalloc() would lead to an
attempt to double free whenever the devm_ mechanism kicks in.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/