diff options
author | Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> | 2012-11-07 22:09:11 -0500 |
---|---|---|
committer | Simon Horman <horms@verge.net.au> | 2012-11-08 03:52:04 -0500 |
commit | 13e35b408ad0dd5592a7d2d1e6ad6c4962b8c4c5 (patch) | |
tree | ccc55c34fd7618c9ef4272719d8fe2dfca55cc80 /arch/arm/mach-shmobile | |
parent | c8c3243c7594858da9a8f51672984f79cd1585d3 (diff) |
ARM: shmobile: use FSI driver's audio clock on armadillo800eva
Current FSI driver can control audio clock without platform
call-back functions
This patch removed board-specific call-back/settings
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Simon Horman <horms@verge.net.au>
Diffstat (limited to 'arch/arm/mach-shmobile')
-rw-r--r-- | arch/arm/mach-shmobile/board-armadillo800eva.c | 38 |
1 files changed, 3 insertions, 35 deletions
diff --git a/arch/arm/mach-shmobile/board-armadillo800eva.c b/arch/arm/mach-shmobile/board-armadillo800eva.c index fe27d7eda4bb..3d4c0e438780 100644 --- a/arch/arm/mach-shmobile/board-armadillo800eva.c +++ b/arch/arm/mach-shmobile/board-armadillo800eva.c | |||
@@ -768,32 +768,6 @@ static struct platform_device ceu0_device = { | |||
768 | }; | 768 | }; |
769 | 769 | ||
770 | /* FSI */ | 770 | /* FSI */ |
771 | static int fsi_hdmi_set_rate(struct device *dev, int rate, int enable) | ||
772 | { | ||
773 | struct clk *fsib; | ||
774 | int ret; | ||
775 | |||
776 | /* it support 48KHz only */ | ||
777 | if (48000 != rate) | ||
778 | return -EINVAL; | ||
779 | |||
780 | fsib = clk_get(dev, "ickb"); | ||
781 | if (IS_ERR(fsib)) | ||
782 | return -EINVAL; | ||
783 | |||
784 | if (enable) { | ||
785 | ret = SH_FSI_ACKMD_256 | SH_FSI_BPFMD_64; | ||
786 | clk_enable(fsib); | ||
787 | } else { | ||
788 | ret = 0; | ||
789 | clk_disable(fsib); | ||
790 | } | ||
791 | |||
792 | clk_put(fsib); | ||
793 | |||
794 | return ret; | ||
795 | } | ||
796 | |||
797 | static struct sh_fsi_platform_info fsi_info = { | 771 | static struct sh_fsi_platform_info fsi_info = { |
798 | /* FSI-WM8978 */ | 772 | /* FSI-WM8978 */ |
799 | .port_a = { | 773 | .port_a = { |
@@ -802,8 +776,8 @@ static struct sh_fsi_platform_info fsi_info = { | |||
802 | /* FSI-HDMI */ | 776 | /* FSI-HDMI */ |
803 | .port_b = { | 777 | .port_b = { |
804 | .flags = SH_FSI_FMT_SPDIF | | 778 | .flags = SH_FSI_FMT_SPDIF | |
805 | SH_FSI_ENABLE_STREAM_MODE, | 779 | SH_FSI_ENABLE_STREAM_MODE | |
806 | .set_rate = fsi_hdmi_set_rate, | 780 | SH_FSI_CLK_CPG, |
807 | .tx_id = SHDMA_SLAVE_FSIB_TX, | 781 | .tx_id = SHDMA_SLAVE_FSIB_TX, |
808 | } | 782 | } |
809 | }; | 783 | }; |
@@ -938,13 +912,11 @@ static void __init eva_clock_init(void) | |||
938 | struct clk *xtal1 = clk_get(NULL, "extal1"); | 912 | struct clk *xtal1 = clk_get(NULL, "extal1"); |
939 | struct clk *usb24s = clk_get(NULL, "usb24s"); | 913 | struct clk *usb24s = clk_get(NULL, "usb24s"); |
940 | struct clk *fsibck = clk_get(NULL, "fsibck"); | 914 | struct clk *fsibck = clk_get(NULL, "fsibck"); |
941 | struct clk *fsib = clk_get(&fsi_device.dev, "ickb"); | ||
942 | 915 | ||
943 | if (IS_ERR(system) || | 916 | if (IS_ERR(system) || |
944 | IS_ERR(xtal1) || | 917 | IS_ERR(xtal1) || |
945 | IS_ERR(usb24s) || | 918 | IS_ERR(usb24s) || |
946 | IS_ERR(fsibck) || | 919 | IS_ERR(fsibck)) { |
947 | IS_ERR(fsib)) { | ||
948 | pr_err("armadillo800eva board clock init failed\n"); | 920 | pr_err("armadillo800eva board clock init failed\n"); |
949 | goto clock_error; | 921 | goto clock_error; |
950 | } | 922 | } |
@@ -956,9 +928,7 @@ static void __init eva_clock_init(void) | |||
956 | clk_set_parent(usb24s, system); | 928 | clk_set_parent(usb24s, system); |
957 | 929 | ||
958 | /* FSIBCK is 12.288MHz, and it is parent of FSI-B */ | 930 | /* FSIBCK is 12.288MHz, and it is parent of FSI-B */ |
959 | clk_set_parent(fsib, fsibck); | ||
960 | clk_set_rate(fsibck, 12288000); | 931 | clk_set_rate(fsibck, 12288000); |
961 | clk_set_rate(fsib, 12288000); | ||
962 | 932 | ||
963 | clock_error: | 933 | clock_error: |
964 | if (!IS_ERR(system)) | 934 | if (!IS_ERR(system)) |
@@ -969,8 +939,6 @@ clock_error: | |||
969 | clk_put(usb24s); | 939 | clk_put(usb24s); |
970 | if (!IS_ERR(fsibck)) | 940 | if (!IS_ERR(fsibck)) |
971 | clk_put(fsibck); | 941 | clk_put(fsibck); |
972 | if (!IS_ERR(fsib)) | ||
973 | clk_put(fsib); | ||
974 | } | 942 | } |
975 | 943 | ||
976 | /* | 944 | /* |