Viresh Kumar 270b9f421e SPEAr: clk: Add Fractional Synthesizer clock
All SPEAr SoC's contain Fractional Synthesizers. Their Fout is derived from
following equations:

Fout = Fin / (2 * div) (division factor)
div is 17 bits:-
     0-13 (fractional part)
     14-16 (integer part)
     div is (16-14 bits).(13-0 bits) (in binary)

     Fout = Fin/(2 * div)
     Fout = ((Fin / 10000)/(2 * div)) * 10000
     Fout = (2^14 * (Fin / 10000)/(2^14 * (2 * div))) * 10000
     Fout = (((Fin / 10000) << 14)/(2 * (div << 14))) * 10000

div << 14 is simply 17 bit value written at register.

This patch adds in support for this type of clock.

Signed-off-by: Viresh Kumar <viresh.kumar@st.com>
Reviewed-by: Mike Turquette <mturquette@linaro.org>
2012-05-12 21:19:27 +02:00
..
2012-04-20 11:31:00 -07:00
2012-04-12 15:36:33 -07:00
2012-03-27 16:03:32 -07:00
2012-04-21 01:58:20 -04:00
2012-04-18 11:15:50 -07:00
2012-04-12 15:36:33 -07:00
2012-03-17 01:41:43 -07:00
2012-03-30 00:09:17 -07:00
2012-04-12 15:35:12 -07:00
2012-04-21 12:45:52 -07:00
2012-04-18 13:15:51 -07:00
2012-03-29 18:02:10 -07:00
2012-04-19 15:12:49 -04:00