mtd: s3c2410 nand: Remove uncessary null check

Linux-MTD Mailing List linux-mtd at lists.infradead.org
Mon Nov 7 11:59:29 EST 2011


Gitweb:     http://git.infradead.org/?p=mtd-2.6.git;a=commit;h=4aa10626adbc27dcf2e3462bb82b4963c5545669
Commit:     4aa10626adbc27dcf2e3462bb82b4963c5545669
Parent:     92394b5c2be774425f255b5c7afbd8b19978fe12
Author:     Jonghwan Choi <jhbird.choi at samsung.com>
AuthorDate: Thu Jul 21 15:33:58 2011 +0900
Committer:  Artem Bityutskiy <artem.bityutskiy at intel.com>
CommitDate: Sun Sep 11 15:02:17 2011 +0300

    mtd: s3c2410 nand: Remove uncessary null check
    
    clk_get() return a pointer to the struct clk or an ERR_PTR().
    
    Signed-off-by: Jonghwan Choi <jhbird.choi at samsung.com>
    Signed-off-by: Artem Bityutskiy <artem.bityutskiy at intel.com>
---
 drivers/mtd/nand/s3c2410.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/mtd/nand/s3c2410.c b/drivers/mtd/nand/s3c2410.c
index b0f8e77..868685d 100644
--- a/drivers/mtd/nand/s3c2410.c
+++ b/drivers/mtd/nand/s3c2410.c
@@ -723,7 +723,7 @@ static int s3c24xx_nand_remove(struct platform_device *pdev)
 
 	/* free the common resources */
 
-	if (info->clk != NULL && !IS_ERR(info->clk)) {
+	if (!IS_ERR(info->clk)) {
 		s3c2410_nand_clk_set_state(info, CLOCK_DISABLE);
 		clk_put(info->clk);
 	}



More information about the linux-mtd-cvs mailing list