[PATCH 2/2] ARM: imx: set CKO1 parent clock source in imx6q sabresd

Shawn Guo shawn.guo at linaro.org
Mon Feb 4 00:12:51 EST 2013


On Mon, Feb 04, 2013 at 03:13:40AM +0000, Zhang Quan-B13634 wrote:
> >  > -static void __init imx6q_sabrelite_cko1_setup(void)
> >  > +static void __init cko1_setup(unsigned long freq)
> >  >  {
> >  >  	struct clk *cko1_sel, *ahb, *cko1;
> >  >  	unsigned long rate;
> >  > @@ -132,8 +132,10 @@ static void __init imx6q_sabrelite_cko1_setup(void)
> >  >  		goto put_clk;
> >  >  	}
> >  >  	clk_set_parent(cko1_sel, ahb);
> >  > -	rate = clk_round_rate(cko1, 16000000);
> >  > +	rate = clk_round_rate(cko1, freq);
> >  >  	clk_set_rate(cko1, rate);
> >  > +
> >  > +	return;
> >  
> >  Why does this "return" needs to be added here?
> [Gary-b13634] because the codes below may be ignored when execute 'return' ,
> Saving cpu consumption.

But we haven't finished our job.  We need to "put" those clocks before
returning to balance the "get" call.

Shawn




More information about the linux-arm-kernel mailing list