diff options
author | Mike Turquette <mturquette@linaro.org> | 2014-09-30 02:43:12 -0400 |
---|---|---|
committer | Mike Turquette <mturquette@linaro.org> | 2014-09-30 02:43:12 -0400 |
commit | 24afc3852e5ec9c35de5ae1b3c4f9e4ecbf53cb6 (patch) | |
tree | 77674714fbc196c028ed2a08a96192d26d9512e6 /drivers/clk | |
parent | 82de1bc86c493ad832db270635fbf4e8c237f02f (diff) | |
parent | fa0111be4ff30150720db3c3e5ee8d7823921639 (diff) |
Merge tag 'for_3.18/samsung-clk' of git://git.kernel.org/pub/scm/linux/kernel/git/tfiga/samsung-clk into clk-next
Samsung clock patches for v3.18
1) non-critical fixes (without the need to push to stable)
fa0111be4ff3 clk: samsung: exynos4: remove duplicate div_core2 divider clock instantiation
b511593d7165 clk: samsung: exynos4: fix g3d clocks
c14254300131 clk: samsung: exynos4: add missing smmu_g2d clock and update comments
22842d244af3 clk: samsung: exynos5260: fix typo in clock name
e82ba578ccde clk: samsung: exynos3250: fix width field of mout_mmc0/1
59037b92f440 clk: samsung: exynos3250: fix width and shift of div_spi0_isp clock
5ce37f266650 clk: samsung: exynos3250: fix mout_cam_blk parent list
2) Clock driver extensions
07ccf02ba5c3 dt-bindings: clk: samsung: Document the DMC domain of Exynos3250 CMU
d0e73eaf1925 ARM: dts: exynos3250: Add CMU node for DMC domain clocks
e3c3f19bc618 clk: samsung: exynos3250: Register DMC clk provider
4676f0aab9dc clk: samsung: exynos4: add support for MOUT_HDMI and MOUT_MIXER clocks
Diffstat (limited to 'drivers/clk')
-rw-r--r-- | drivers/clk/samsung/clk-exynos3250.c | 202 | ||||
-rw-r--r-- | drivers/clk/samsung/clk-exynos4.c | 18 | ||||
-rw-r--r-- | drivers/clk/samsung/clk-exynos5260.c | 2 |
3 files changed, 208 insertions, 14 deletions
diff --git a/drivers/clk/samsung/clk-exynos3250.c b/drivers/clk/samsung/clk-exynos3250.c index dc85f8e7a2d7..6e6cca392082 100644 --- a/drivers/clk/samsung/clk-exynos3250.c +++ b/drivers/clk/samsung/clk-exynos3250.c | |||
@@ -110,7 +110,14 @@ enum exynos3250_plls { | |||
110 | nr_plls | 110 | nr_plls |
111 | }; | 111 | }; |
112 | 112 | ||
113 | /* list of PLLs in DMC block to be registered */ | ||
114 | enum exynos3250_dmc_plls { | ||
115 | bpll, epll, | ||
116 | nr_dmc_plls | ||
117 | }; | ||
118 | |||
113 | static void __iomem *reg_base; | 119 | static void __iomem *reg_base; |
120 | static void __iomem *dmc_reg_base; | ||
114 | 121 | ||
115 | /* | 122 | /* |
116 | * Support for CMU save/restore across system suspends | 123 | * Support for CMU save/restore across system suspends |
@@ -266,6 +273,7 @@ PNAME(group_sclk_cam_blk_p) = { "xxti", "xusbxti", | |||
266 | "none", "none", "none", | 273 | "none", "none", "none", |
267 | "none", "div_mpll_pre", | 274 | "none", "div_mpll_pre", |
268 | "mout_epll_user", "mout_vpll", | 275 | "mout_epll_user", "mout_vpll", |
276 | "none", "none", "none", | ||
269 | "div_cam_blk_320", }; | 277 | "div_cam_blk_320", }; |
270 | PNAME(group_sclk_fimd0_p) = { "xxti", "xusbxti", | 278 | PNAME(group_sclk_fimd0_p) = { "xxti", "xusbxti", |
271 | "m_bitclkhsdiv4_2l", "none", | 279 | "m_bitclkhsdiv4_2l", "none", |
@@ -353,8 +361,8 @@ static struct samsung_mux_clock mux_clks[] __initdata = { | |||
353 | 361 | ||
354 | /* SRC_FSYS */ | 362 | /* SRC_FSYS */ |
355 | MUX(CLK_MOUT_TSADC, "mout_tsadc", group_sclk_p, SRC_FSYS, 28, 4), | 363 | MUX(CLK_MOUT_TSADC, "mout_tsadc", group_sclk_p, SRC_FSYS, 28, 4), |
356 | MUX(CLK_MOUT_MMC1, "mout_mmc1", group_sclk_p, SRC_FSYS, 4, 3), | 364 | MUX(CLK_MOUT_MMC1, "mout_mmc1", group_sclk_p, SRC_FSYS, 4, 4), |
357 | MUX(CLK_MOUT_MMC0, "mout_mmc0", group_sclk_p, SRC_FSYS, 0, 3), | 365 | MUX(CLK_MOUT_MMC0, "mout_mmc0", group_sclk_p, SRC_FSYS, 0, 4), |
358 | 366 | ||
359 | /* SRC_PERIL0 */ | 367 | /* SRC_PERIL0 */ |
360 | MUX(CLK_MOUT_UART1, "mout_uart1", group_sclk_p, SRC_PERIL0, 4, 4), | 368 | MUX(CLK_MOUT_UART1, "mout_uart1", group_sclk_p, SRC_PERIL0, 4, 4), |
@@ -423,7 +431,7 @@ static struct samsung_div_clock div_clks[] __initdata = { | |||
423 | DIV(CLK_DIV_SPI1_ISP, "div_spi1_isp", "mout_spi1_isp", DIV_ISP, 16, 4), | 431 | DIV(CLK_DIV_SPI1_ISP, "div_spi1_isp", "mout_spi1_isp", DIV_ISP, 16, 4), |
424 | DIV_F(CLK_DIV_SPI0_ISP_PRE, "div_spi0_isp_pre", "div_spi0_isp", | 432 | DIV_F(CLK_DIV_SPI0_ISP_PRE, "div_spi0_isp_pre", "div_spi0_isp", |
425 | DIV_ISP, 8, 8, CLK_SET_RATE_PARENT, 0), | 433 | DIV_ISP, 8, 8, CLK_SET_RATE_PARENT, 0), |
426 | DIV(CLK_DIV_SPI0_ISP, "div_spi0_isp", "mout_spi0_isp", DIV_ISP, 0, 4), | 434 | DIV(CLK_DIV_SPI0_ISP, "div_spi0_isp", "mout_spi0_isp", DIV_ISP, 4, 4), |
427 | 435 | ||
428 | /* DIV_FSYS0 */ | 436 | /* DIV_FSYS0 */ |
429 | DIV_F(CLK_DIV_TSADC_PRE, "div_tsadc_pre", "div_tsadc", DIV_FSYS0, 8, 8, | 437 | DIV_F(CLK_DIV_TSADC_PRE, "div_tsadc_pre", "div_tsadc", DIV_FSYS0, 8, 8, |
@@ -724,6 +732,25 @@ static struct samsung_pll_rate_table exynos3250_pll_rates[] = { | |||
724 | { /* sentinel */ } | 732 | { /* sentinel */ } |
725 | }; | 733 | }; |
726 | 734 | ||
735 | /* EPLL */ | ||
736 | static struct samsung_pll_rate_table exynos3250_epll_rates[] = { | ||
737 | PLL_36XX_RATE(800000000, 200, 3, 1, 0), | ||
738 | PLL_36XX_RATE(288000000, 96, 2, 2, 0), | ||
739 | PLL_36XX_RATE(192000000, 128, 2, 3, 0), | ||
740 | PLL_36XX_RATE(144000000, 96, 2, 3, 0), | ||
741 | PLL_36XX_RATE( 96000000, 128, 2, 4, 0), | ||
742 | PLL_36XX_RATE( 84000000, 112, 2, 4, 0), | ||
743 | PLL_36XX_RATE( 80000004, 106, 2, 4, 43691), | ||
744 | PLL_36XX_RATE( 73728000, 98, 2, 4, 19923), | ||
745 | PLL_36XX_RATE( 67737598, 270, 3, 5, 62285), | ||
746 | PLL_36XX_RATE( 65535999, 174, 2, 5, 49982), | ||
747 | PLL_36XX_RATE( 50000000, 200, 3, 5, 0), | ||
748 | PLL_36XX_RATE( 49152002, 131, 2, 5, 4719), | ||
749 | PLL_36XX_RATE( 48000000, 128, 2, 5, 0), | ||
750 | PLL_36XX_RATE( 45158401, 180, 3, 5, 41524), | ||
751 | { /* sentinel */ } | ||
752 | }; | ||
753 | |||
727 | /* VPLL */ | 754 | /* VPLL */ |
728 | static struct samsung_pll_rate_table exynos3250_vpll_rates[] = { | 755 | static struct samsung_pll_rate_table exynos3250_vpll_rates[] = { |
729 | PLL_36XX_RATE(600000000, 100, 2, 1, 0), | 756 | PLL_36XX_RATE(600000000, 100, 2, 1, 0), |
@@ -821,3 +848,172 @@ static void __init exynos3250_cmu_init(struct device_node *np) | |||
821 | samsung_clk_of_add_provider(np, ctx); | 848 | samsung_clk_of_add_provider(np, ctx); |
822 | } | 849 | } |
823 | CLK_OF_DECLARE(exynos3250_cmu, "samsung,exynos3250-cmu", exynos3250_cmu_init); | 850 | CLK_OF_DECLARE(exynos3250_cmu, "samsung,exynos3250-cmu", exynos3250_cmu_init); |
851 | |||
852 | /* | ||
853 | * CMU DMC | ||
854 | */ | ||
855 | |||
856 | #define BPLL_LOCK 0x0118 | ||
857 | #define BPLL_CON0 0x0218 | ||
858 | #define BPLL_CON1 0x021c | ||
859 | #define BPLL_CON2 0x0220 | ||
860 | #define SRC_DMC 0x0300 | ||
861 | #define DIV_DMC1 0x0504 | ||
862 | #define GATE_BUS_DMC0 0x0700 | ||
863 | #define GATE_BUS_DMC1 0x0704 | ||
864 | #define GATE_BUS_DMC2 0x0708 | ||
865 | #define GATE_BUS_DMC3 0x070c | ||
866 | #define GATE_SCLK_DMC 0x0800 | ||
867 | #define GATE_IP_DMC0 0x0900 | ||
868 | #define GATE_IP_DMC1 0x0904 | ||
869 | #define EPLL_LOCK 0x1110 | ||
870 | #define EPLL_CON0 0x1114 | ||
871 | #define EPLL_CON1 0x1118 | ||
872 | #define EPLL_CON2 0x111c | ||
873 | #define SRC_EPLL 0x1120 | ||
874 | |||
875 | /* | ||
876 | * Support for CMU save/restore across system suspends | ||
877 | */ | ||
878 | #ifdef CONFIG_PM_SLEEP | ||
879 | static struct samsung_clk_reg_dump *exynos3250_dmc_clk_regs; | ||
880 | |||
881 | static unsigned long exynos3250_cmu_dmc_clk_regs[] __initdata = { | ||
882 | BPLL_LOCK, | ||
883 | BPLL_CON0, | ||
884 | BPLL_CON1, | ||
885 | BPLL_CON2, | ||
886 | SRC_DMC, | ||
887 | DIV_DMC1, | ||
888 | GATE_BUS_DMC0, | ||
889 | GATE_BUS_DMC1, | ||
890 | GATE_BUS_DMC2, | ||
891 | GATE_BUS_DMC3, | ||
892 | GATE_SCLK_DMC, | ||
893 | GATE_IP_DMC0, | ||
894 | GATE_IP_DMC1, | ||
895 | EPLL_LOCK, | ||
896 | EPLL_CON0, | ||
897 | EPLL_CON1, | ||
898 | EPLL_CON2, | ||
899 | SRC_EPLL, | ||
900 | }; | ||
901 | |||
902 | static int exynos3250_dmc_clk_suspend(void) | ||
903 | { | ||
904 | samsung_clk_save(dmc_reg_base, exynos3250_dmc_clk_regs, | ||
905 | ARRAY_SIZE(exynos3250_cmu_dmc_clk_regs)); | ||
906 | return 0; | ||
907 | } | ||
908 | |||
909 | static void exynos3250_dmc_clk_resume(void) | ||
910 | { | ||
911 | samsung_clk_restore(dmc_reg_base, exynos3250_dmc_clk_regs, | ||
912 | ARRAY_SIZE(exynos3250_cmu_dmc_clk_regs)); | ||
913 | } | ||
914 | |||
915 | static struct syscore_ops exynos3250_dmc_clk_syscore_ops = { | ||
916 | .suspend = exynos3250_dmc_clk_suspend, | ||
917 | .resume = exynos3250_dmc_clk_resume, | ||
918 | }; | ||
919 | |||
920 | static void exynos3250_dmc_clk_sleep_init(void) | ||
921 | { | ||
922 | exynos3250_dmc_clk_regs = | ||
923 | samsung_clk_alloc_reg_dump(exynos3250_cmu_dmc_clk_regs, | ||
924 | ARRAY_SIZE(exynos3250_cmu_dmc_clk_regs)); | ||
925 | if (!exynos3250_dmc_clk_regs) { | ||
926 | pr_warn("%s: Failed to allocate sleep save data\n", __func__); | ||
927 | goto err; | ||
928 | } | ||
929 | |||
930 | register_syscore_ops(&exynos3250_dmc_clk_syscore_ops); | ||
931 | return; | ||
932 | err: | ||
933 | kfree(exynos3250_dmc_clk_regs); | ||
934 | } | ||
935 | #else | ||
936 | static inline void exynos3250_dmc_clk_sleep_init(void) { } | ||
937 | #endif | ||
938 | |||
939 | PNAME(mout_epll_p) = { "fin_pll", "fout_epll", }; | ||
940 | PNAME(mout_bpll_p) = { "fin_pll", "fout_bpll", }; | ||
941 | PNAME(mout_mpll_mif_p) = { "fin_pll", "sclk_mpll_mif", }; | ||
942 | PNAME(mout_dphy_p) = { "mout_mpll_mif", "mout_bpll", }; | ||
943 | |||
944 | static struct samsung_mux_clock dmc_mux_clks[] __initdata = { | ||
945 | /* | ||
946 | * NOTE: Following table is sorted by register address in ascending | ||
947 | * order and then bitfield shift in descending order, as it is done | ||
948 | * in the User's Manual. When adding new entries, please make sure | ||
949 | * that the order is preserved, to avoid merge conflicts and make | ||
950 | * further work with defined data easier. | ||
951 | */ | ||
952 | |||
953 | /* SRC_DMC */ | ||
954 | MUX(CLK_MOUT_MPLL_MIF, "mout_mpll_mif", mout_mpll_mif_p, SRC_DMC, 12, 1), | ||
955 | MUX(CLK_MOUT_BPLL, "mout_bpll", mout_bpll_p, SRC_DMC, 10, 1), | ||
956 | MUX(CLK_MOUT_DPHY, "mout_dphy", mout_dphy_p, SRC_DMC, 8, 1), | ||
957 | MUX(CLK_MOUT_DMC_BUS, "mout_dmc_bus", mout_dphy_p, SRC_DMC, 4, 1), | ||
958 | |||
959 | /* SRC_EPLL */ | ||
960 | MUX(CLK_MOUT_EPLL, "mout_epll", mout_epll_p, SRC_EPLL, 4, 1), | ||
961 | }; | ||
962 | |||
963 | static struct samsung_div_clock dmc_div_clks[] __initdata = { | ||
964 | /* | ||
965 | * NOTE: Following table is sorted by register address in ascending | ||
966 | * order and then bitfield shift in descending order, as it is done | ||
967 | * in the User's Manual. When adding new entries, please make sure | ||
968 | * that the order is preserved, to avoid merge conflicts and make | ||
969 | * further work with defined data easier. | ||
970 | */ | ||
971 | |||
972 | /* DIV_DMC1 */ | ||
973 | DIV(CLK_DIV_DMC, "div_dmc", "div_dmc_pre", DIV_DMC1, 27, 3), | ||
974 | DIV(CLK_DIV_DPHY, "div_dphy", "mout_dphy", DIV_DMC1, 23, 3), | ||
975 | DIV(CLK_DIV_DMC_PRE, "div_dmc_pre", "mout_dmc_bus", DIV_DMC1, 19, 2), | ||
976 | DIV(CLK_DIV_DMCP, "div_dmcp", "div_dmcd", DIV_DMC1, 15, 3), | ||
977 | DIV(CLK_DIV_DMCD, "div_dmcd", "div_dmc", DIV_DMC1, 11, 3), | ||
978 | }; | ||
979 | |||
980 | static struct samsung_pll_clock exynos3250_dmc_plls[nr_dmc_plls] __initdata = { | ||
981 | [bpll] = PLL(pll_35xx, CLK_FOUT_BPLL, "fout_bpll", "fin_pll", | ||
982 | BPLL_LOCK, BPLL_CON0, NULL), | ||
983 | [epll] = PLL(pll_36xx, CLK_FOUT_EPLL, "fout_epll", "fin_pll", | ||
984 | EPLL_LOCK, EPLL_CON0, NULL), | ||
985 | }; | ||
986 | |||
987 | static void __init exynos3250_cmu_dmc_init(struct device_node *np) | ||
988 | { | ||
989 | struct samsung_clk_provider *ctx; | ||
990 | |||
991 | dmc_reg_base = of_iomap(np, 0); | ||
992 | if (!dmc_reg_base) | ||
993 | panic("%s: failed to map registers\n", __func__); | ||
994 | |||
995 | ctx = samsung_clk_init(np, dmc_reg_base, NR_CLKS_DMC); | ||
996 | if (!ctx) | ||
997 | panic("%s: unable to allocate context.\n", __func__); | ||
998 | |||
999 | exynos3250_dmc_plls[bpll].rate_table = exynos3250_pll_rates; | ||
1000 | exynos3250_dmc_plls[epll].rate_table = exynos3250_epll_rates; | ||
1001 | |||
1002 | pr_err("CLK registering epll bpll: %d, %d, %d, %d\n", | ||
1003 | exynos3250_dmc_plls[bpll].rate_table[0].rate, | ||
1004 | exynos3250_dmc_plls[bpll].rate_table[0].mdiv, | ||
1005 | exynos3250_dmc_plls[bpll].rate_table[0].pdiv, | ||
1006 | exynos3250_dmc_plls[bpll].rate_table[0].sdiv | ||
1007 | ); | ||
1008 | samsung_clk_register_pll(ctx, exynos3250_dmc_plls, | ||
1009 | ARRAY_SIZE(exynos3250_dmc_plls), dmc_reg_base); | ||
1010 | |||
1011 | samsung_clk_register_mux(ctx, dmc_mux_clks, ARRAY_SIZE(dmc_mux_clks)); | ||
1012 | samsung_clk_register_div(ctx, dmc_div_clks, ARRAY_SIZE(dmc_div_clks)); | ||
1013 | |||
1014 | exynos3250_dmc_clk_sleep_init(); | ||
1015 | |||
1016 | samsung_clk_of_add_provider(np, ctx); | ||
1017 | } | ||
1018 | CLK_OF_DECLARE(exynos3250_cmu_dmc, "samsung,exynos3250-cmu-dmc", | ||
1019 | exynos3250_cmu_dmc_init); | ||
diff --git a/drivers/clk/samsung/clk-exynos4.c b/drivers/clk/samsung/clk-exynos4.c index ac163d7f5bc3..940f02837b82 100644 --- a/drivers/clk/samsung/clk-exynos4.c +++ b/drivers/clk/samsung/clk-exynos4.c | |||
@@ -517,7 +517,7 @@ static struct samsung_fixed_factor_clock exynos4_fixed_factor_clks[] __initdata | |||
517 | FFACTOR(0, "sclk_apll_div_2", "sclk_apll", 1, 2, 0), | 517 | FFACTOR(0, "sclk_apll_div_2", "sclk_apll", 1, 2, 0), |
518 | FFACTOR(0, "fout_mpll_div_2", "fout_mpll", 1, 2, 0), | 518 | FFACTOR(0, "fout_mpll_div_2", "fout_mpll", 1, 2, 0), |
519 | FFACTOR(0, "fout_apll_div_2", "fout_apll", 1, 2, 0), | 519 | FFACTOR(0, "fout_apll_div_2", "fout_apll", 1, 2, 0), |
520 | FFACTOR(0, "arm_clk_div_2", "arm_clk", 1, 2, 0), | 520 | FFACTOR(0, "arm_clk_div_2", "div_core2", 1, 2, 0), |
521 | }; | 521 | }; |
522 | 522 | ||
523 | static struct samsung_fixed_factor_clock exynos4210_fixed_factor_clks[] __initdata = { | 523 | static struct samsung_fixed_factor_clock exynos4210_fixed_factor_clks[] __initdata = { |
@@ -535,7 +535,7 @@ static struct samsung_fixed_factor_clock exynos4x12_fixed_factor_clks[] __initda | |||
535 | static struct samsung_mux_clock exynos4_mux_clks[] __initdata = { | 535 | static struct samsung_mux_clock exynos4_mux_clks[] __initdata = { |
536 | MUX_FA(CLK_MOUT_APLL, "mout_apll", mout_apll_p, SRC_CPU, 0, 1, | 536 | MUX_FA(CLK_MOUT_APLL, "mout_apll", mout_apll_p, SRC_CPU, 0, 1, |
537 | CLK_SET_RATE_PARENT, 0, "mout_apll"), | 537 | CLK_SET_RATE_PARENT, 0, "mout_apll"), |
538 | MUX(0, "mout_hdmi", mout_hdmi_p, SRC_TV, 0, 1), | 538 | MUX(CLK_MOUT_HDMI, "mout_hdmi", mout_hdmi_p, SRC_TV, 0, 1), |
539 | MUX(0, "mout_mfc1", sclk_evpll_p, SRC_MFC, 4, 1), | 539 | MUX(0, "mout_mfc1", sclk_evpll_p, SRC_MFC, 4, 1), |
540 | MUX(0, "mout_mfc", mout_mfc_p, SRC_MFC, 8, 1), | 540 | MUX(0, "mout_mfc", mout_mfc_p, SRC_MFC, 8, 1), |
541 | MUX_F(CLK_MOUT_G3D1, "mout_g3d1", sclk_evpll_p, SRC_G3D, 4, 1, | 541 | MUX_F(CLK_MOUT_G3D1, "mout_g3d1", sclk_evpll_p, SRC_G3D, 4, 1, |
@@ -569,7 +569,7 @@ static struct samsung_mux_clock exynos4210_mux_clks[] __initdata = { | |||
569 | MUX(0, "mout_aclk100", sclk_ampll_p4210, SRC_TOP0, 16, 1), | 569 | MUX(0, "mout_aclk100", sclk_ampll_p4210, SRC_TOP0, 16, 1), |
570 | MUX(0, "mout_aclk160", sclk_ampll_p4210, SRC_TOP0, 20, 1), | 570 | MUX(0, "mout_aclk160", sclk_ampll_p4210, SRC_TOP0, 20, 1), |
571 | MUX(0, "mout_aclk133", sclk_ampll_p4210, SRC_TOP0, 24, 1), | 571 | MUX(0, "mout_aclk133", sclk_ampll_p4210, SRC_TOP0, 24, 1), |
572 | MUX(0, "mout_mixer", mout_mixer_p4210, SRC_TV, 4, 1), | 572 | MUX(CLK_MOUT_MIXER, "mout_mixer", mout_mixer_p4210, SRC_TV, 4, 1), |
573 | MUX(0, "mout_dac", mout_dac_p4210, SRC_TV, 8, 1), | 573 | MUX(0, "mout_dac", mout_dac_p4210, SRC_TV, 8, 1), |
574 | MUX(0, "mout_g2d0", sclk_ampll_p4210, E4210_SRC_IMAGE, 0, 1), | 574 | MUX(0, "mout_g2d0", sclk_ampll_p4210, E4210_SRC_IMAGE, 0, 1), |
575 | MUX(0, "mout_g2d1", sclk_evpll_p, E4210_SRC_IMAGE, 4, 1), | 575 | MUX(0, "mout_g2d1", sclk_evpll_p, E4210_SRC_IMAGE, 4, 1), |
@@ -719,7 +719,7 @@ static struct samsung_div_clock exynos4_div_clks[] __initdata = { | |||
719 | DIV(0, "div_periph", "div_core2", DIV_CPU0, 12, 3), | 719 | DIV(0, "div_periph", "div_core2", DIV_CPU0, 12, 3), |
720 | DIV(0, "div_atb", "mout_core", DIV_CPU0, 16, 3), | 720 | DIV(0, "div_atb", "mout_core", DIV_CPU0, 16, 3), |
721 | DIV(0, "div_pclk_dbg", "div_atb", DIV_CPU0, 20, 3), | 721 | DIV(0, "div_pclk_dbg", "div_atb", DIV_CPU0, 20, 3), |
722 | DIV(0, "div_core2", "div_core", DIV_CPU0, 28, 3), | 722 | DIV(CLK_ARM_CLK, "div_core2", "div_core", DIV_CPU0, 28, 3), |
723 | DIV(0, "div_copy", "mout_hpm", DIV_CPU1, 0, 3), | 723 | DIV(0, "div_copy", "mout_hpm", DIV_CPU1, 0, 3), |
724 | DIV(0, "div_hpm", "div_copy", DIV_CPU1, 4, 3), | 724 | DIV(0, "div_hpm", "div_copy", DIV_CPU1, 4, 3), |
725 | DIV(0, "div_clkout_cpu", "mout_clkout_cpu", CLKOUT_CMU_CPU, 8, 6), | 725 | DIV(0, "div_clkout_cpu", "mout_clkout_cpu", CLKOUT_CMU_CPU, 8, 6), |
@@ -733,8 +733,7 @@ static struct samsung_div_clock exynos4_div_clks[] __initdata = { | |||
733 | DIV(0, "div_csis0", "mout_csis0", DIV_CAM, 24, 4), | 733 | DIV(0, "div_csis0", "mout_csis0", DIV_CAM, 24, 4), |
734 | DIV(0, "div_csis1", "mout_csis1", DIV_CAM, 28, 4), | 734 | DIV(0, "div_csis1", "mout_csis1", DIV_CAM, 28, 4), |
735 | DIV(CLK_SCLK_MFC, "sclk_mfc", "mout_mfc", DIV_MFC, 0, 4), | 735 | DIV(CLK_SCLK_MFC, "sclk_mfc", "mout_mfc", DIV_MFC, 0, 4), |
736 | DIV_F(0, "div_g3d", "mout_g3d", DIV_G3D, 0, 4, | 736 | DIV(CLK_SCLK_G3D, "sclk_g3d", "mout_g3d", DIV_G3D, 0, 4), |
737 | CLK_SET_RATE_PARENT, 0), | ||
738 | DIV(0, "div_fimd0", "mout_fimd0", DIV_LCD0, 0, 4), | 737 | DIV(0, "div_fimd0", "mout_fimd0", DIV_LCD0, 0, 4), |
739 | DIV(0, "div_mipi0", "mout_mipi0", DIV_LCD0, 16, 4), | 738 | DIV(0, "div_mipi0", "mout_mipi0", DIV_LCD0, 16, 4), |
740 | DIV(0, "div_audio0", "mout_audio0", DIV_MAUDIO, 0, 4), | 739 | DIV(0, "div_audio0", "mout_audio0", DIV_MAUDIO, 0, 4), |
@@ -769,7 +768,6 @@ static struct samsung_div_clock exynos4_div_clks[] __initdata = { | |||
769 | DIV(0, "div_spi_pre2", "div_spi2", DIV_PERIL2, 8, 8), | 768 | DIV(0, "div_spi_pre2", "div_spi2", DIV_PERIL2, 8, 8), |
770 | DIV(0, "div_audio1", "mout_audio1", DIV_PERIL4, 0, 4), | 769 | DIV(0, "div_audio1", "mout_audio1", DIV_PERIL4, 0, 4), |
771 | DIV(0, "div_audio2", "mout_audio2", DIV_PERIL4, 16, 4), | 770 | DIV(0, "div_audio2", "mout_audio2", DIV_PERIL4, 16, 4), |
772 | DIV(CLK_ARM_CLK, "arm_clk", "div_core2", DIV_CPU0, 28, 3), | ||
773 | DIV(CLK_SCLK_APLL, "sclk_apll", "mout_apll", DIV_CPU0, 24, 3), | 771 | DIV(CLK_SCLK_APLL, "sclk_apll", "mout_apll", DIV_CPU0, 24, 3), |
774 | DIV_F(0, "div_mipi_pre0", "div_mipi0", DIV_LCD0, 20, 4, | 772 | DIV_F(0, "div_mipi_pre0", "div_mipi0", DIV_LCD0, 20, 4, |
775 | CLK_SET_RATE_PARENT, 0), | 773 | CLK_SET_RATE_PARENT, 0), |
@@ -857,8 +855,7 @@ static struct samsung_gate_clock exynos4_gate_clks[] __initdata = { | |||
857 | 0), | 855 | 0), |
858 | GATE(CLK_TSI, "tsi", "aclk133", GATE_IP_FSYS, 4, 0, 0), | 856 | GATE(CLK_TSI, "tsi", "aclk133", GATE_IP_FSYS, 4, 0, 0), |
859 | GATE(CLK_SROMC, "sromc", "aclk133", GATE_IP_FSYS, 11, 0, 0), | 857 | GATE(CLK_SROMC, "sromc", "aclk133", GATE_IP_FSYS, 11, 0, 0), |
860 | GATE(CLK_SCLK_G3D, "sclk_g3d", "div_g3d", GATE_IP_G3D, 0, | 858 | GATE(CLK_G3D, "g3d", "aclk200", GATE_IP_G3D, 0, 0, 0), |
861 | CLK_SET_RATE_PARENT, 0), | ||
862 | GATE(CLK_PPMUG3D, "ppmug3d", "aclk200", GATE_IP_G3D, 1, 0, 0), | 859 | GATE(CLK_PPMUG3D, "ppmug3d", "aclk200", GATE_IP_G3D, 1, 0, 0), |
863 | GATE(CLK_USB_DEVICE, "usb_device", "aclk133", GATE_IP_FSYS, 13, 0, 0), | 860 | GATE(CLK_USB_DEVICE, "usb_device", "aclk133", GATE_IP_FSYS, 13, 0, 0), |
864 | GATE(CLK_ONENAND, "onenand", "aclk133", GATE_IP_FSYS, 15, 0, 0), | 861 | GATE(CLK_ONENAND, "onenand", "aclk133", GATE_IP_FSYS, 15, 0, 0), |
@@ -1183,6 +1180,7 @@ static struct samsung_gate_clock exynos4x12_gate_clks[] __initdata = { | |||
1183 | GATE(CLK_SPI1_ISP, "spi1_isp", "aclk200", E4X12_GATE_ISP1, 13, | 1180 | GATE(CLK_SPI1_ISP, "spi1_isp", "aclk200", E4X12_GATE_ISP1, 13, |
1184 | CLK_IGNORE_UNUSED | CLK_GET_RATE_NOCACHE, 0), | 1181 | CLK_IGNORE_UNUSED | CLK_GET_RATE_NOCACHE, 0), |
1185 | GATE(CLK_G2D, "g2d", "aclk200", GATE_IP_DMC, 23, 0, 0), | 1182 | GATE(CLK_G2D, "g2d", "aclk200", GATE_IP_DMC, 23, 0, 0), |
1183 | GATE(CLK_SMMU_G2D, "smmu_g2d", "aclk200", GATE_IP_DMC, 24, 0, 0), | ||
1186 | GATE(CLK_TMU_APBIF, "tmu_apbif", "aclk100", E4X12_GATE_IP_PERIR, 17, 0, | 1184 | GATE(CLK_TMU_APBIF, "tmu_apbif", "aclk100", E4X12_GATE_IP_PERIR, 17, 0, |
1187 | 0), | 1185 | 0), |
1188 | }; | 1186 | }; |
@@ -1486,7 +1484,7 @@ static void __init exynos4_clk_init(struct device_node *np, | |||
1486 | exynos4_soc == EXYNOS4210 ? "Exynos4210" : "Exynos4x12", | 1484 | exynos4_soc == EXYNOS4210 ? "Exynos4210" : "Exynos4x12", |
1487 | _get_rate("sclk_apll"), _get_rate("sclk_mpll"), | 1485 | _get_rate("sclk_apll"), _get_rate("sclk_mpll"), |
1488 | _get_rate("sclk_epll"), _get_rate("sclk_vpll"), | 1486 | _get_rate("sclk_epll"), _get_rate("sclk_vpll"), |
1489 | _get_rate("arm_clk")); | 1487 | _get_rate("div_core2")); |
1490 | } | 1488 | } |
1491 | 1489 | ||
1492 | 1490 | ||
diff --git a/drivers/clk/samsung/clk-exynos5260.c b/drivers/clk/samsung/clk-exynos5260.c index ce3de97e5f11..2527e39aadcf 100644 --- a/drivers/clk/samsung/clk-exynos5260.c +++ b/drivers/clk/samsung/clk-exynos5260.c | |||
@@ -1581,7 +1581,7 @@ struct samsung_fixed_rate_clock fixed_rate_clks[] __initdata = { | |||
1581 | FRATE(PHYCLK_HDMI_LINK_O_TMDS_CLKHI, "phyclk_hdmi_link_o_tmds_clkhi", | 1581 | FRATE(PHYCLK_HDMI_LINK_O_TMDS_CLKHI, "phyclk_hdmi_link_o_tmds_clkhi", |
1582 | NULL, CLK_IS_ROOT, 125000000), | 1582 | NULL, CLK_IS_ROOT, 125000000), |
1583 | FRATE(PHYCLK_MIPI_DPHY_4L_M_TXBYTECLKHS, | 1583 | FRATE(PHYCLK_MIPI_DPHY_4L_M_TXBYTECLKHS, |
1584 | "phyclk_mipi_dphy_4l_m_txbyteclkhs" , NULL, | 1584 | "phyclk_mipi_dphy_4l_m_txbyte_clkhs" , NULL, |
1585 | CLK_IS_ROOT, 187500000), | 1585 | CLK_IS_ROOT, 187500000), |
1586 | FRATE(PHYCLK_DPTX_PHY_O_REF_CLK_24M, "phyclk_dptx_phy_o_ref_clk_24m", | 1586 | FRATE(PHYCLK_DPTX_PHY_O_REF_CLK_24M, "phyclk_dptx_phy_o_ref_clk_24m", |
1587 | NULL, CLK_IS_ROOT, 24000000), | 1587 | NULL, CLK_IS_ROOT, 24000000), |