diff options
| author | Linus Torvalds <torvalds@linux-foundation.org> | 2010-12-03 12:19:54 -0500 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-12-03 12:19:54 -0500 |
| commit | df9d38ebda762e54ed0b142c2c47b2f57a145ab2 (patch) | |
| tree | 24fbfb229eabf74a2b2ed887e5b4d1b4bd7dae29 /arch | |
| parent | 47337ad65f823358609865c5dff77404744bc38e (diff) | |
| parent | a9fc749224bfb69686322643678f89e00303ee21 (diff) | |
Merge branch 'sh-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-2.6
* 'sh-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-2.6:
sh: se/7724: Remove FSI/B of GPIO init code
sh: se/7724: Update clock framework of FSI clock to non-legacy
sh: Assume new page cache pages have dirty dcache lines.
sh: boards: mach-se: use IS_ERR() instead of NULL check
sh: Add div6_reparent_clks to clock framework for FSI
dma: shdma: add a MODULE_ALIAS() to allow module autoloading
Diffstat (limited to 'arch')
| -rw-r--r-- | arch/sh/boards/mach-ecovec24/setup.c | 34 | ||||
| -rw-r--r-- | arch/sh/boards/mach-se/7724/setup.c | 47 | ||||
| -rw-r--r-- | arch/sh/include/asm/cacheflush.h | 2 | ||||
| -rw-r--r-- | arch/sh/include/cpu-sh4/cpu/sh7724.h | 3 | ||||
| -rw-r--r-- | arch/sh/kernel/cpu/sh4a/clock-sh7724.c | 44 | ||||
| -rw-r--r-- | arch/sh/mm/cache-sh4.c | 4 | ||||
| -rw-r--r-- | arch/sh/mm/cache-sh7705.c | 2 | ||||
| -rw-r--r-- | arch/sh/mm/cache.c | 14 | ||||
| -rw-r--r-- | arch/sh/mm/kmap.c | 2 |
9 files changed, 65 insertions, 87 deletions
diff --git a/arch/sh/boards/mach-ecovec24/setup.c b/arch/sh/boards/mach-ecovec24/setup.c index 2eaeb9e59585..f48c492a68d3 100644 --- a/arch/sh/boards/mach-ecovec24/setup.c +++ b/arch/sh/boards/mach-ecovec24/setup.c | |||
| @@ -720,32 +720,6 @@ static struct platform_device camera_devices[] = { | |||
| 720 | }; | 720 | }; |
| 721 | 721 | ||
| 722 | /* FSI */ | 722 | /* FSI */ |
| 723 | /* | ||
| 724 | * FSI-B use external clock which came from da7210. | ||
| 725 | * So, we should change parent of fsi | ||
| 726 | */ | ||
| 727 | #define FCLKBCR 0xa415000c | ||
| 728 | static void fsimck_init(struct clk *clk) | ||
| 729 | { | ||
| 730 | u32 status = __raw_readl(clk->enable_reg); | ||
| 731 | |||
| 732 | /* use external clock */ | ||
| 733 | status &= ~0x000000ff; | ||
| 734 | status |= 0x00000080; | ||
| 735 | |||
| 736 | __raw_writel(status, clk->enable_reg); | ||
| 737 | } | ||
| 738 | |||
| 739 | static struct clk_ops fsimck_clk_ops = { | ||
| 740 | .init = fsimck_init, | ||
| 741 | }; | ||
| 742 | |||
| 743 | static struct clk fsimckb_clk = { | ||
| 744 | .ops = &fsimck_clk_ops, | ||
| 745 | .enable_reg = (void __iomem *)FCLKBCR, | ||
| 746 | .rate = 0, /* unknown */ | ||
| 747 | }; | ||
| 748 | |||
| 749 | static struct sh_fsi_platform_info fsi_info = { | 723 | static struct sh_fsi_platform_info fsi_info = { |
| 750 | .portb_flags = SH_FSI_BRS_INV | | 724 | .portb_flags = SH_FSI_BRS_INV | |
| 751 | SH_FSI_OUT_SLAVE_MODE | | 725 | SH_FSI_OUT_SLAVE_MODE | |
| @@ -1264,10 +1238,10 @@ static int __init arch_setup(void) | |||
| 1264 | /* change parent of FSI B */ | 1238 | /* change parent of FSI B */ |
| 1265 | clk = clk_get(NULL, "fsib_clk"); | 1239 | clk = clk_get(NULL, "fsib_clk"); |
| 1266 | if (!IS_ERR(clk)) { | 1240 | if (!IS_ERR(clk)) { |
| 1267 | clk_register(&fsimckb_clk); | 1241 | /* 48kHz dummy clock was used to make sure 1/1 divide */ |
| 1268 | clk_set_parent(clk, &fsimckb_clk); | 1242 | clk_set_rate(&sh7724_fsimckb_clk, 48000); |
| 1269 | clk_set_rate(clk, 11000); | 1243 | clk_set_parent(clk, &sh7724_fsimckb_clk); |
| 1270 | clk_set_rate(&fsimckb_clk, 11000); | 1244 | clk_set_rate(clk, 48000); |
| 1271 | clk_put(clk); | 1245 | clk_put(clk); |
| 1272 | } | 1246 | } |
| 1273 | 1247 | ||
diff --git a/arch/sh/boards/mach-se/7724/setup.c b/arch/sh/boards/mach-se/7724/setup.c index c31d228fdfc6..527a0cd956b5 100644 --- a/arch/sh/boards/mach-se/7724/setup.c +++ b/arch/sh/boards/mach-se/7724/setup.c | |||
| @@ -283,31 +283,6 @@ static struct platform_device ceu1_device = { | |||
| 283 | }; | 283 | }; |
| 284 | 284 | ||
| 285 | /* FSI */ | 285 | /* FSI */ |
| 286 | /* | ||
| 287 | * FSI-A use external clock which came from ak464x. | ||
| 288 | * So, we should change parent of fsi | ||
| 289 | */ | ||
| 290 | #define FCLKACR 0xa4150008 | ||
| 291 | static void fsimck_init(struct clk *clk) | ||
| 292 | { | ||
| 293 | u32 status = __raw_readl(clk->enable_reg); | ||
| 294 | |||
| 295 | /* use external clock */ | ||
| 296 | status &= ~0x000000ff; | ||
| 297 | status |= 0x00000080; | ||
| 298 | __raw_writel(status, clk->enable_reg); | ||
| 299 | } | ||
| 300 | |||
| 301 | static struct clk_ops fsimck_clk_ops = { | ||
| 302 | .init = fsimck_init, | ||
| 303 | }; | ||
| 304 | |||
| 305 | static struct clk fsimcka_clk = { | ||
| 306 | .ops = &fsimck_clk_ops, | ||
| 307 | .enable_reg = (void __iomem *)FCLKACR, | ||
| 308 | .rate = 0, /* unknown */ | ||
| 309 | }; | ||
| 310 | |||
| 311 | /* change J20, J21, J22 pin to 1-2 connection to use slave mode */ | 286 | /* change J20, J21, J22 pin to 1-2 connection to use slave mode */ |
| 312 | static struct sh_fsi_platform_info fsi_info = { | 287 | static struct sh_fsi_platform_info fsi_info = { |
| 313 | .porta_flags = SH_FSI_BRS_INV | | 288 | .porta_flags = SH_FSI_BRS_INV | |
| @@ -852,37 +827,29 @@ static int __init devices_setup(void) | |||
| 852 | gpio_request(GPIO_FN_KEYOUT0, NULL); | 827 | gpio_request(GPIO_FN_KEYOUT0, NULL); |
| 853 | 828 | ||
| 854 | /* enable FSI */ | 829 | /* enable FSI */ |
| 855 | gpio_request(GPIO_FN_FSIMCKB, NULL); | ||
| 856 | gpio_request(GPIO_FN_FSIMCKA, NULL); | 830 | gpio_request(GPIO_FN_FSIMCKA, NULL); |
| 831 | gpio_request(GPIO_FN_FSIIASD, NULL); | ||
| 857 | gpio_request(GPIO_FN_FSIOASD, NULL); | 832 | gpio_request(GPIO_FN_FSIOASD, NULL); |
| 858 | gpio_request(GPIO_FN_FSIIABCK, NULL); | 833 | gpio_request(GPIO_FN_FSIIABCK, NULL); |
| 859 | gpio_request(GPIO_FN_FSIIALRCK, NULL); | 834 | gpio_request(GPIO_FN_FSIIALRCK, NULL); |
| 860 | gpio_request(GPIO_FN_FSIOABCK, NULL); | 835 | gpio_request(GPIO_FN_FSIOABCK, NULL); |
| 861 | gpio_request(GPIO_FN_FSIOALRCK, NULL); | 836 | gpio_request(GPIO_FN_FSIOALRCK, NULL); |
| 862 | gpio_request(GPIO_FN_CLKAUDIOAO, NULL); | 837 | gpio_request(GPIO_FN_CLKAUDIOAO, NULL); |
| 863 | gpio_request(GPIO_FN_FSIIBSD, NULL); | ||
| 864 | gpio_request(GPIO_FN_FSIOBSD, NULL); | ||
| 865 | gpio_request(GPIO_FN_FSIIBBCK, NULL); | ||
| 866 | gpio_request(GPIO_FN_FSIIBLRCK, NULL); | ||
| 867 | gpio_request(GPIO_FN_FSIOBBCK, NULL); | ||
| 868 | gpio_request(GPIO_FN_FSIOBLRCK, NULL); | ||
| 869 | gpio_request(GPIO_FN_CLKAUDIOBO, NULL); | ||
| 870 | gpio_request(GPIO_FN_FSIIASD, NULL); | ||
| 871 | 838 | ||
| 872 | /* set SPU2 clock to 83.4 MHz */ | 839 | /* set SPU2 clock to 83.4 MHz */ |
| 873 | clk = clk_get(NULL, "spu_clk"); | 840 | clk = clk_get(NULL, "spu_clk"); |
| 874 | if (clk) { | 841 | if (!IS_ERR(clk)) { |
| 875 | clk_set_rate(clk, clk_round_rate(clk, 83333333)); | 842 | clk_set_rate(clk, clk_round_rate(clk, 83333333)); |
| 876 | clk_put(clk); | 843 | clk_put(clk); |
| 877 | } | 844 | } |
| 878 | 845 | ||
| 879 | /* change parent of FSI A */ | 846 | /* change parent of FSI A */ |
| 880 | clk = clk_get(NULL, "fsia_clk"); | 847 | clk = clk_get(NULL, "fsia_clk"); |
| 881 | if (clk) { | 848 | if (!IS_ERR(clk)) { |
| 882 | clk_register(&fsimcka_clk); | 849 | /* 48kHz dummy clock was used to make sure 1/1 divide */ |
| 883 | clk_set_parent(clk, &fsimcka_clk); | 850 | clk_set_rate(&sh7724_fsimcka_clk, 48000); |
| 884 | clk_set_rate(clk, 11000); | 851 | clk_set_parent(clk, &sh7724_fsimcka_clk); |
| 885 | clk_set_rate(&fsimcka_clk, 11000); | 852 | clk_set_rate(clk, 48000); |
| 886 | clk_put(clk); | 853 | clk_put(clk); |
| 887 | } | 854 | } |
| 888 | 855 | ||
diff --git a/arch/sh/include/asm/cacheflush.h b/arch/sh/include/asm/cacheflush.h index 1f4e562c5e8c..82e1eabeac98 100644 --- a/arch/sh/include/asm/cacheflush.h +++ b/arch/sh/include/asm/cacheflush.h | |||
| @@ -96,7 +96,7 @@ void kmap_coherent_init(void); | |||
| 96 | void *kmap_coherent(struct page *page, unsigned long addr); | 96 | void *kmap_coherent(struct page *page, unsigned long addr); |
| 97 | void kunmap_coherent(void *kvaddr); | 97 | void kunmap_coherent(void *kvaddr); |
| 98 | 98 | ||
| 99 | #define PG_dcache_dirty PG_arch_1 | 99 | #define PG_dcache_clean PG_arch_1 |
| 100 | 100 | ||
| 101 | void cpu_cache_init(void); | 101 | void cpu_cache_init(void); |
| 102 | 102 | ||
diff --git a/arch/sh/include/cpu-sh4/cpu/sh7724.h b/arch/sh/include/cpu-sh4/cpu/sh7724.h index 4c27b68789b3..7eb435999426 100644 --- a/arch/sh/include/cpu-sh4/cpu/sh7724.h +++ b/arch/sh/include/cpu-sh4/cpu/sh7724.h | |||
| @@ -303,4 +303,7 @@ enum { | |||
| 303 | SHDMA_SLAVE_SDHI1_RX, | 303 | SHDMA_SLAVE_SDHI1_RX, |
| 304 | }; | 304 | }; |
| 305 | 305 | ||
| 306 | extern struct clk sh7724_fsimcka_clk; | ||
| 307 | extern struct clk sh7724_fsimckb_clk; | ||
