[PATCH] CLKDEV: return from clk_find as soon as we get maching clk

Russell King - ARM Linux linux at arm.linux.org.uk
Wed Mar 3 14:44:22 EST 2010


On Tue, Mar 02, 2010 at 10:01:38PM +0100, Uwe Kleine-König wrote:
> I starred a the code a bit, but I don't see the problem here.  match is
> always <= 3 so if it is 3 in one iteration best increases to 3 and clk
> isn't touched anymore.  The other statements in the loop have no side
> effects either.

Yes, you're right - I thought there was some additional code at the end
of the function - was thinking of a previous revision of the code.

I'd still prefer the conditional code to be a 'clk = p->clk; break;'
though, to keep the flow of the code the same.



More information about the linux-arm-kernel mailing list