aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-omap2/clock44xx_data.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-omap2/clock44xx_data.c')
-rw-r--r--arch/arm/mach-omap2/clock44xx_data.c237
1 files changed, 76 insertions, 161 deletions
diff --git a/arch/arm/mach-omap2/clock44xx_data.c b/arch/arm/mach-omap2/clock44xx_data.c
index 8c965671b4d4..044df38f65ce 100644
--- a/arch/arm/mach-omap2/clock44xx_data.c
+++ b/arch/arm/mach-omap2/clock44xx_data.c
@@ -53,9 +53,9 @@ static struct clk extalt_clkin_ck = {
53static struct clk pad_clks_ck = { 53static struct clk pad_clks_ck = {
54 .name = "pad_clks_ck", 54 .name = "pad_clks_ck",
55 .rate = 12000000, 55 .rate = 12000000,
56 .ops = &clkops_omap2_dflt, 56 .ops = &clkops_omap2_dflt,
57 .enable_reg = OMAP4430_CM_CLKSEL_ABE, 57 .enable_reg = OMAP4430_CM_CLKSEL_ABE,
58 .enable_bit = OMAP4430_PAD_CLKS_GATE_SHIFT, 58 .enable_bit = OMAP4430_PAD_CLKS_GATE_SHIFT,
59}; 59};
60 60
61static struct clk pad_slimbus_core_clks_ck = { 61static struct clk pad_slimbus_core_clks_ck = {
@@ -73,9 +73,9 @@ static struct clk secure_32k_clk_src_ck = {
73static struct clk slimbus_clk = { 73static struct clk slimbus_clk = {
74 .name = "slimbus_clk", 74 .name = "slimbus_clk",
75 .rate = 12000000, 75 .rate = 12000000,
76 .ops = &clkops_omap2_dflt, 76 .ops = &clkops_omap2_dflt,
77 .enable_reg = OMAP4430_CM_CLKSEL_ABE, 77 .enable_reg = OMAP4430_CM_CLKSEL_ABE,
78 .enable_bit = OMAP4430_SLIMBUS_CLK_GATE_SHIFT, 78 .enable_bit = OMAP4430_SLIMBUS_CLK_GATE_SHIFT,
79}; 79};
80 80
81static struct clk sys_32k_ck = { 81static struct clk sys_32k_ck = {
@@ -258,8 +258,8 @@ static struct dpll_data dpll_abe_dd = {
258 .enable_mask = OMAP4430_DPLL_EN_MASK, 258 .enable_mask = OMAP4430_DPLL_EN_MASK,
259 .autoidle_mask = OMAP4430_AUTO_DPLL_MODE_MASK, 259 .autoidle_mask = OMAP4430_AUTO_DPLL_MODE_MASK,
260 .idlest_mask = OMAP4430_ST_DPLL_CLK_MASK, 260 .idlest_mask = OMAP4430_ST_DPLL_CLK_MASK,
261 .max_multiplier = OMAP4430_MAX_DPLL_MULT, 261 .max_multiplier = 2047,
262 .max_divider = OMAP4430_MAX_DPLL_DIV, 262 .max_divider = 128,
263 .min_divider = 1, 263 .min_divider = 1,
264}; 264};
265 265
@@ -278,10 +278,10 @@ static struct clk dpll_abe_ck = {
278static struct clk dpll_abe_x2_ck = { 278static struct clk dpll_abe_x2_ck = {
279 .name = "dpll_abe_x2_ck", 279 .name = "dpll_abe_x2_ck",
280 .parent = &dpll_abe_ck, 280 .parent = &dpll_abe_ck,
281 .clksel_reg = OMAP4430_CM_DIV_M2_DPLL_ABE,
281 .flags = CLOCK_CLKOUTX2, 282 .flags = CLOCK_CLKOUTX2,
282 .ops = &clkops_omap4_dpllmx_ops, 283 .ops = &clkops_omap4_dpllmx_ops,
283 .recalc = &omap3_clkoutx2_recalc, 284 .recalc = &omap3_clkoutx2_recalc,
284 .clksel_reg = OMAP4430_CM_DIV_M2_DPLL_ABE,
285}; 285};
286 286
287static const struct clksel_rate div31_1to31_rates[] = { 287static const struct clksel_rate div31_1to31_rates[] = {
@@ -434,8 +434,8 @@ static struct dpll_data dpll_core_dd = {
434 .enable_mask = OMAP4430_DPLL_EN_MASK, 434 .enable_mask = OMAP4430_DPLL_EN_MASK,
435 .autoidle_mask = OMAP4430_AUTO_DPLL_MODE_MASK, 435 .autoidle_mask = OMAP4430_AUTO_DPLL_MODE_MASK,
436 .idlest_mask = OMAP4430_ST_DPLL_CLK_MASK, 436 .idlest_mask = OMAP4430_ST_DPLL_CLK_MASK,
437 .max_multiplier = OMAP4430_MAX_DPLL_MULT, 437 .max_multiplier = 2047,
438 .max_divider = OMAP4430_MAX_DPLL_DIV, 438 .max_divider = 128,
439 .min_divider = 1, 439 .min_divider = 1,
440}; 440};
441 441
@@ -622,11 +622,11 @@ static struct clk dpll_core_m3x2_ck = {
622 .clksel_reg = OMAP4430_CM_DIV_M3_DPLL_CORE, 622 .clksel_reg = OMAP4430_CM_DIV_M3_DPLL_CORE,
623 .clksel_mask = OMAP4430_DPLL_CLKOUTHIF_DIV_MASK, 623 .clksel_mask = OMAP4430_DPLL_CLKOUTHIF_DIV_MASK,
624 .ops = &clkops_omap2_dflt, 624 .ops = &clkops_omap2_dflt,
625 .enable_reg = OMAP4430_CM_DIV_M3_DPLL_CORE,
626 .enable_bit = OMAP4430_DPLL_CLKOUTHIF_GATE_CTRL_SHIFT,
627 .recalc = &omap2_clksel_recalc, 625 .recalc = &omap2_clksel_recalc,
628 .round_rate = &omap2_clksel_round_rate, 626 .round_rate = &omap2_clksel_round_rate,
629 .set_rate = &omap2_clksel_set_rate, 627 .set_rate = &omap2_clksel_set_rate,
628 .enable_reg = OMAP4430_CM_DIV_M3_DPLL_CORE,
629 .enable_bit = OMAP4430_DPLL_CLKOUTHIF_GATE_CTRL_SHIFT,
630}; 630};
631 631
632static struct clk dpll_core_m7x2_ck = { 632static struct clk dpll_core_m7x2_ck = {
@@ -672,8 +672,8 @@ static struct dpll_data dpll_iva_dd = {
672 .enable_mask = OMAP4430_DPLL_EN_MASK, 672 .enable_mask = OMAP4430_DPLL_EN_MASK,
673 .autoidle_mask = OMAP4430_AUTO_DPLL_MODE_MASK, 673 .autoidle_mask = OMAP4430_AUTO_DPLL_MODE_MASK,
674 .idlest_mask = OMAP4430_ST_DPLL_CLK_MASK, 674 .idlest_mask = OMAP4430_ST_DPLL_CLK_MASK,
675 .max_multiplier = OMAP4430_MAX_DPLL_MULT, 675 .max_multiplier = 2047,
676 .max_divider = OMAP4430_MAX_DPLL_DIV, 676 .max_divider = 128,
677 .min_divider = 1, 677 .min_divider = 1,
678}; 678};
679 679
@@ -740,8 +740,8 @@ static struct dpll_data dpll_mpu_dd = {
740 .enable_mask = OMAP4430_DPLL_EN_MASK, 740 .enable_mask = OMAP4430_DPLL_EN_MASK,
741 .autoidle_mask = OMAP4430_AUTO_DPLL_MODE_MASK, 741 .autoidle_mask = OMAP4430_AUTO_DPLL_MODE_MASK,
742 .idlest_mask = OMAP4430_ST_DPLL_CLK_MASK, 742 .idlest_mask = OMAP4430_ST_DPLL_CLK_MASK,
743 .max_multiplier = OMAP4430_MAX_DPLL_MULT, 743 .max_multiplier = 2047,
744 .max_divider = OMAP4430_MAX_DPLL_DIV, 744 .max_divider = 128,
745 .min_divider = 1, 745 .min_divider = 1,
746}; 746};
747 747
@@ -813,8 +813,8 @@ static struct dpll_data dpll_per_dd = {
813 .enable_mask = OMAP4430_DPLL_EN_MASK, 813 .enable_mask = OMAP4430_DPLL_EN_MASK,
814 .autoidle_mask = OMAP4430_AUTO_DPLL_MODE_MASK, 814 .autoidle_mask = OMAP4430_AUTO_DPLL_MODE_MASK,
815 .idlest_mask = OMAP4430_ST_DPLL_CLK_MASK, 815 .idlest_mask = OMAP4430_ST_DPLL_CLK_MASK,
816 .max_multiplier = OMAP4430_MAX_DPLL_MULT, 816 .max_multiplier = 2047,
817 .max_divider = OMAP4430_MAX_DPLL_DIV, 817 .max_divider = 128,
818 .min_divider = 1, 818 .min_divider = 1,
819}; 819};
820 820
@@ -850,10 +850,10 @@ static struct clk dpll_per_m2_ck = {
850static struct clk dpll_per_x2_ck = { 850static struct clk dpll_per_x2_ck = {
851 .name = "dpll_per_x2_ck", 851 .name = "dpll_per_x2_ck",
852 .parent = &dpll_per_ck, 852 .parent = &dpll_per_ck,
853 .clksel_reg = OMAP4430_CM_DIV_M2_DPLL_PER,
853 .flags = CLOCK_CLKOUTX2, 854 .flags = CLOCK_CLKOUTX2,
854 .ops = &clkops_omap4_dpllmx_ops, 855 .ops = &clkops_omap4_dpllmx_ops,
855 .recalc = &omap3_clkoutx2_recalc, 856 .recalc = &omap3_clkoutx2_recalc,
856 .clksel_reg = OMAP4430_CM_DIV_M2_DPLL_PER,
857}; 857};
858 858
859static const struct clksel dpll_per_m2x2_div[] = { 859static const struct clksel dpll_per_m2x2_div[] = {
@@ -880,11 +880,11 @@ static struct clk dpll_per_m3x2_ck = {
880 .clksel_reg = OMAP4430_CM_DIV_M3_DPLL_PER, 880 .clksel_reg = OMAP4430_CM_DIV_M3_DPLL_PER,
881 .clksel_mask = OMAP4430_DPLL_CLKOUTHIF_DIV_MASK, 881 .clksel_mask = OMAP4430_DPLL_CLKOUTHIF_DIV_MASK,
882 .ops = &clkops_omap2_dflt, 882 .ops = &clkops_omap2_dflt,
883 .enable_reg = OMAP4430_CM_DIV_M3_DPLL_PER,
884 .enable_bit = OMAP4430_DPLL_CLKOUTHIF_GATE_CTRL_SHIFT,
885 .recalc = &omap2_clksel_recalc, 883 .recalc = &omap2_clksel_recalc,
886 .round_rate = &omap2_clksel_round_rate, 884 .round_rate = &omap2_clksel_round_rate,
887 .set_rate = &omap2_clksel_set_rate, 885 .set_rate = &omap2_clksel_set_rate,
886 .enable_reg = OMAP4430_CM_DIV_M3_DPLL_PER,
887 .enable_bit = OMAP4430_DPLL_CLKOUTHIF_GATE_CTRL_SHIFT,
888}; 888};
889 889
890static struct clk dpll_per_m4x2_ck = { 890static struct clk dpll_per_m4x2_ck = {
@@ -935,63 +935,6 @@ static struct clk dpll_per_m7x2_ck = {
935 .set_rate = &omap2_clksel_set_rate, 935 .set_rate = &omap2_clksel_set_rate,
936}; 936};
937 937
938/* DPLL_UNIPRO */
939static struct dpll_data dpll_unipro_dd = {
940 .mult_div1_reg = OMAP4430_CM_CLKSEL_DPLL_UNIPRO,
941 .clk_bypass = &sys_clkin_ck,
942 .clk_ref = &sys_clkin_ck,
943 .control_reg = OMAP4430_CM_CLKMODE_DPLL_UNIPRO,
944 .modes = (1 << DPLL_LOW_POWER_BYPASS) | (1 << DPLL_LOCKED),
945 .autoidle_reg = OMAP4430_CM_AUTOIDLE_DPLL_UNIPRO,
946 .idlest_reg = OMAP4430_CM_IDLEST_DPLL_UNIPRO,
947 .mult_mask = OMAP4430_DPLL_MULT_MASK,
948 .div1_mask = OMAP4430_DPLL_DIV_MASK,
949 .enable_mask = OMAP4430_DPLL_EN_MASK,
950 .autoidle_mask = OMAP4430_AUTO_DPLL_MODE_MASK,
951 .idlest_mask = OMAP4430_ST_DPLL_CLK_MASK,
952 .sddiv_mask = OMAP4430_DPLL_SD_DIV_MASK,
953 .max_multiplier = OMAP4430_MAX_DPLL_MULT,
954 .max_divider = OMAP4430_MAX_DPLL_DIV,
955 .min_divider = 1,
956};
957
958
959static struct clk dpll_unipro_ck = {
960 .name = "dpll_unipro_ck",
961 .parent = &sys_clkin_ck,
962 .dpll_data = &dpll_unipro_dd,
963 .init = &omap2_init_dpll_parent,
964 .ops = &clkops_omap3_noncore_dpll_ops,
965 .recalc = &omap3_dpll_recalc,
966 .round_rate = &omap2_dpll_round_rate,
967 .set_rate = &omap3_noncore_dpll_set_rate,
968};
969
970static struct clk dpll_unipro_x2_ck = {
971 .name = "dpll_unipro_x2_ck",
972 .parent = &dpll_unipro_ck,
973 .flags = CLOCK_CLKOUTX2,
974 .ops = &clkops_null,
975 .recalc = &omap3_clkoutx2_recalc,
976};
977
978static const struct clksel dpll_unipro_m2x2_div[] = {
979 { .parent = &dpll_unipro_x2_ck, .rates = div31_1to31_rates },
980 { .parent = NULL },
981};
982
983static struct clk dpll_unipro_m2x2_ck = {
984 .name = "dpll_unipro_m2x2_ck",
985 .parent = &dpll_unipro_x2_ck,
986 .clksel = dpll_unipro_m2x2_div,
987 .clksel_reg = OMAP4430_CM_DIV_M2_DPLL_UNIPRO,
988 .clksel_mask = OMAP4430_DPLL_CLKOUT_DIV_MASK,
989 .ops = &clkops_omap4_dpllmx_ops,
990 .recalc = &omap2_clksel_recalc,
991 .round_rate = &omap2_clksel_round_rate,
992 .set_rate = &omap2_clksel_set_rate,
993};
994
995static struct clk usb_hs_clk_div_ck = { 938static struct clk usb_hs_clk_div_ck = {
996 .name = "usb_hs_clk_div_ck", 939 .name = "usb_hs_clk_div_ck",
997 .parent = &dpll_abe_m3x2_ck, 940 .parent = &dpll_abe_m3x2_ck,
@@ -1015,8 +958,9 @@ static struct dpll_data dpll_usb_dd = {
1015 .enable_mask = OMAP4430_DPLL_EN_MASK, 958 .enable_mask = OMAP4430_DPLL_EN_MASK,
1016 .autoidle_mask = OMAP4430_AUTO_DPLL_MODE_MASK, 959 .autoidle_mask = OMAP4430_AUTO_DPLL_MODE_MASK,
1017 .idlest_mask = OMAP4430_ST_DPLL_CLK_MASK, 960 .idlest_mask = OMAP4430_ST_DPLL_CLK_MASK,
1018 .max_multiplier = OMAP4430_MAX_DPLL_MULT, 961 .sddiv_mask = OMAP4430_DPLL_SD_DIV_MASK,
1019 .max_divider = OMAP4430_MAX_DPLL_DIV, 962 .max_multiplier = 4095,
963 .max_divider = 256,
1020 .min_divider = 1, 964 .min_divider = 1,
1021}; 965};
1022 966
@@ -1035,8 +979,8 @@ static struct clk dpll_usb_ck = {
1035static struct clk dpll_usb_clkdcoldo_ck = { 979static struct clk dpll_usb_clkdcoldo_ck = {
1036 .name = "dpll_usb_clkdcoldo_ck", 980 .name = "dpll_usb_clkdcoldo_ck",
1037 .parent = &dpll_usb_ck, 981 .parent = &dpll_usb_ck,
1038 .ops = &clkops_omap4_dpllmx_ops,
1039 .clksel_reg = OMAP4430_CM_CLKDCOLDO_DPLL_USB, 982 .clksel_reg = OMAP4430_CM_CLKDCOLDO_DPLL_USB,
983 .ops = &clkops_omap4_dpllmx_ops,
1040 .recalc = &followparent_recalc, 984 .recalc = &followparent_recalc,
1041}; 985};
1042 986
@@ -1169,19 +1113,6 @@ static struct clk func_96m_fclk = {
1169 .set_rate = &omap2_clksel_set_rate, 1113 .set_rate = &omap2_clksel_set_rate,
1170}; 1114};
1171 1115
1172static const struct clksel hsmmc6_fclk_sel[] = {
1173 { .parent = &func_64m_fclk, .rates = div_1_0_rates },
1174 { .parent = &func_96m_fclk, .rates = div_1_1_rates },
1175 { .parent = NULL },
1176};
1177
1178static struct clk hsmmc6_fclk = {
1179 .name = "hsmmc6_fclk",
1180 .parent = &func_64m_fclk,
1181 .ops = &clkops_null,
1182 .recalc = &followparent_recalc,
1183};
1184
1185static const struct clksel_rate div2_1to8_rates[] = { 1116static const struct clksel_rate div2_1to8_rates[] = {
1186 { .div = 1, .val = 0, .flags = RATE_IN_4430 }, 1117 { .div = 1, .val = 0, .flags = RATE_IN_4430 },
1187 { .div = 8, .val = 1, .flags = RATE_IN_4430 }, 1118 { .div = 8, .val = 1, .flags = RATE_IN_4430 },
@@ -1264,6 +1195,21 @@ static struct clk l4_wkup_clk_mux_ck = {
1264 .recalc = &omap2_clksel_recalc, 1195 .recalc = &omap2_clksel_recalc,
1265}; 1196};
1266 1197
1198static struct clk ocp_abe_iclk = {
1199 .name = "ocp_abe_iclk",
1200 .parent = &aess_fclk,
1201 .ops = &clkops_null,
1202 .recalc = &followparent_recalc,
1203};
1204
1205static struct clk per_abe_24m_fclk = {
1206 .name = "per_abe_24m_fclk",
1207 .parent = &dpll_abe_m2_ck,
1208 .ops = &clkops_null,
1209 .fixed_div = 4,
1210 .recalc = &omap_fixed_divisor_recalc,
1211};
1212
1267static const struct clksel per_abe_nc_fclk_div[] = { 1213static const struct clksel per_abe_nc_fclk_div[] = {
1268 { .parent = &dpll_abe_m2_ck, .rates = div2_1to2_rates }, 1214 { .parent = &dpll_abe_m2_ck, .rates = div2_1to2_rates },
1269 { .parent = NULL }, 1215 { .parent = NULL },
@@ -1281,41 +1227,6 @@ static struct clk per_abe_nc_fclk = {
1281 .set_rate = &omap2_clksel_set_rate, 1227 .set_rate = &omap2_clksel_set_rate,
1282}; 1228};
1283 1229
1284static const struct clksel mcasp2_fclk_sel[] = {
1285 { .parent = &func_96m_fclk, .rates = div_1_0_rates },
1286 { .parent = &per_abe_nc_fclk, .rates = div_1_1_rates },
1287 { .parent = NULL },
1288};
1289
1290static struct clk mcasp2_fclk = {
1291 .name = "mcasp2_fclk",
1292 .parent = &func_96m_fclk,
1293 .ops = &clkops_null,
1294 .recalc = &followparent_recalc,
1295};
1296
1297static struct clk mcasp3_fclk = {
1298 .name = "mcasp3_fclk",
1299 .parent = &func_96m_fclk,
1300 .ops = &clkops_null,
1301 .recalc = &followparent_recalc,
1302};
1303
1304static struct clk ocp_abe_iclk = {
1305 .name = "ocp_abe_iclk",
1306 .parent = &aess_fclk,
1307 .ops = &clkops_null,
1308 .recalc = &followparent_recalc,
1309};
1310
1311static struct clk per_abe_24m_fclk = {
1312 .name = "per_abe_24m_fclk",
1313 .parent = &dpll_abe_m2_ck,
1314 .ops = &clkops_null,
1315 .fixed_div = 4,
1316 .recalc = &omap_fixed_divisor_recalc,
1317};
1318
1319static const struct clksel pmd_stm_clock_mux_sel[] = { 1230static const struct clksel pmd_stm_clock_mux_sel[] = {
1320 { .parent = &sys_clkin_ck, .rates = div_1_0_rates }, 1231 { .parent = &sys_clkin_ck, .rates = div_1_0_rates },
1321 { .parent = &dpll_core_m6x2_ck, .rates = div_1_1_rates }, 1232 { .parent = &dpll_core_m6x2_ck, .rates = div_1_1_rates },
@@ -1846,8 +1757,8 @@ static struct clk l3_instr_ick = {
1846 .ops = &clkops_omap2_dflt, 1757 .ops = &clkops_omap2_dflt,
1847 .enable_reg = OMAP4430_CM_L3INSTR_L3_INSTR_CLKCTRL, 1758 .enable_reg = OMAP4430_CM_L3INSTR_L3_INSTR_CLKCTRL,
1848 .enable_bit = OMAP4430_MODULEMODE_HWCTRL, 1759 .enable_bit = OMAP4430_MODULEMODE_HWCTRL,
1849 .clkdm_name = "l3_instr_clkdm",
1850 .flags = ENABLE_ON_INIT, 1760 .flags = ENABLE_ON_INIT,
1761 .clkdm_name = "l3_instr_clkdm",
1851 .parent = &l3_div_ck, 1762 .parent = &l3_div_ck,
1852 .recalc = &followparent_recalc, 1763 .recalc = &followparent_recalc,
1853}; 1764};
@@ -1857,8 +1768,8 @@ static struct clk l3_main_3_ick = {
1857 .ops = &clkops_omap2_dflt, 1768 .ops = &clkops_omap2_dflt,
1858 .enable_reg = OMAP4430_CM_L3INSTR_L3_3_CLKCTRL, 1769 .enable_reg = OMAP4430_CM_L3INSTR_L3_3_CLKCTRL,
1859 .enable_bit = OMAP4430_MODULEMODE_HWCTRL, 1770 .enable_bit = OMAP4430_MODULEMODE_HWCTRL,
1860 .clkdm_name = "l3_instr_clkdm",
1861 .flags = ENABLE_ON_INIT, 1771 .flags = ENABLE_ON_INIT,
1772 .clkdm_name = "l3_instr_clkdm",
1862 .parent = &l3_div_ck, 1773 .parent = &l3_div_ck,
1863 .recalc = &followparent_recalc, 1774 .recalc = &followparent_recalc,
1864}; 1775};
@@ -1995,10 +1906,16 @@ static struct clk mcbsp3_fck = {
1995 .clkdm_name = "abe_clkdm", 1906 .clkdm_name = "abe_clkdm",
1996}; 1907};
1997 1908
1909static const struct clksel mcbsp4_sync_mux_sel[] = {
1910 { .parent = &func_96m_fclk, .rates = div_1_0_rates },
1911 { .parent = &per_abe_nc_fclk, .rates = div_1_1_rates },
1912 { .parent = NULL },
1913};
1914
1998static struct clk mcbsp4_sync_mux_ck = { 1915static struct clk mcbsp4_sync_mux_ck = {
1999 .name = "mcbsp4_sync_mux_ck", 1916 .name = "mcbsp4_sync_mux_ck",
2000 .parent = &func_96m_fclk, 1917 .parent = &func_96m_fclk,
2001 .clksel = mcasp2_fclk_sel, 1918 .clksel = mcbsp4_sync_mux_sel,
2002 .init = &omap2_init_clksel_parent, 1919 .init = &omap2_init_clksel_parent,
2003 .clksel_reg = OMAP4430_CM_L4PER_MCBSP4_CLKCTRL, 1920 .clksel_reg = OMAP4430_CM_L4PER_MCBSP4_CLKCTRL,
2004 .clksel_mask = OMAP4430_CLKSEL_INTERNAL_SOURCE_MASK, 1921 .clksel_mask = OMAP4430_CLKSEL_INTERNAL_SOURCE_MASK,
@@ -2077,11 +1994,17 @@ static struct clk mcspi4_fck = {
2077 .recalc = &followparent_recalc, 1994 .recalc = &followparent_recalc,
2078}; 1995};
2079 1996
1997static const struct clksel hsmmc1_fclk_sel[] = {
1998 { .parent = &func_64m_fclk, .rates = div_1_0_rates },
1999 { .parent = &func_96m_fclk, .rates = div_1_1_rates },
2000 { .parent = NULL },
2001};
2002
2080/* Merged hsmmc1_fclk into mmc1 */ 2003/* Merged hsmmc1_fclk into mmc1 */
2081static struct clk mmc1_fck = { 2004static struct clk mmc1_fck = {
2082 .name = "mmc1_fck", 2005 .name = "mmc1_fck",
2083 .parent = &func_64m_fclk, 2006 .parent = &func_64m_fclk,
2084 .clksel = hsmmc6_fclk_sel, 2007 .clksel = hsmmc1_fclk_sel,
2085 .init = &omap2_init_clksel_parent, 2008 .init = &omap2_init_clksel_parent,
2086 .clksel_reg = OMAP4430_CM_L3INIT_MMC1_CLKCTRL, 2009 .clksel_reg = OMAP4430_CM_L3INIT_MMC1_CLKCTRL,
2087 .clksel_mask = OMAP4430_CLKSEL_MASK, 2010 .clksel_mask = OMAP4430_CLKSEL_MASK,
@@ -2096,7 +2019,7 @@ static struct clk mmc1_fck = {
2096static struct clk mmc2_fck = { 2019static struct clk mmc2_fck = {
2097 .name = "mmc2_fck", 2020 .name = "mmc2_fck",
2098 .parent = &func_64m_fclk, 2021 .parent = &func_64m_fclk,
2099 .clksel = hsmmc6_fclk_sel, 2022 .clksel = hsmmc1_fclk_sel,
2100 .init = &omap2_init_clksel_parent, 2023 .init = &omap2_init_clksel_parent,
2101 .clksel_reg = OMAP4430_CM_L3INIT_MMC2_CLKCTRL, 2024 .clksel_reg = OMAP4430_CM_L3INIT_MMC2_CLKCTRL,
2102 .clksel_mask = OMAP4430_CLKSEL_MASK, 2025 .clksel_mask = OMAP4430_CLKSEL_MASK,
@@ -2162,8 +2085,8 @@ static struct clk ocp_wp_noc_ick = {
2162 .ops = &clkops_omap2_dflt, 2085 .ops = &clkops_omap2_dflt,
2163 .enable_reg = OMAP4430_CM_L3INSTR_OCP_WP1_CLKCTRL, 2086 .enable_reg = OMAP4430_CM_L3INSTR_OCP_WP1_CLKCTRL,
2164 .enable_bit = OMAP4430_MODULEMODE_HWCTRL, 2087 .enable_bit = OMAP4430_MODULEMODE_HWCTRL,
2165 .clkdm_name = "l3_instr_clkdm",
2166 .flags = ENABLE_ON_INIT, 2088 .flags = ENABLE_ON_INIT,
2089 .clkdm_name = "l3_instr_clkdm",
2167 .parent = &l3_div_ck, 2090 .parent = &l3_div_ck,
2168 .recalc = &followparent_recalc, 2091 .recalc = &followparent_recalc,
2169}; 2092};
@@ -2895,6 +2818,7 @@ static struct clk auxclk2_ck = {
2895 .enable_reg = OMAP4_SCRM_AUXCLK2, 2818 .enable_reg = OMAP4_SCRM_AUXCLK2,
2896 .enable_bit = OMAP4_ENABLE_SHIFT, 2819 .enable_bit = OMAP4_ENABLE_SHIFT,
2897}; 2820};
2821
2898static struct clk auxclk3_ck = { 2822static struct clk auxclk3_ck = {
2899 .name = "auxclk3_ck", 2823 .name = "auxclk3_ck",
2900 .parent = &sys_clkin_ck, 2824 .parent = &sys_clkin_ck,
@@ -3077,9 +3001,6 @@ static struct omap_clk omap44xx_clks[] = {
3077 CLK(NULL, "dpll_per_m5x2_ck", &dpll_per_m5x2_ck, CK_443X), 3001 CLK(NULL, "dpll_per_m5x2_ck", &dpll_per_m5x2_ck, CK_443X),
3078 CLK(NULL, "dpll_per_m6x2_ck", &dpll_per_m6x2_ck, CK_443X), 3002 CLK(NULL, "dpll_per_m6x2_ck", &dpll_per_m6x2_ck, CK_443X),
3079 CLK(NULL, "dpll_per_m7x2_ck", &dpll_per_m7x2_ck, CK_443X), 3003 CLK(NULL, "dpll_per_m7x2_ck", &dpll_per_m7x2_ck, CK_443X),
3080 CLK(NULL, "dpll_unipro_ck", &dpll_unipro_ck, CK_443X),
3081 CLK(NULL, "dpll_unipro_x2_ck", &dpll_unipro_x2_ck, CK_443X),
3082 CLK(NULL, "dpll_unipro_m2x2_ck", &dpll_unipro_m2x2_ck, CK_443X),
3083 CLK(NULL, "usb_hs_clk_div_ck", &usb_hs_clk_div_ck, CK_443X), 3004 CLK(NULL, "usb_hs_clk_div_ck", &usb_hs_clk_div_ck, CK_443X),
3084 CLK(NULL, "dpll_usb_ck", &dpll_usb_ck, CK_443X), 3005 CLK(NULL, "dpll_usb_ck", &dpll_usb_ck, CK_443X),
3085 CLK(NULL, "dpll_usb_clkdcoldo_ck", &dpll_usb_clkdcoldo_ck, CK_443X), 3006 CLK(NULL, "dpll_usb_clkdcoldo_ck", &dpll_usb_clkdcoldo_ck, CK_443X),
@@ -3092,17 +3013,14 @@ static struct omap_clk omap44xx_clks[] = {
3092 CLK(NULL, "func_48mc_fclk", &func_48mc_fclk, CK_443X), 3013 CLK(NULL, "func_48mc_fclk", &func_48mc_fclk, CK_443X),
3093 CLK(NULL, "func_64m_fclk", &func_64m_fclk, CK_443X), 3014 CLK(NULL, "func_64m_fclk", &func_64m_fclk, CK_443X),
3094 CLK(NULL, "func_96m_fclk", &func_96m_fclk, CK_443X), 3015 CLK(NULL, "func_96m_fclk", &func_96m_fclk, CK_443X),
3095 CLK(NULL, "hsmmc6_fclk", &hsmmc6_fclk, CK_443X),
3096 CLK(NULL, "init_60m_fclk", &init_60m_fclk, CK_443X), 3016 CLK(NULL, "init_60m_fclk", &init_60m_fclk, CK_443X),
3097 CLK(NULL, "l3_div_ck", &l3_div_ck, CK_443X), 3017 CLK(NULL, "l3_div_ck", &l3_div_ck, CK_443X),
3098 CLK(NULL, "l4_div_ck", &l4_div_ck, CK_443X), 3018 CLK(NULL, "l4_div_ck", &l4_div_ck, CK_443X),
3099 CLK(NULL, "lp_clk_div_ck", &lp_clk_div_ck, CK_443X), 3019 CLK(NULL, "lp_clk_div_ck", &lp_clk_div_ck, CK_443X),
3100 CLK(NULL, "l4_wkup_clk_mux_ck", &l4_wkup_clk_mux_ck, CK_443X), 3020 CLK(NULL, "l4_wkup_clk_mux_ck", &l4_wkup_clk_mux_ck, CK_443X),
3101 CLK(NULL, "per_abe_nc_fclk", &per_abe_nc_fclk, CK_443X),
3102 CLK(NULL, "mcasp2_fclk", &mcasp2_fclk, CK_443X),
3103 CLK(NULL, "mcasp3_fclk", &mcasp3_fclk, CK_443X),
3104 CLK(NULL, "ocp_abe_iclk", &ocp_abe_iclk, CK_443X), 3021 CLK(NULL, "ocp_abe_iclk", &ocp_abe_iclk, CK_443X),
3105 CLK(NULL, "per_abe_24m_fclk", &per_abe_24m_fclk, CK_443X), 3022 CLK(NULL, "per_abe_24m_fclk", &per_abe_24m_fclk, CK_443X),
3023 CLK(NULL, "per_abe_nc_fclk", &per_abe_nc_fclk, CK_443X),
3106 CLK(NULL, "pmd_stm_clock_mux_ck", &pmd_stm_clock_mux_ck, CK_443X), 3024 CLK(NULL, "pmd_stm_clock_mux_ck", &pmd_stm_clock_mux_ck, CK_443X),
3107 CLK(NULL, "pmd_trace_clk_mux_ck", &pmd_trace_clk_mux_ck, CK_443X), 3025 CLK(NULL, "pmd_trace_clk_mux_ck", &pmd_trace_clk_mux_ck, CK_443X),
3108 CLK(NULL, "syc_clk_div_ck", &syc_clk_div_ck, CK_443X), 3026 CLK(NULL, "syc_clk_div_ck", &syc_clk_div_ck, CK_443X),
@@ -3204,7 +3122,6 @@ static struct omap_clk omap44xx_clks[] = {
3204 CLK(NULL, "uart2_fck", &uart2_fck, CK_443X), 3122 CLK(NULL, "uart2_fck", &uart2_fck, CK_443X),
3205 CLK(NULL, "uart3_fck", &uart3_fck, CK_443X), 3123 CLK(NULL, "uart3_fck", &uart3_fck, CK_443X),
3206 CLK(NULL, "uart4_fck", &uart4_fck, CK_443X), 3124 CLK(NULL, "uart4_fck", &uart4_fck, CK_443X),
3207 CLK(NULL, "usb_host_fs_fck", &usb_host_fs_fck, CK_443X),
3208 CLK("usbhs-omap.0", "fs_fck", &usb_host_fs_fck, CK_443X), 3125 CLK("usbhs-omap.0", "fs_fck", &usb_host_fs_fck, CK_443X),
3209 CLK(NULL, "utmi_p1_gfclk", &utmi_p1_gfclk, CK_443X), 3126 CLK(NULL, "utmi_p1_gfclk", &utmi_p1_gfclk, CK_443X),
3210 CLK(NULL, "usb_host_hs_utmi_p1_clk", &usb_host_hs_utmi_p1_clk, CK_443X), 3127 CLK(NULL, "usb_host_hs_utmi_p1_clk", &usb_host_hs_utmi_p1_clk, CK_443X),
@@ -3216,9 +3133,7 @@ static struct omap_clk omap44xx_clks[] = {
3216 CLK(NULL, "usb_host_hs_hsic60m_p2_clk", &usb_host_hs_hsic60m_p2_clk, CK_443X), 3133 CLK(NULL, "usb_host_hs_hsic60m_p2_clk", &usb_host_hs_hsic60m_p2_clk, CK_443X),
3217 CLK(NULL, "usb_host_hs_hsic480m_p2_clk", &usb_host_hs_hsic480m_p2_clk, CK_443X), 3134 CLK(NULL, "usb_host_hs_hsic480m_p2_clk", &usb_host_hs_hsic480m_p2_clk, CK_443X),
3218 CLK(NULL, "usb_host_hs_func48mclk", &usb_host_hs_func48mclk, CK_443X), 3135 CLK(NULL, "usb_host_hs_func48mclk", &usb_host_hs_func48mclk, CK_443X),
3219 CLK(NULL, "usb_host_hs_fck", &usb_host_hs_fck, CK_443X),
3220 CLK("usbhs-omap.0", "hs_fck", &usb_host_hs_fck, CK_443X), 3136 CLK("usbhs-omap.0", "hs_fck", &usb_host_hs_fck, CK_443X),
3221 CLK("usbhs-omap.0", "usbhost_ick", &dummy_ck, CK_443X),
3222 CLK(NULL, "otg_60m_gfclk", &otg_60m_gfclk, CK_443X), 3137 CLK(NULL, "otg_60m_gfclk", &otg_60m_gfclk, CK_443X),
3223 CLK(NULL, "usb_otg_hs_xclk", &usb_otg_hs_xclk, CK_443X), 3138 CLK(NULL, "usb_otg_hs_xclk", &usb_otg_hs_xclk, CK_443X),
3224 CLK("musb-omap2430", "ick", &usb_otg_hs_ick, CK_443X), 3139 CLK("musb-omap2430", "ick", &usb_otg_hs_ick, CK_443X),
@@ -3226,17 +3141,26 @@ static struct omap_clk omap44xx_clks[] = {
3226 CLK(NULL, "usb_tll_hs_usb_ch2_clk", &usb_tll_hs_usb_ch2_clk, CK_443X), 3141 CLK(NULL, "usb_tll_hs_usb_ch2_clk", &usb_tll_hs_usb_ch2_clk, CK_443X),
3227 CLK(NULL, "usb_tll_hs_usb_ch0_clk", &usb_tll_hs_usb_ch0_clk, CK_443X), 3142 CLK(NULL, "usb_tll_hs_usb_ch0_clk", &usb_tll_hs_usb_ch0_clk, CK_443X),
3228 CLK(NULL, "usb_tll_hs_usb_ch1_clk", &usb_tll_hs_usb_ch1_clk, CK_443X), 3143 CLK(NULL, "usb_tll_hs_usb_ch1_clk", &usb_tll_hs_usb_ch1_clk, CK_443X),
3229 CLK(NULL, "usb_tll_hs_ick", &usb_tll_hs_ick, CK_443X),
3230 CLK("usbhs-omap.0", "usbtll_ick", &usb_tll_hs_ick, CK_443X), 3144 CLK("usbhs-omap.0", "usbtll_ick", &usb_tll_hs_ick, CK_443X),
3231 CLK("usbhs-omap.0", "usbtll_fck", &dummy_ck, CK_443X),
3232 CLK(NULL, "usim_ck", &usim_ck, CK_443X), 3145 CLK(NULL, "usim_ck", &usim_ck, CK_443X),
3233 CLK(NULL, "usim_fclk", &usim_fclk, CK_443X), 3146 CLK(NULL, "usim_fclk", &usim_fclk, CK_443X),
3234 CLK(NULL, "usim_fck", &usim_fck, CK_443X), 3147 CLK(NULL, "usim_fck", &usim_fck, CK_443X),
3235 CLK("omap_wdt", "fck", &wd_timer2_fck, CK_443X), 3148 CLK("omap_wdt", "fck", &wd_timer2_fck, CK_443X),
3236 CLK(NULL, "mailboxes_ick", &dummy_ck, CK_443X),
3237 CLK(NULL, "wd_timer3_fck", &wd_timer3_fck, CK_443X), 3149 CLK(NULL, "wd_timer3_fck", &wd_timer3_fck, CK_443X),
3238 CLK(NULL, "stm_clk_div_ck", &stm_clk_div_ck, CK_443X), 3150 CLK(NULL, "stm_clk_div_ck", &stm_clk_div_ck, CK_443X),
3239 CLK(NULL, "trace_clk_div_ck", &trace_clk_div_ck, CK_443X), 3151 CLK(NULL, "trace_clk_div_ck", &trace_clk_div_ck, CK_443X),
3152 CLK(NULL, "auxclk0_ck", &auxclk0_ck, CK_443X),
3153 CLK(NULL, "auxclk1_ck", &auxclk1_ck, CK_443X),
3154 CLK(NULL, "auxclk2_ck", &auxclk2_ck, CK_443X),
3155 CLK(NULL, "auxclk3_ck", &auxclk3_ck, CK_443X),
3156 CLK(NULL, "auxclk4_ck", &auxclk4_ck, CK_443X),
3157 CLK(NULL, "auxclk5_ck", &auxclk5_ck, CK_443X),
3158 CLK(NULL, "auxclkreq0_ck", &auxclkreq0_ck, CK_443X),
3159 CLK(NULL, "auxclkreq1_ck", &auxclkreq1_ck, CK_443X),
3160 CLK(NULL, "auxclkreq2_ck", &auxclkreq2_ck, CK_443X),
3161 CLK(NULL, "auxclkreq3_ck", &auxclkreq3_ck, CK_443X),
3162 CLK(NULL, "auxclkreq4_ck", &auxclkreq4_ck, CK_443X),
3163 CLK(NULL, "auxclkreq5_ck", &auxclkreq5_ck, CK_443X),
3240 CLK(NULL, "gpmc_ck", &dummy_ck, CK_443X), 3164 CLK(NULL, "gpmc_ck", &dummy_ck, CK_443X),
3241 CLK(NULL, "gpt1_ick", &dummy_ck, CK_443X), 3165 CLK(NULL, "gpt1_ick", &dummy_ck, CK_443X),
3242 CLK(NULL, "gpt2_ick", &dummy_ck, CK_443X), 3166 CLK(NULL, "gpt2_ick", &dummy_ck, CK_443X),
@@ -3253,6 +3177,7 @@ static struct omap_clk omap44xx_clks[] = {
3253 CLK("omap_i2c.2", "ick", &dummy_ck, CK_443X), 3177 CLK("omap_i2c.2", "ick", &dummy_ck, CK_443X),
3254 CLK("omap_i2c.3", "ick", &dummy_ck, CK_443X), 3178 CLK("omap_i2c.3", "ick", &dummy_ck, CK_443X),
3255 CLK("omap_i2c.4", "ick", &dummy_ck, CK_443X), 3179 CLK("omap_i2c.4", "ick", &dummy_ck, CK_443X),
3180 CLK(NULL, "mailboxes_ick", &dummy_ck, CK_443X),
3256 CLK("omap_hsmmc.0", "ick", &dummy_ck, CK_443X), 3181 CLK("omap_hsmmc.0", "ick", &dummy_ck, CK_443X),
3257 CLK("omap_hsmmc.1", "ick", &dummy_ck, CK_443X), 3182 CLK("omap_hsmmc.1", "ick", &dummy_ck, CK_443X),
3258 CLK("omap_hsmmc.2", "ick", &dummy_ck, CK_443X), 3183 CLK("omap_hsmmc.2", "ick", &dummy_ck, CK_443X),
@@ -3270,19 +3195,9 @@ static struct omap_clk omap44xx_clks[] = {
3270 CLK(NULL, "uart2_ick", &dummy_ck, CK_443X), 3195 CLK(NULL, "uart2_ick", &dummy_ck, CK_443X),
3271 CLK(NULL, "uart3_ick", &dummy_ck, CK_443X), 3196 CLK(NULL, "uart3_ick", &dummy_ck, CK_443X),
3272 CLK(NULL, "uart4_ick", &dummy_ck, CK_443X), 3197 CLK(NULL, "uart4_ick", &dummy_ck, CK_443X),
3198 CLK("usbhs-omap.0", "usbhost_ick", &dummy_ck, CK_443X),
3199 CLK("usbhs-omap.0", "usbtll_fck", &dummy_ck, CK_443X),
3273 CLK("omap_wdt", "ick", &dummy_ck, CK_443X), 3200 CLK("omap_wdt", "ick", &dummy_ck, CK_443X),
3274 CLK(NULL, "auxclk0_ck", &auxclk0_ck, CK_443X),
3275 CLK(NULL, "auxclk1_ck", &auxclk1_ck, CK_443X),
3276 CLK(NULL, "auxclk2_ck", &auxclk2_ck, CK_443X),
3277 CLK(NULL, "auxclk3_ck", &auxclk3_ck, CK_443X),
3278 CLK(NULL, "auxclk4_ck", &auxclk4_ck, CK_443X),
3279 CLK(NULL, "auxclk5_ck", &auxclk5_ck, CK_443X),
3280 CLK(NULL, "auxclkreq0_ck", &auxclkreq0_ck, CK_443X),
3281 CLK(NULL, "auxclkreq1_ck", &auxclkreq1_ck, CK_443X),
3282 CLK(NULL, "auxclkreq2_ck", &auxclkreq2_ck, CK_443X),
3283 CLK(NULL, "auxclkreq3_ck", &auxclkreq3_ck, CK_443X),
3284 CLK(NULL, "auxclkreq4_ck", &auxclkreq4_ck, CK_443X),
3285 CLK(NULL, "auxclkreq5_ck", &auxclkreq5_ck, CK_443X),
3286}; 3201};
3287 3202
3288int __init omap4xxx_clk_init(void) 3203int __init omap4xxx_clk_init(void)