aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-exynos
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2012-07-30 12:45:53 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2012-07-30 12:45:53 -0400
commitb7574a22a24c9417ae4cc416785556bad0a0a371 (patch)
treecdd9722f1eca326e16fa840479469e0023c7be39 /arch/arm/mach-exynos
parent148b729b9f51a78c1a024369bdcdc592f01103d4 (diff)
parent537cd80cea370c530d455bc8e00ef0673ba165cb (diff)
Merge tag 'soc2' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc
Pull arm-soc soc updates from Olof Johansson: "This is the second batch of SoC updates for the 3.6 merge window, containing parts that arrived close to the merge window opening and thus needed to sit in linux-next for a while. Most contents is updates of Renesas shmobile, with a couple of Samsung Exynos patches in the mix." * tag 'soc2' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (39 commits) ARM: S3C64XX: Add header file protection macros in pm-core.h [CPUFREQ] EXYNOS5250: Add support max 1.7GHz for EXYNOS5250 ARM: EXYNOS: Add G2D related clock entries for SMDK4X12 ARM: EXYNOS: Move G2D clock entries to clock-exynos4210.c file ARM: shmobile: Fix build problem in pm-sh7372.c for unusual .config ARM: shmobile: Take cpuidle dependencies into account correctly ARM: mach-shmobile: sh7377 generic board support via DT ARM: mach-shmobile: r8a7740 generic board support via DT ARM: shmobile: sh7372: completely switch over to using pm-rmobile API ARM: shmobile: ap4evb: switch to using pm-rmobile API ARM: shmobile: mackerel: switch to using pm-rmobile API ARM: shmobile: sh7372: add pm-rmobile domain support ARM: shmobile: r8a7740: add A4LC pm domain support ARM: shmobile: r8a7740: add A3SP pm domain support ARM: shmobile: r8a7740: add A4S pm domain support ARM: shmobile: r8a7740: fixup: MSEL1CR 7bit control ARM: shmobile: soc-core: add R-mobile PM domain common APIs ARM: shmobile: sh7372 A3SM CPUIdle support ARM: shmobile: Use INTCA with sh7372 A3SM power domain ARM: mach-shmobile: Convert sh_clk_mstp32_register to sh_clk_mstp_register ...
Diffstat (limited to 'arch/arm/mach-exynos')
-rw-r--r--arch/arm/mach-exynos/clock-exynos4.c41
-rw-r--r--arch/arm/mach-exynos/clock-exynos4.h3
-rw-r--r--arch/arm/mach-exynos/clock-exynos4210.c37
-rw-r--r--arch/arm/mach-exynos/clock-exynos4212.c41
4 files changed, 81 insertions, 41 deletions
diff --git a/arch/arm/mach-exynos/clock-exynos4.c b/arch/arm/mach-exynos/clock-exynos4.c
index 26fe9de35ecb..2f51293c1875 100644
--- a/arch/arm/mach-exynos/clock-exynos4.c
+++ b/arch/arm/mach-exynos/clock-exynos4.c
@@ -620,10 +620,6 @@ static struct clk exynos4_init_clocks_off[] = {
620 .enable = exynos4_clk_ip_peril_ctrl, 620 .enable = exynos4_clk_ip_peril_ctrl,
621 .ctrlbit = (1 << 27), 621 .ctrlbit = (1 << 27),
622 }, { 622 }, {
623 .name = "fimg2d",
624 .enable = exynos4_clk_ip_image_ctrl,
625 .ctrlbit = (1 << 0),
626 }, {
627 .name = "mfc", 623 .name = "mfc",
628 .devname = "s5p-mfc", 624 .devname = "s5p-mfc",
629 .enable = exynos4_clk_ip_mfc_ctrl, 625 .enable = exynos4_clk_ip_mfc_ctrl,
@@ -819,47 +815,21 @@ static struct clk *exynos4_clkset_mout_g2d0_list[] = {
819 [1] = &exynos4_clk_sclk_apll.clk, 815 [1] = &exynos4_clk_sclk_apll.clk,
820}; 816};
821 817
822static struct clksrc_sources exynos4_clkset_mout_g2d0 = { 818struct clksrc_sources exynos4_clkset_mout_g2d0 = {
823 .sources = exynos4_clkset_mout_g2d0_list, 819 .sources = exynos4_clkset_mout_g2d0_list,
824 .nr_sources = ARRAY_SIZE(exynos4_clkset_mout_g2d0_list), 820 .nr_sources = ARRAY_SIZE(exynos4_clkset_mout_g2d0_list),
825}; 821};
826 822
827static struct clksrc_clk exynos4_clk_mout_g2d0 = {
828 .clk = {
829 .name = "mout_g2d0",
830 },
831 .sources = &exynos4_clkset_mout_g2d0,
832 .reg_src = { .reg = EXYNOS4_CLKSRC_IMAGE, .shift = 0, .size = 1 },
833};
834
835static struct clk *exynos4_clkset_mout_g2d1_list[] = { 823static struct clk *exynos4_clkset_mout_g2d1_list[] = {
836 [0] = &exynos4_clk_mout_epll.clk, 824 [0] = &exynos4_clk_mout_epll.clk,
837 [1] = &exynos4_clk_sclk_vpll.clk, 825 [1] = &exynos4_clk_sclk_vpll.clk,
838}; 826};
839 827
840static struct clksrc_sources exynos4_clkset_mout_g2d1 = { 828struct clksrc_sources exynos4_clkset_mout_g2d1 = {
841 .sources = exynos4_clkset_mout_g2d1_list, 829 .sources = exynos4_clkset_mout_g2d1_list,
842 .nr_sources = ARRAY_SIZE(exynos4_clkset_mout_g2d1_list), 830 .nr_sources = ARRAY_SIZE(exynos4_clkset_mout_g2d1_list),
843}; 831};
844 832
845static struct clksrc_clk exynos4_clk_mout_g2d1 = {
846 .clk = {
847 .name = "mout_g2d1",
848 },
849 .sources = &exynos4_clkset_mout_g2d1,
850 .reg_src = { .reg = EXYNOS4_CLKSRC_IMAGE, .shift = 4, .size = 1 },
851};
852
853static struct clk *exynos4_clkset_mout_g2d_list[] = {
854 [0] = &exynos4_clk_mout_g2d0.clk,
855 [1] = &exynos4_clk_mout_g2d1.clk,
856};
857
858static struct clksrc_sources exynos4_clkset_mout_g2d = {
859 .sources = exynos4_clkset_mout_g2d_list,
860 .nr_sources = ARRAY_SIZE(exynos4_clkset_mout_g2d_list),
861};
862
863static struct clk *exynos4_clkset_mout_mfc0_list[] = { 833static struct clk *exynos4_clkset_mout_mfc0_list[] = {
864 [0] = &exynos4_clk_mout_mpll.clk, 834 [0] = &exynos4_clk_mout_mpll.clk,
865 [1] = &exynos4_clk_sclk_apll.clk, 835 [1] = &exynos4_clk_sclk_apll.clk,
@@ -1126,13 +1096,6 @@ static struct clksrc_clk exynos4_clksrcs[] = {
1126 .reg_div = { .reg = EXYNOS4_CLKDIV_LCD0, .shift = 0, .size = 4 }, 1096 .reg_div = { .reg = EXYNOS4_CLKDIV_LCD0, .shift = 0, .size = 4 },
1127 }, { 1097 }, {
1128 .clk = { 1098 .clk = {
1129 .name = "sclk_fimg2d",
1130 },
1131 .sources = &exynos4_clkset_mout_g2d,
1132 .reg_src = { .reg = EXYNOS4_CLKSRC_IMAGE, .shift = 8, .size = 1 },
1133 .reg_div = { .reg = EXYNOS4_CLKDIV_IMAGE, .shift = 0, .size = 4 },
1134 }, {
1135 .clk = {
1136 .name = "sclk_mfc", 1099 .name = "sclk_mfc",
1137 .devname = "s5p-mfc", 1100 .devname = "s5p-mfc",
1138 }, 1101 },
diff --git a/arch/arm/mach-exynos/clock-exynos4.h b/arch/arm/mach-exynos/clock-exynos4.h
index 28a119701182..bd12d5f8b63d 100644
--- a/arch/arm/mach-exynos/clock-exynos4.h
+++ b/arch/arm/mach-exynos/clock-exynos4.h
@@ -23,6 +23,9 @@ extern struct clksrc_sources exynos4_clkset_group;
23extern struct clk *exynos4_clkset_aclk_top_list[]; 23extern struct clk *exynos4_clkset_aclk_top_list[];
24extern struct clk *exynos4_clkset_group_list[]; 24extern struct clk *exynos4_clkset_group_list[];
25 25
26extern struct clksrc_sources exynos4_clkset_mout_g2d0;
27extern struct clksrc_sources exynos4_clkset_mout_g2d1;
28
26extern int exynos4_clksrc_mask_fsys_ctrl(struct clk *clk, int enable); 29extern int exynos4_clksrc_mask_fsys_ctrl(struct clk *clk, int enable);
27extern int exynos4_clk_ip_fsys_ctrl(struct clk *clk, int enable); 30extern int exynos4_clk_ip_fsys_ctrl(struct clk *clk, int enable);
28extern int exynos4_clk_ip_lcd1_ctrl(struct clk *clk, int enable); 31extern int exynos4_clk_ip_lcd1_ctrl(struct clk *clk, int enable);
diff --git a/arch/arm/mach-exynos/clock-exynos4210.c b/arch/arm/mach-exynos/clock-exynos4210.c
index b8689ff60baf..fed4c26e9dad 100644
--- a/arch/arm/mach-exynos/clock-exynos4210.c
+++ b/arch/arm/mach-exynos/clock-exynos4210.c
@@ -48,6 +48,32 @@ static struct clksrc_clk *sysclks[] = {
48 /* nothing here yet */ 48 /* nothing here yet */
49}; 49};
50 50
51static struct clksrc_clk exynos4210_clk_mout_g2d0 = {
52 .clk = {
53 .name = "mout_g2d0",
54 },
55 .sources = &exynos4_clkset_mout_g2d0,
56 .reg_src = { .reg = EXYNOS4_CLKSRC_IMAGE, .shift = 0, .size = 1 },
57};
58
59static struct clksrc_clk exynos4210_clk_mout_g2d1 = {
60 .clk = {
61 .name = "mout_g2d1",
62 },
63 .sources = &exynos4_clkset_mout_g2d1,
64 .reg_src = { .reg = EXYNOS4_CLKSRC_IMAGE, .shift = 4, .size = 1 },
65};
66
67static struct clk *exynos4210_clkset_mout_g2d_list[] = {
68 [0] = &exynos4210_clk_mout_g2d0.clk,
69 [1] = &exynos4210_clk_mout_g2d1.clk,
70};
71
72static struct clksrc_sources exynos4210_clkset_mout_g2d = {
73 .sources = exynos4210_clkset_mout_g2d_list,
74 .nr_sources = ARRAY_SIZE(exynos4210_clkset_mout_g2d_list),
75};
76
51static int exynos4_clksrc_mask_lcd1_ctrl(struct clk *clk, int enable) 77static int exynos4_clksrc_mask_lcd1_ctrl(struct clk *clk, int enable)
52{ 78{
53 return s5p_gatectrl(EXYNOS4210_CLKSRC_MASK_LCD1, clk, enable); 79 return s5p_gatectrl(EXYNOS4210_CLKSRC_MASK_LCD1, clk, enable);
@@ -74,6 +100,13 @@ static struct clksrc_clk clksrcs[] = {
74 .sources = &exynos4_clkset_group, 100 .sources = &exynos4_clkset_group,
75 .reg_src = { .reg = EXYNOS4210_CLKSRC_LCD1, .shift = 0, .size = 4 }, 101 .reg_src = { .reg = EXYNOS4210_CLKSRC_LCD1, .shift = 0, .size = 4 },
76 .reg_div = { .reg = EXYNOS4210_CLKDIV_LCD1, .shift = 0, .size = 4 }, 102 .reg_div = { .reg = EXYNOS4210_CLKDIV_LCD1, .shift = 0, .size = 4 },
103 }, {
104 .clk = {
105 .name = "sclk_fimg2d",
106 },
107 .sources = &exynos4210_clkset_mout_g2d,
108 .reg_src = { .reg = EXYNOS4_CLKSRC_IMAGE, .shift = 8, .size = 1 },
109 .reg_div = { .reg = EXYNOS4_CLKDIV_IMAGE, .shift = 0, .size = 4 },
77 }, 110 },
78}; 111};
79 112
@@ -105,6 +138,10 @@ static struct clk init_clocks_off[] = {
105 .devname = SYSMMU_CLOCK_DEVNAME(fimd1, 11), 138 .devname = SYSMMU_CLOCK_DEVNAME(fimd1, 11),
106 .enable = exynos4_clk_ip_lcd1_ctrl, 139 .enable = exynos4_clk_ip_lcd1_ctrl,
107 .ctrlbit = (1 << 4), 140 .ctrlbit = (1 << 4),
141 }, {
142 .name = "fimg2d",
143 .enable = exynos4_clk_ip_image_ctrl,
144 .ctrlbit = (1 << 0),
108 }, 145 },
109}; 146};
110 147
diff --git a/arch/arm/mach-exynos/clock-exynos4212.c b/arch/arm/mach-exynos/clock-exynos4212.c
index da397d21bbcf..8fba0b5fb8ab 100644
--- a/arch/arm/mach-exynos/clock-exynos4212.c
+++ b/arch/arm/mach-exynos/clock-exynos4212.c
@@ -68,12 +68,45 @@ static struct clksrc_clk clk_mout_mpll_user = {
68 .reg_src = { .reg = EXYNOS4_CLKSRC_CPU, .shift = 24, .size = 1 }, 68 .reg_src = { .reg = EXYNOS4_CLKSRC_CPU, .shift = 24, .size = 1 },
69}; 69};
70 70
71static struct clksrc_clk exynos4x12_clk_mout_g2d0 = {
72 .clk = {
73 .name = "mout_g2d0",
74 },
75 .sources = &exynos4_clkset_mout_g2d0,
76 .reg_src = { .reg = EXYNOS4_CLKSRC_DMC, .shift = 20, .size = 1 },
77};
78
79static struct clksrc_clk exynos4x12_clk_mout_g2d1 = {
80 .clk = {
81 .name = "mout_g2d1",
82 },
83 .sources = &exynos4_clkset_mout_g2d1,
84 .reg_src = { .reg = EXYNOS4_CLKSRC_DMC, .shift = 24, .size = 1 },
85};
86
87static struct clk *exynos4x12_clkset_mout_g2d_list[] = {
88 [0] = &exynos4x12_clk_mout_g2d0.clk,
89 [1] = &exynos4x12_clk_mout_g2d1.clk,
90};
91
92static struct clksrc_sources exynos4x12_clkset_mout_g2d = {
93 .sources = exynos4x12_clkset_mout_g2d_list,
94 .nr_sources = ARRAY_SIZE(exynos4x12_clkset_mout_g2d_list),
95};
96
71static struct clksrc_clk *sysclks[] = { 97static struct clksrc_clk *sysclks[] = {
72 &clk_mout_mpll_user, 98 &clk_mout_mpll_user,
73}; 99};
74 100
75static struct clksrc_clk clksrcs[] = { 101static struct clksrc_clk clksrcs[] = {
76 /* nothing here yet */ 102 {
103 .clk = {
104 .name = "sclk_fimg2d",
105 },
106 .sources = &exynos4x12_clkset_mout_g2d,
107 .reg_src = { .reg = EXYNOS4_CLKSRC_DMC, .shift = 28, .size = 1 },
108 .reg_div = { .reg = EXYNOS4_CLKDIV_DMC1, .shift = 0, .size = 4 },
109 },
77}; 110};
78 111
79static struct clk init_clocks_off[] = { 112static struct clk init_clocks_off[] = {
@@ -102,7 +135,11 @@ static struct clk init_clocks_off[] = {
102 .devname = "exynos-fimc-lite.1", 135 .devname = "exynos-fimc-lite.1",
103 .enable = exynos4212_clk_ip_isp0_ctrl, 136 .enable = exynos4212_clk_ip_isp0_ctrl,
104 .ctrlbit = (1 << 3), 137 .ctrlbit = (1 << 3),
105 } 138 }, {
139 .name = "fimg2d",
140 .enable = exynos4_clk_ip_dmc_ctrl,
141 .ctrlbit = (1 << 23),
142 },
106}; 143};
107 144
108#ifdef CONFIG_PM_SLEEP 145#ifdef CONFIG_PM_SLEEP