diff mbox

[11/12] fbdev: shmobile-hdmi: Convert to clk_prepare/unprepare

Message ID 1383000569-8916-12-git-send-email-laurent.pinchart+renesas@ideasonboard.com (mailing list archive)
State New, archived
Headers show

Commit Message

Laurent Pinchart Oct. 28, 2013, 10:49 p.m. UTC
Turn clk_enable() and clk_disable() calls into clk_prepare_enable() and
clk_disable_unprepare() to get ready for the migration to the common
clock framework.

Cc: Jean-Christophe Plagniol-Villard <plagnioj@jcrosoft.com>
Cc: Tomi Valkeinen <tomi.valkeinen@ti.com>
Cc: linux-fbdev@vger.kernel.org
Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
---
 drivers/video/sh_mobile_hdmi.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

Comments

Jean-Christophe PLAGNIOL-VILLARD Oct. 31, 2013, 10:48 a.m. UTC | #1
On 23:49 Mon 28 Oct     , Laurent Pinchart wrote:
> Turn clk_enable() and clk_disable() calls into clk_prepare_enable() and
> clk_disable_unprepare() to get ready for the migration to the common
> clock framework.
> 
> Cc: Jean-Christophe Plagniol-Villard <plagnioj@jcrosoft.com>
> Cc: Tomi Valkeinen <tomi.valkeinen@ti.com>
Acked-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>

Bset Regards,
J.
> Cc: linux-fbdev@vger.kernel.org
> Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
> ---
>  drivers/video/sh_mobile_hdmi.c | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/video/sh_mobile_hdmi.c b/drivers/video/sh_mobile_hdmi.c
> index bfe4728..190145e 100644
> --- a/drivers/video/sh_mobile_hdmi.c
> +++ b/drivers/video/sh_mobile_hdmi.c
> @@ -1326,7 +1326,7 @@ static int __init sh_hdmi_probe(struct platform_device *pdev)
>  		goto erate;
>  	}
>  
> -	ret = clk_enable(hdmi->hdmi_clk);
> +	ret = clk_prepare_enable(hdmi->hdmi_clk);
>  	if (ret < 0) {
>  		dev_err(hdmi->dev, "Cannot enable clock: %d\n", ret);
>  		goto erate;
> @@ -1404,7 +1404,7 @@ emap_htop1:
>  emap:
>  	release_mem_region(res->start, resource_size(res));
>  ereqreg:
> -	clk_disable(hdmi->hdmi_clk);
> +	clk_disable_unprepare(hdmi->hdmi_clk);
>  erate:
>  	clk_put(hdmi->hdmi_clk);
>  egetclk:
> @@ -1427,7 +1427,7 @@ static int __exit sh_hdmi_remove(struct platform_device *pdev)
>  	cancel_delayed_work_sync(&hdmi->edid_work);
>  	pm_runtime_put(&pdev->dev);
>  	pm_runtime_disable(&pdev->dev);
> -	clk_disable(hdmi->hdmi_clk);
> +	clk_disable_unprepare(hdmi->hdmi_clk);
>  	clk_put(hdmi->hdmi_clk);
>  	if (hdmi->htop1)
>  		iounmap(hdmi->htop1);
> -- 
> 1.8.1.5
> 
--
To unsubscribe from this list: send the line "unsubscribe linux-fbdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Laurent Pinchart Nov. 9, 2013, 2:13 p.m. UTC | #2
Hi Jean-Christophe,

On Thursday 31 October 2013 11:48:09 Jean-Christophe PLAGNIOL-VILLARD wrote:
> On 23:49 Mon 28 Oct     , Laurent Pinchart wrote:
> > Turn clk_enable() and clk_disable() calls into clk_prepare_enable() and
> > clk_disable_unprepare() to get ready for the migration to the common
> > clock framework.
> > 
> > Cc: Jean-Christophe Plagniol-Villard <plagnioj@jcrosoft.com>
> > Cc: Tomi Valkeinen <tomi.valkeinen@ti.com>
> 
> Acked-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>

Thank you. Could you please pick patches 11/12 and 12/12 up for v3.13 or v3.14 
?

> > Cc: linux-fbdev@vger.kernel.org
> > Signed-off-by: Laurent Pinchart
> > <laurent.pinchart+renesas@ideasonboard.com>
> > ---
> > 
> >  drivers/video/sh_mobile_hdmi.c | 6 +++---
> >  1 file changed, 3 insertions(+), 3 deletions(-)
> > 
> > diff --git a/drivers/video/sh_mobile_hdmi.c
> > b/drivers/video/sh_mobile_hdmi.c index bfe4728..190145e 100644
> > --- a/drivers/video/sh_mobile_hdmi.c
> > +++ b/drivers/video/sh_mobile_hdmi.c
> > @@ -1326,7 +1326,7 @@ static int __init sh_hdmi_probe(struct
> > platform_device *pdev)> 
> >  		goto erate;
> >  	
> >  	}
> > 
> > -	ret = clk_enable(hdmi->hdmi_clk);
> > +	ret = clk_prepare_enable(hdmi->hdmi_clk);
> > 
> >  	if (ret < 0) {
> >  	
> >  		dev_err(hdmi->dev, "Cannot enable clock: %d\n", ret);
> >  		goto erate;
> > 
> > @@ -1404,7 +1404,7 @@ emap_htop1:
> >  emap:
> >  	release_mem_region(res->start, resource_size(res));
> >  
> >  ereqreg:
> > -	clk_disable(hdmi->hdmi_clk);
> > +	clk_disable_unprepare(hdmi->hdmi_clk);
> > 
> >  erate:
> >  	clk_put(hdmi->hdmi_clk);
> >  
> >  egetclk:
> > @@ -1427,7 +1427,7 @@ static int __exit sh_hdmi_remove(struct
> > platform_device *pdev)> 
> >  	cancel_delayed_work_sync(&hdmi->edid_work);
> >  	pm_runtime_put(&pdev->dev);
> >  	pm_runtime_disable(&pdev->dev);
> > 
> > -	clk_disable(hdmi->hdmi_clk);
> > +	clk_disable_unprepare(hdmi->hdmi_clk);
> > 
> >  	clk_put(hdmi->hdmi_clk);
> >  	if (hdmi->htop1)
> >  	
> >  		iounmap(hdmi->htop1);
Tomi Valkeinen Nov. 11, 2013, 1:34 p.m. UTC | #3
On 2013-11-09 16:13, Laurent Pinchart wrote:
> Hi Jean-Christophe,
> 
> On Thursday 31 October 2013 11:48:09 Jean-Christophe PLAGNIOL-VILLARD wrote:
>> On 23:49 Mon 28 Oct     , Laurent Pinchart wrote:
>>> Turn clk_enable() and clk_disable() calls into clk_prepare_enable() and
>>> clk_disable_unprepare() to get ready for the migration to the common
>>> clock framework.
>>>
>>> Cc: Jean-Christophe Plagniol-Villard <plagnioj@jcrosoft.com>
>>> Cc: Tomi Valkeinen <tomi.valkeinen@ti.com>
>>
>> Acked-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
> 
> Thank you. Could you please pick patches 11/12 and 12/12 up for v3.13 or v3.14 
> ?

Thanks, picked both for 3.13.

 Tomi
diff mbox

Patch

diff --git a/drivers/video/sh_mobile_hdmi.c b/drivers/video/sh_mobile_hdmi.c
index bfe4728..190145e 100644
--- a/drivers/video/sh_mobile_hdmi.c
+++ b/drivers/video/sh_mobile_hdmi.c
@@ -1326,7 +1326,7 @@  static int __init sh_hdmi_probe(struct platform_device *pdev)
 		goto erate;
 	}
 
-	ret = clk_enable(hdmi->hdmi_clk);
+	ret = clk_prepare_enable(hdmi->hdmi_clk);
 	if (ret < 0) {
 		dev_err(hdmi->dev, "Cannot enable clock: %d\n", ret);
 		goto erate;
@@ -1404,7 +1404,7 @@  emap_htop1:
 emap:
 	release_mem_region(res->start, resource_size(res));
 ereqreg:
-	clk_disable(hdmi->hdmi_clk);
+	clk_disable_unprepare(hdmi->hdmi_clk);
 erate:
 	clk_put(hdmi->hdmi_clk);
 egetclk:
@@ -1427,7 +1427,7 @@  static int __exit sh_hdmi_remove(struct platform_device *pdev)
 	cancel_delayed_work_sync(&hdmi->edid_work);
 	pm_runtime_put(&pdev->dev);
 	pm_runtime_disable(&pdev->dev);
-	clk_disable(hdmi->hdmi_clk);
+	clk_disable_unprepare(hdmi->hdmi_clk);
 	clk_put(hdmi->hdmi_clk);
 	if (hdmi->htop1)
 		iounmap(hdmi->htop1);