diff options
Diffstat (limited to 'arch/sh')
-rw-r--r-- | arch/sh/boards/mach-ecovec24/setup.c | 24 |
1 files changed, 15 insertions, 9 deletions
diff --git a/arch/sh/boards/mach-ecovec24/setup.c b/arch/sh/boards/mach-ecovec24/setup.c index 1850c087a93b..62123885a6fa 100644 --- a/arch/sh/boards/mach-ecovec24/setup.c +++ b/arch/sh/boards/mach-ecovec24/setup.c | |||
@@ -1136,16 +1136,20 @@ static int __init arch_setup(void) | |||
1136 | 1136 | ||
1137 | /* set SPU2 clock to 83.4 MHz */ | 1137 | /* set SPU2 clock to 83.4 MHz */ |
1138 | clk = clk_get(NULL, "spu_clk"); | 1138 | clk = clk_get(NULL, "spu_clk"); |
1139 | clk_set_rate(clk, clk_round_rate(clk, 83333333)); | 1139 | if (clk) { |
1140 | clk_put(clk); | 1140 | clk_set_rate(clk, clk_round_rate(clk, 83333333)); |
1141 | clk_put(clk); | ||
1142 | } | ||
1141 | 1143 | ||
1142 | /* change parent of FSI B */ | 1144 | /* change parent of FSI B */ |
1143 | clk = clk_get(NULL, "fsib_clk"); | 1145 | clk = clk_get(NULL, "fsib_clk"); |
1144 | clk_register(&fsimckb_clk); | 1146 | if (clk) { |
1145 | clk_set_parent(clk, &fsimckb_clk); | 1147 | clk_register(&fsimckb_clk); |
1146 | clk_set_rate(clk, 11000); | 1148 | clk_set_parent(clk, &fsimckb_clk); |
1147 | clk_set_rate(&fsimckb_clk, 11000); | 1149 | clk_set_rate(clk, 11000); |
1148 | clk_put(clk); | 1150 | clk_set_rate(&fsimckb_clk, 11000); |
1151 | clk_put(clk); | ||
1152 | } | ||
1149 | 1153 | ||
1150 | gpio_request(GPIO_PTU0, NULL); | 1154 | gpio_request(GPIO_PTU0, NULL); |
1151 | gpio_direction_output(GPIO_PTU0, 0); | 1155 | gpio_direction_output(GPIO_PTU0, 0); |
@@ -1157,8 +1161,10 @@ static int __init arch_setup(void) | |||
1157 | 1161 | ||
1158 | /* set VPU clock to 166 MHz */ | 1162 | /* set VPU clock to 166 MHz */ |
1159 | clk = clk_get(NULL, "vpu_clk"); | 1163 | clk = clk_get(NULL, "vpu_clk"); |
1160 | clk_set_rate(clk, clk_round_rate(clk, 166000000)); | 1164 | if (clk) { |
1161 | clk_put(clk); | 1165 | clk_set_rate(clk, clk_round_rate(clk, 166000000)); |
1166 | clk_put(clk); | ||
1167 | } | ||
1162 | 1168 | ||
1163 | /* enable IrDA */ | 1169 | /* enable IrDA */ |
1164 | gpio_request(GPIO_FN_IRDA_OUT, NULL); | 1170 | gpio_request(GPIO_FN_IRDA_OUT, NULL); |