aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-davinci/devices-tnetv107x.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-davinci/devices-tnetv107x.c')
-rw-r--r--arch/arm/mach-davinci/devices-tnetv107x.c15
1 files changed, 14 insertions, 1 deletions
diff --git a/arch/arm/mach-davinci/devices-tnetv107x.c b/arch/arm/mach-davinci/devices-tnetv107x.c
index c9a86d8130d..85503debda5 100644
--- a/arch/arm/mach-davinci/devices-tnetv107x.c
+++ b/arch/arm/mach-davinci/devices-tnetv107x.c
@@ -344,7 +344,20 @@ static struct platform_device tsc_device = {
344 344
345void __init tnetv107x_devices_init(struct tnetv107x_device_info *info) 345void __init tnetv107x_devices_init(struct tnetv107x_device_info *info)
346{ 346{
347 int i; 347 int i, error;
348 struct clk *tsc_clk;
349
350 /*
351 * The reset defaults for tnetv107x tsc clock divider is set too high.
352 * This forces the clock down to a range that allows the ADC to
353 * complete sample conversion in time.
354 */
355 tsc_clk = clk_get(NULL, "sys_tsc_clk");
356 if (tsc_clk) {
357 error = clk_set_rate(tsc_clk, 5000000);
358 WARN_ON(error < 0);
359 clk_put(tsc_clk);
360 }
348 361
349 platform_device_register(&edma_device); 362 platform_device_register(&edma_device);
350 platform_device_register(&tnetv107x_wdt_device); 363 platform_device_register(&tnetv107x_wdt_device);