aboutsummaryrefslogtreecommitdiffstats
path: root/arch/sh/boards/mach-se/7724/setup.c
diff options
context:
space:
mode:
authorKuninori Morimoto <kuninori.morimoto.gx@renesas.com>2010-05-12 21:08:37 -0400
committerPaul Mundt <lethal@linux-sh.org>2010-05-13 04:39:39 -0400
commit03c5ecd13cfe308a521e40e6dec6059314f3341b (patch)
tree6c5c58414e0644097a0d0dd42aebd698b4509dfd /arch/sh/boards/mach-se/7724/setup.c
parent103058536300f80ec54f2a8c9209d066925416fd (diff)
sh: Check return value of clk_get on ms7724
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Diffstat (limited to 'arch/sh/boards/mach-se/7724/setup.c')
-rw-r--r--arch/sh/boards/mach-se/7724/setup.c18
1 files changed, 11 insertions, 7 deletions
diff --git a/arch/sh/boards/mach-se/7724/setup.c b/arch/sh/boards/mach-se/7724/setup.c
index 20b6053f714..e74ae7b0d8b 100644
--- a/arch/sh/boards/mach-se/7724/setup.c
+++ b/arch/sh/boards/mach-se/7724/setup.c
@@ -769,16 +769,20 @@ static int __init devices_setup(void)
769 769
770 /* set SPU2 clock to 83.4 MHz */ 770 /* set SPU2 clock to 83.4 MHz */
771 clk = clk_get(NULL, "spu_clk"); 771 clk = clk_get(NULL, "spu_clk");
772 clk_set_rate(clk, clk_round_rate(clk, 83333333)); 772 if (clk) {
773 clk_put(clk); 773 clk_set_rate(clk, clk_round_rate(clk, 83333333));
774 clk_put(clk);
775 }
774 776
775 /* change parent of FSI A */ 777 /* change parent of FSI A */
776 clk = clk_get(NULL, "fsia_clk"); 778 clk = clk_get(NULL, "fsia_clk");
777 clk_register(&fsimcka_clk); 779 if (clk) {
778 clk_set_parent(clk, &fsimcka_clk); 780 clk_register(&fsimcka_clk);
779 clk_set_rate(clk, 11000); 781 clk_set_parent(clk, &fsimcka_clk);
780 clk_set_rate(&fsimcka_clk, 11000); 782 clk_set_rate(clk, 11000);
781 clk_put(clk); 783 clk_set_rate(&fsimcka_clk, 11000);
784 clk_put(clk);
785 }
782 786
783 /* SDHI0 connected to cn7 */ 787 /* SDHI0 connected to cn7 */
784 gpio_request(GPIO_FN_SDHI0CD, NULL); 788 gpio_request(GPIO_FN_SDHI0CD, NULL);