sh: reinstate clock framework rate rounding.
authorPaul Mundt <lethal@linux-sh.org>
Fri, 20 Aug 2010 10:10:38 +0000 (19:10 +0900)
committerPaul Mundt <lethal@linux-sh.org>
Fri, 20 Aug 2010 10:10:38 +0000 (19:10 +0900)
commit960bc368e7561791b94b749087d2e0d7b36d231c
treed686302966fb8813b95cee44d331dd3916d8f327
parenta8dc49b51ace4ff80cb764c250338cb9b311fb14
sh: reinstate clock framework rate rounding.

This was killed off by a simplification patch previously that failed to
take the cpufreq use case in to account, so reinstate the old bounding
logic. The lowest rate bounding on the other hand was broken in that it
never actually got assigned a rate and the best fit rate was instead just
getting lucky based on the ordering of the rate table, fix this up so the
code actually does what it was intended to do originally.

Signed-off-by: Paul Mundt <lethal@linux-sh.org>
drivers/sh/clk.c