All of lore.kernel.org
 help / color / mirror / Atom feed
From: Duan Jiong <duanj.fnst@cn.fujitsu.com>
To: dwmw2@infradead.org
Cc: linux-kernel@vger.kernel.org
Subject: [PATCH] mtd: bcm47xxsflash: the argument to kfree should not be the address of a structure field
Date: Thu, 05 Sep 2013 15:02:30 +0800	[thread overview]
Message-ID: <52282C86.9050306@cn.fujitsu.com> (raw)

From: Duan Jiong <duanj.fnst@cn.fujitsu.com>

Signed-off-by: Duan Jiong <duanj.fnst@cn.fujitsu.com>
---
 drivers/mtd/devices/bcm47xxsflash.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mtd/devices/bcm47xxsflash.c b/drivers/mtd/devices/bcm47xxsflash.c
index 18e7761..9b8aaf3 100644
--- a/drivers/mtd/devices/bcm47xxsflash.c
+++ b/drivers/mtd/devices/bcm47xxsflash.c
@@ -87,7 +87,7 @@ static int bcm47xxsflash_bcma_probe(struct platform_device *pdev)
 	return 0;
 
 err_dev_reg:
-	kfree(&b47s->mtd);
+	kfree(b47s);
 out:
 	return err;
 }
-- 
1.8.3.1

             reply	other threads:[~2013-09-05  7:03 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-09-05  7:02 Duan Jiong [this message]
2013-09-05  8:36 ` [PATCH] mtd: bcm47xxsflash: the argument to kfree should not be the address of a structure field David Woodhouse

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=52282C86.9050306@cn.fujitsu.com \
    --to=duanj.fnst@cn.fujitsu.com \
    --cc=dwmw2@infradead.org \
    --cc=linux-kernel@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.