aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/mtd/nand
diff options
context:
space:
mode:
authorJesper Juhl <jesper.juhl@gmail.com>2005-11-07 04:01:27 -0500
committerLinus Torvalds <torvalds@g5.osdl.org>2005-11-07 10:54:02 -0500
commitfa671646f61182cd18234461a6e65f50c6558695 (patch)
tree79d5fe8cbfdf9670456538837e60c695e6875006 /drivers/mtd/nand
parentc9475cb0c358ff0dd473544280d92482df491913 (diff)
[PATCH] kfree cleanup: drivers/mtd
This is the drivers/mtd part of the big kfree cleanup patch. Remove pointless checks for NULL prior to calling kfree() in drivers/mtd/. Signed-off-by: Jesper Juhl <jesper.juhl@gmail.com> Cc: David Woodhouse <dwmw2@infradead.org> Acked-by: Joern Engel <joern@wohnheim.fh-wedel.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers/mtd/nand')
-rw-r--r--drivers/mtd/nand/nand_base.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/mtd/nand/nand_base.c b/drivers/mtd/nand/nand_base.c
index 04e54318bc6..8e78d7b96a5 100644
--- a/drivers/mtd/nand/nand_base.c
+++ b/drivers/mtd/nand/nand_base.c
@@ -2676,9 +2676,8 @@ void nand_release (struct mtd_info *mtd)
2676 /* Deregister the device */ 2676 /* Deregister the device */
2677 del_mtd_device (mtd); 2677 del_mtd_device (mtd);
2678 2678
2679 /* Free bad block table memory, if allocated */ 2679 /* Free bad block table memory */
2680 if (this->bbt) 2680 kfree (this->bbt);
2681 kfree (this->bbt);
2682 /* Buffer allocated by nand_scan ? */ 2681 /* Buffer allocated by nand_scan ? */
2683 if (this->options & NAND_OOBBUF_ALLOC) 2682 if (this->options & NAND_OOBBUF_ALLOC)
2684 kfree (this->oob_buf); 2683 kfree (this->oob_buf);