diff mbox

mtd: nand: denali_dt: replace clk_disable() with clk_disable_unprepare()

Message ID 1478107264-21139-1-git-send-email-yamada.masahiro@socionext.com
State Accepted
Commit a1a261707b51d728d0c2b4c32630bc43a8eb33b2
Headers show

Commit Message

Masahiro Yamada Nov. 2, 2016, 5:21 p.m. UTC
The denali_dt_probe() calls clk_disable_unprepare() in the bailout
path, whereas denali_dt_remove calls clk_disable(), inconsistently.
Replace the latter with clk_disable_unprepare() to make sure to
unprepare the clock.

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>

---

 drivers/mtd/nand/denali_dt.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

-- 
1.9.1


______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/

Comments

Marek Vasut Nov. 5, 2016, 7:26 a.m. UTC | #1
On 11/02/2016 06:21 PM, Masahiro Yamada wrote:
> The denali_dt_probe() calls clk_disable_unprepare() in the bailout

> path, whereas denali_dt_remove calls clk_disable(), inconsistently.

> Replace the latter with clk_disable_unprepare() to make sure to

> unprepare the clock.

> 

> Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>


Reviewed-by: Marek Vasut <marek.vasut@gmail.com>


> ---

> 

>  drivers/mtd/nand/denali_dt.c | 2 +-

>  1 file changed, 1 insertion(+), 1 deletion(-)

> 

> diff --git a/drivers/mtd/nand/denali_dt.c b/drivers/mtd/nand/denali_dt.c

> index 0cb1e8d..f821dc1 100644

> --- a/drivers/mtd/nand/denali_dt.c

> +++ b/drivers/mtd/nand/denali_dt.c

> @@ -110,7 +110,7 @@ static int denali_dt_remove(struct platform_device *ofdev)

>  	struct denali_dt *dt = platform_get_drvdata(ofdev);

>  

>  	denali_remove(&dt->denali);

> -	clk_disable(dt->clk);

> +	clk_disable_unprepare(dt->clk);

>  

>  	return 0;

>  }

> 



-- 
Best regards,
Marek Vasut

______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/
diff mbox

Patch

diff --git a/drivers/mtd/nand/denali_dt.c b/drivers/mtd/nand/denali_dt.c
index 0cb1e8d..f821dc1 100644
--- a/drivers/mtd/nand/denali_dt.c
+++ b/drivers/mtd/nand/denali_dt.c
@@ -110,7 +110,7 @@  static int denali_dt_remove(struct platform_device *ofdev)
 	struct denali_dt *dt = platform_get_drvdata(ofdev);
 
 	denali_remove(&dt->denali);
-	clk_disable(dt->clk);
+	clk_disable_unprepare(dt->clk);
 
 	return 0;
 }