diff options
author | Olof Johansson <olof@lixom.net> | 2013-06-12 19:26:33 -0400 |
---|---|---|
committer | Olof Johansson <olof@lixom.net> | 2013-06-12 19:27:21 -0400 |
commit | 1e76c7cb3c1d281be2e452e780e53859abc7c145 (patch) | |
tree | 5199604868c08ab76ea17c860f1f2ab553670360 /drivers/clk | |
parent | 18c0e596791a1014781202a3af649f42a6d8495d (diff) | |
parent | a38089057fa450944f2e2d07885d76fd727c8d16 (diff) |
Merge tag 'exynos-dt-1' of git://git.kernel.org/pub/scm/linux/kernel/git/kgene/linux-samsung into next/dt
From Kukjin Kim:
Update exynos DT for
- usb3phy and dwc3 for exynos5250
- keypad for exynos4412
- TMU clock for exynos4210
- MFC clock for exynos4
- DP controller for exynos5250
- G2D clock for exynos4
- some exynos boards
* tag 'exynos-dt-1' of git://git.kernel.org/pub/scm/linux/kernel/git/kgene/linux-samsung: (456 commits)
ARM: dts: add ohci and ehci controller nodes for EXYNOS5440
ARM: dts: Update G2D documentation for clock entries
ARM: dts: Add clock entries to G2D node for exynos4x12
ARM: dts: Add clock entries to G2D node for exynos4210
ARM: dts: Remove duplicate and add missing G2D nodes
clk: exynos4: Add additional G2D clocks
ARM: dts: Document DP clock in samsung,exynos5-dp binding
ARM: dts: add pin state information for DP HPD support to Exynos5250
ARM: dts: add dts node for the ahci sata exynos5440
ARM: dts: add vmmc regulator support for ODROID-X
ARM: dts: add max77686 node entry for ODROID-X
ARM: dts: Enable RTC by default on EXYNOS5440
ARM: dts: Add display timing node to exynos5250-arndale.dts
ARM: dts: Add clock provider information for DP controller in Exynos5250 SoC
ARM: dts: Add DT node for DP controller for Arndale Board
ARM: dts: Remove combiner IRQ node from exynos4x12.dtsi
ARM: dts: add max8997 device node for exynos4210-origen board
ARM: dts: Enable TMU on Origen4210 board
ARM: dts: Add TMU clock entries to exynos4210.dtsi
ARM: dts: Update MFC documentation for clock entries
...
Signed-off-by: Olof Johansson <olof@lixom.net>
Diffstat (limited to 'drivers/clk')
-rw-r--r-- | drivers/clk/clk-si5351.c | 12 | ||||
-rw-r--r-- | drivers/clk/clk-vt8500.c | 2 | ||||
-rw-r--r-- | drivers/clk/mxs/clk-imx28.c | 1 | ||||
-rw-r--r-- | drivers/clk/samsung/clk-exynos4.c | 15 | ||||
-rw-r--r-- | drivers/clk/ux500/clk-sysctrl.c | 8 | ||||
-rw-r--r-- | drivers/clk/ux500/u8500_clk.c | 2 |
6 files changed, 32 insertions, 8 deletions
diff --git a/drivers/clk/clk-si5351.c b/drivers/clk/clk-si5351.c index 892728412e9d..24f553673b72 100644 --- a/drivers/clk/clk-si5351.c +++ b/drivers/clk/clk-si5351.c | |||
@@ -932,7 +932,7 @@ static unsigned long si5351_clkout_recalc_rate(struct clk_hw *hw, | |||
932 | unsigned char reg; | 932 | unsigned char reg; |
933 | unsigned char rdiv; | 933 | unsigned char rdiv; |
934 | 934 | ||
935 | if (hwdata->num > 5) | 935 | if (hwdata->num <= 5) |
936 | reg = si5351_msynth_params_address(hwdata->num) + 2; | 936 | reg = si5351_msynth_params_address(hwdata->num) + 2; |
937 | else | 937 | else |
938 | reg = SI5351_CLK6_7_OUTPUT_DIVIDER; | 938 | reg = SI5351_CLK6_7_OUTPUT_DIVIDER; |
@@ -1477,6 +1477,16 @@ static int si5351_i2c_probe(struct i2c_client *client, | |||
1477 | return -EINVAL; | 1477 | return -EINVAL; |
1478 | } | 1478 | } |
1479 | drvdata->onecell.clks[n] = clk; | 1479 | drvdata->onecell.clks[n] = clk; |
1480 | |||
1481 | /* set initial clkout rate */ | ||
1482 | if (pdata->clkout[n].rate != 0) { | ||
1483 | int ret; | ||
1484 | ret = clk_set_rate(clk, pdata->clkout[n].rate); | ||
1485 | if (ret != 0) { | ||
1486 | dev_err(&client->dev, "Cannot set rate : %d\n", | ||
1487 | ret); | ||
1488 | } | ||
1489 | } | ||
1480 | } | 1490 | } |
1481 | 1491 | ||
1482 | ret = of_clk_add_provider(client->dev.of_node, of_clk_src_onecell_get, | 1492 | ret = of_clk_add_provider(client->dev.of_node, of_clk_src_onecell_get, |
diff --git a/drivers/clk/clk-vt8500.c b/drivers/clk/clk-vt8500.c index debf688afa8e..553ac35bcc91 100644 --- a/drivers/clk/clk-vt8500.c +++ b/drivers/clk/clk-vt8500.c | |||
@@ -183,7 +183,7 @@ static int vt8500_dclk_set_rate(struct clk_hw *hw, unsigned long rate, | |||
183 | writel(divisor, cdev->div_reg); | 183 | writel(divisor, cdev->div_reg); |
184 | vt8500_pmc_wait_busy(); | 184 | vt8500_pmc_wait_busy(); |
185 | 185 | ||
186 | spin_lock_irqsave(cdev->lock, flags); | 186 | spin_unlock_irqrestore(cdev->lock, flags); |
187 | 187 | ||
188 | return 0; | 188 | return 0; |
189 | } | 189 | } |
diff --git a/drivers/clk/mxs/clk-imx28.c b/drivers/clk/mxs/clk-imx28.c index d0e5eed146de..4faf0afc44cd 100644 --- a/drivers/clk/mxs/clk-imx28.c +++ b/drivers/clk/mxs/clk-imx28.c | |||
@@ -10,6 +10,7 @@ | |||
10 | */ | 10 | */ |
11 | 11 | ||
12 | #include <linux/clk.h> | 12 | #include <linux/clk.h> |
13 | #include <linux/clk/mxs.h> | ||
13 | #include <linux/clkdev.h> | 14 | #include <linux/clkdev.h> |
14 | #include <linux/err.h> | 15 | #include <linux/err.h> |
15 | #include <linux/init.h> | 16 | #include <linux/init.h> |
diff --git a/drivers/clk/samsung/clk-exynos4.c b/drivers/clk/samsung/clk-exynos4.c index d0940e69d034..addc738a06fb 100644 --- a/drivers/clk/samsung/clk-exynos4.c +++ b/drivers/clk/samsung/clk-exynos4.c | |||
@@ -151,7 +151,7 @@ enum exynos4_clks { | |||
151 | sclk_audio1, sclk_audio2, sclk_spdif, sclk_spi0, sclk_spi1, sclk_spi2, | 151 | sclk_audio1, sclk_audio2, sclk_spdif, sclk_spi0, sclk_spi1, sclk_spi2, |
152 | sclk_slimbus, sclk_fimd1, sclk_mipi1, sclk_pcm1, sclk_pcm2, sclk_i2s1, | 152 | sclk_slimbus, sclk_fimd1, sclk_mipi1, sclk_pcm1, sclk_pcm2, sclk_i2s1, |
153 | sclk_i2s2, sclk_mipihsi, sclk_mfc, sclk_pcm0, sclk_g3d, sclk_pwm_isp, | 153 | sclk_i2s2, sclk_mipihsi, sclk_mfc, sclk_pcm0, sclk_g3d, sclk_pwm_isp, |
154 | sclk_spi0_isp, sclk_spi1_isp, sclk_uart_isp, | 154 | sclk_spi0_isp, sclk_spi1_isp, sclk_uart_isp, sclk_fimg2d, |
155 | 155 | ||
156 | /* gate clocks */ | 156 | /* gate clocks */ |
157 | fimc0 = 256, fimc1, fimc2, fimc3, csis0, csis1, jpeg, smmu_fimc0, | 157 | fimc0 = 256, fimc1, fimc2, fimc3, csis0, csis1, jpeg, smmu_fimc0, |
@@ -484,6 +484,9 @@ struct samsung_mux_clock exynos4x12_mux_clks[] __initdata = { | |||
484 | MUX(none, "mout_spi0_isp", group1_p4x12, E4X12_SRC_ISP, 4, 4), | 484 | MUX(none, "mout_spi0_isp", group1_p4x12, E4X12_SRC_ISP, 4, 4), |
485 | MUX(none, "mout_spi1_isp", group1_p4x12, E4X12_SRC_ISP, 8, 4), | 485 | MUX(none, "mout_spi1_isp", group1_p4x12, E4X12_SRC_ISP, 8, 4), |
486 | MUX(none, "mout_uart_isp", group1_p4x12, E4X12_SRC_ISP, 12, 4), | 486 | MUX(none, "mout_uart_isp", group1_p4x12, E4X12_SRC_ISP, 12, 4), |
487 | MUX(none, "mout_g2d0", sclk_ampll_p4210, SRC_DMC, 20, 1), | ||
488 | MUX(none, "mout_g2d1", sclk_evpll_p, SRC_DMC, 24, 1), | ||
489 | MUX(none, "mout_g2d", mout_g2d_p, SRC_DMC, 28, 1), | ||
487 | }; | 490 | }; |
488 | 491 | ||
489 | /* list of divider clocks supported in all exynos4 soc's */ | 492 | /* list of divider clocks supported in all exynos4 soc's */ |
@@ -552,7 +555,7 @@ struct samsung_div_clock exynos4_div_clks[] __initdata = { | |||
552 | /* list of divider clocks supported in exynos4210 soc */ | 555 | /* list of divider clocks supported in exynos4210 soc */ |
553 | struct samsung_div_clock exynos4210_div_clks[] __initdata = { | 556 | struct samsung_div_clock exynos4210_div_clks[] __initdata = { |
554 | DIV(aclk200, "aclk200", "mout_aclk200", DIV_TOP, 0, 3), | 557 | DIV(aclk200, "aclk200", "mout_aclk200", DIV_TOP, 0, 3), |
555 | DIV(none, "div_g2d", "mout_g2d", DIV_IMAGE, 0, 4), | 558 | DIV(sclk_fimg2d, "sclk_fimg2d", "mout_g2d", DIV_IMAGE, 0, 4), |
556 | DIV(none, "div_fimd1", "mout_fimd1", E4210_DIV_LCD1, 0, 4), | 559 | DIV(none, "div_fimd1", "mout_fimd1", E4210_DIV_LCD1, 0, 4), |
557 | DIV(none, "div_mipi1", "mout_mipi1", E4210_DIV_LCD1, 16, 4), | 560 | DIV(none, "div_mipi1", "mout_mipi1", E4210_DIV_LCD1, 16, 4), |
558 | DIV(none, "div_sata", "mout_sata", DIV_FSYS0, 20, 4), | 561 | DIV(none, "div_sata", "mout_sata", DIV_FSYS0, 20, 4), |
@@ -582,6 +585,7 @@ struct samsung_div_clock exynos4x12_div_clks[] __initdata = { | |||
582 | DIV(none, "div_mpwm", "div_isp1", E4X12_DIV_ISP1, 0, 3), | 585 | DIV(none, "div_mpwm", "div_isp1", E4X12_DIV_ISP1, 0, 3), |
583 | DIV(div_mcuisp0, "div_mcuisp0", "aclk400_mcuisp", E4X12_DIV_ISP1, 4, 3), | 586 | DIV(div_mcuisp0, "div_mcuisp0", "aclk400_mcuisp", E4X12_DIV_ISP1, 4, 3), |
584 | DIV(div_mcuisp1, "div_mcuisp1", "div_mcuisp0", E4X12_DIV_ISP1, 8, 3), | 587 | DIV(div_mcuisp1, "div_mcuisp1", "div_mcuisp0", E4X12_DIV_ISP1, 8, 3), |
588 | DIV(sclk_fimg2d, "sclk_fimg2d", "mout_g2d", DIV_DMC1, 0, 4), | ||
585 | }; | 589 | }; |
586 | 590 | ||
587 | /* list of gate clocks supported in all exynos4 soc's */ | 591 | /* list of gate clocks supported in all exynos4 soc's */ |
@@ -791,7 +795,8 @@ struct samsung_gate_clock exynos4210_gate_clks[] __initdata = { | |||
791 | GATE(smmu_pcie, "smmu_pcie", "aclk133", GATE_IP_FSYS, 18, 0, 0), | 795 | GATE(smmu_pcie, "smmu_pcie", "aclk133", GATE_IP_FSYS, 18, 0, 0), |
792 | GATE(modemif, "modemif", "aclk100", GATE_IP_PERIL, 28, 0, 0), | 796 | GATE(modemif, "modemif", "aclk100", GATE_IP_PERIL, 28, 0, 0), |
793 | GATE(chipid, "chipid", "aclk100", E4210_GATE_IP_PERIR, 0, 0, 0), | 797 | GATE(chipid, "chipid", "aclk100", E4210_GATE_IP_PERIR, 0, 0, 0), |
794 | GATE(sysreg, "sysreg", "aclk100", E4210_GATE_IP_PERIR, 0, 0, 0), | 798 | GATE(sysreg, "sysreg", "aclk100", E4210_GATE_IP_PERIR, 0, |
799 | CLK_IGNORE_UNUSED, 0), | ||
795 | GATE(hdmi_cec, "hdmi_cec", "aclk100", E4210_GATE_IP_PERIR, 11, 0, 0), | 800 | GATE(hdmi_cec, "hdmi_cec", "aclk100", E4210_GATE_IP_PERIR, 11, 0, 0), |
796 | GATE(smmu_rotator, "smmu_rotator", "aclk200", | 801 | GATE(smmu_rotator, "smmu_rotator", "aclk200", |
797 | E4210_GATE_IP_IMAGE, 4, 0, 0), | 802 | E4210_GATE_IP_IMAGE, 4, 0, 0), |
@@ -819,7 +824,8 @@ struct samsung_gate_clock exynos4x12_gate_clks[] __initdata = { | |||
819 | GATE(smmu_mdma, "smmu_mdma", "aclk200", E4X12_GATE_IP_IMAGE, 5, 0, 0), | 824 | GATE(smmu_mdma, "smmu_mdma", "aclk200", E4X12_GATE_IP_IMAGE, 5, 0, 0), |
820 | GATE(mipi_hsi, "mipi_hsi", "aclk133", GATE_IP_FSYS, 10, 0, 0), | 825 | GATE(mipi_hsi, "mipi_hsi", "aclk133", GATE_IP_FSYS, 10, 0, 0), |
821 | GATE(chipid, "chipid", "aclk100", E4X12_GATE_IP_PERIR, 0, 0, 0), | 826 | GATE(chipid, "chipid", "aclk100", E4X12_GATE_IP_PERIR, 0, 0, 0), |
822 | GATE(sysreg, "sysreg", "aclk100", E4X12_GATE_IP_PERIR, 1, 0, 0), | 827 | GATE(sysreg, "sysreg", "aclk100", E4X12_GATE_IP_PERIR, 1, |
828 | CLK_IGNORE_UNUSED, 0), | ||
823 | GATE(hdmi_cec, "hdmi_cec", "aclk100", E4X12_GATE_IP_PERIR, 11, 0, 0), | 829 | GATE(hdmi_cec, "hdmi_cec", "aclk100", E4X12_GATE_IP_PERIR, 11, 0, 0), |
824 | GATE(sclk_mdnie0, "sclk_mdnie0", "div_mdnie0", | 830 | GATE(sclk_mdnie0, "sclk_mdnie0", "div_mdnie0", |
825 | SRC_MASK_LCD0, 4, CLK_SET_RATE_PARENT, 0), | 831 | SRC_MASK_LCD0, 4, CLK_SET_RATE_PARENT, 0), |
@@ -907,6 +913,7 @@ struct samsung_gate_clock exynos4x12_gate_clks[] __initdata = { | |||
907 | CLK_IGNORE_UNUSED, 0), | 913 | CLK_IGNORE_UNUSED, 0), |
908 | GATE(spi1_isp, "spi1_isp", "aclk200", E4X12_GATE_ISP1, 13, | 914 | GATE(spi1_isp, "spi1_isp", "aclk200", E4X12_GATE_ISP1, 13, |
909 | CLK_IGNORE_UNUSED, 0), | 915 | CLK_IGNORE_UNUSED, 0), |
916 | GATE(g2d, "g2d", "aclk200", GATE_IP_DMC, 23, 0, 0), | ||
910 | }; | 917 | }; |
911 | 918 | ||
912 | /* | 919 | /* |
diff --git a/drivers/clk/ux500/clk-sysctrl.c b/drivers/clk/ux500/clk-sysctrl.c index bc7e9bde792b..e364c9d4aa60 100644 --- a/drivers/clk/ux500/clk-sysctrl.c +++ b/drivers/clk/ux500/clk-sysctrl.c | |||
@@ -145,7 +145,13 @@ static struct clk *clk_reg_sysctrl(struct device *dev, | |||
145 | return ERR_PTR(-ENOMEM); | 145 | return ERR_PTR(-ENOMEM); |
146 | } | 146 | } |
147 | 147 | ||
148 | for (i = 0; i < num_parents; i++) { | 148 | /* set main clock registers */ |
149 | clk->reg_sel[0] = reg_sel[0]; | ||
150 | clk->reg_bits[0] = reg_bits[0]; | ||
151 | clk->reg_mask[0] = reg_mask[0]; | ||
152 | |||
153 | /* handle clocks with more than one parent */ | ||
154 | for (i = 1; i < num_parents; i++) { | ||
149 | clk->reg_sel[i] = reg_sel[i]; | 155 | clk->reg_sel[i] = reg_sel[i]; |
150 | clk->reg_bits[i] = reg_bits[i]; | 156 | clk->reg_bits[i] = reg_bits[i]; |
151 | clk->reg_mask[i] = reg_mask[i]; | 157 | clk->reg_mask[i] = reg_mask[i]; |
diff --git a/drivers/clk/ux500/u8500_clk.c b/drivers/clk/ux500/u8500_clk.c index 0b4f35a5ffc2..80069c370a47 100644 --- a/drivers/clk/ux500/u8500_clk.c +++ b/drivers/clk/ux500/u8500_clk.c | |||
@@ -325,7 +325,7 @@ void u8500_clk_init(u32 clkrst1_base, u32 clkrst2_base, u32 clkrst3_base, | |||
325 | clk = clk_reg_prcc_pclk("p3_pclk0", "per3clk", clkrst3_base, | 325 | clk = clk_reg_prcc_pclk("p3_pclk0", "per3clk", clkrst3_base, |
326 | BIT(0), 0); | 326 | BIT(0), 0); |
327 | clk_register_clkdev(clk, "fsmc", NULL); | 327 | clk_register_clkdev(clk, "fsmc", NULL); |
328 | clk_register_clkdev(clk, NULL, "smsc911x"); | 328 | clk_register_clkdev(clk, NULL, "smsc911x.0"); |
329 | 329 | ||
330 | clk = clk_reg_prcc_pclk("p3_pclk1", "per3clk", clkrst3_base, | 330 | clk = clk_reg_prcc_pclk("p3_pclk1", "per3clk", clkrst3_base, |
331 | BIT(1), 0); | 331 | BIT(1), 0); |