diff mbox

[4/4] sc16is7xx: enable the clock

Message ID 1426548529-21738-5-git-send-email-moorray3@wp.pl
State Not Applicable
Headers show

Commit Message

Jakub KiciƄski March 16, 2015, 11:28 p.m. UTC
From: Jakub Kicinski <kubakici@wp.pl>

Although clk_disable_unprepare() is called both on .remove()
and in .probe() error path, the clock is never actually enabled.

Signed-off-by: Jakub Kicinski <kubakici@wp.pl>
---
 drivers/tty/serial/sc16is7xx.c | 1 +
 1 file changed, 1 insertion(+)

Comments

Jon Ringle March 17, 2015, 2:46 p.m. UTC | #1
On Mon, 16 Mar 2015, Jakub Kicinski wrote:

> From: Jakub Kicinski <kubakici@wp.pl>
> 
> Although clk_disable_unprepare() is called both on .remove()
> and in .probe() error path, the clock is never actually enabled.
> 
> Signed-off-by: Jakub Kicinski <kubakici@wp.pl>

Signed-off-by: Jon Ringle <jringle@gridpoint.com>

> ---
>  drivers/tty/serial/sc16is7xx.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/tty/serial/sc16is7xx.c b/drivers/tty/serial/sc16is7xx.c
> index 24902d589b07..20573d72715d 100644
> --- a/drivers/tty/serial/sc16is7xx.c
> +++ b/drivers/tty/serial/sc16is7xx.c
> @@ -1064,6 +1064,7 @@ static int sc16is7xx_probe(struct device *dev,
>  		else
>  			return PTR_ERR(s->clk);
>  	} else {
> +		clk_prepare_enable(s->clk);
>  		freq = clk_get_rate(s->clk);
>  	}
>  
> -- 
> 2.1.0
> 
> 
--
To unsubscribe from this list: send the line "unsubscribe linux-i2c" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/drivers/tty/serial/sc16is7xx.c b/drivers/tty/serial/sc16is7xx.c
index 24902d589b07..20573d72715d 100644
--- a/drivers/tty/serial/sc16is7xx.c
+++ b/drivers/tty/serial/sc16is7xx.c
@@ -1064,6 +1064,7 @@  static int sc16is7xx_probe(struct device *dev,
 		else
 			return PTR_ERR(s->clk);
 	} else {
+		clk_prepare_enable(s->clk);
 		freq = clk_get_rate(s->clk);
 	}