aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-omap1/clock_data.c
diff options
context:
space:
mode:
authorJanusz Krzysztofik <jkrzyszt@tis.icnet.pl>2011-12-01 16:16:26 -0500
committerTony Lindgren <tony@atomide.com>2011-12-08 21:02:25 -0500
commitf9e5908fa04e15a681dc4695b53c2c0c1d9b9a03 (patch)
treee5174f71bffc3b93d4043a2e65756ff9ac85769d /arch/arm/mach-omap1/clock_data.c
parent24ce2705c2dd50e51f325c6e57dec378adc8c135 (diff)
ARM: OMAP1: Update dpll1 default rate reprogramming method
According to comments in omap1_select_table_rate(), reprogramming dpll1 is tricky, and should always be done from SRAM. While being at it, move OMAP730 special case handling inside omap_sram_reprogram_clock(). Created on top of version 2 of the series "ARM: OMAP1: Fix dpll1 reprogramming related issues", which it depends on. Tested on Amstrad Delta. Signed-off-by: Janusz Krzysztofik <jkrzyszt@tis.icnet.pl> Signed-off-by: Tony Lindgren <tony@atomide.com>
Diffstat (limited to 'arch/arm/mach-omap1/clock_data.c')
-rw-r--r--arch/arm/mach-omap1/clock_data.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/arch/arm/mach-omap1/clock_data.c b/arch/arm/mach-omap1/clock_data.c
index ff2d5248df23..9d1a42a5afd8 100644
--- a/arch/arm/mach-omap1/clock_data.c
+++ b/arch/arm/mach-omap1/clock_data.c
@@ -25,6 +25,7 @@
25#include <plat/clock.h> 25#include <plat/clock.h>
26#include <plat/cpu.h> 26#include <plat/cpu.h>
27#include <plat/clkdev_omap.h> 27#include <plat/clkdev_omap.h>
28#include <plat/sram.h> /* for omap_sram_reprogram_clock() */
28#include <plat/usb.h> /* for OTG_BASE */ 29#include <plat/usb.h> /* for OTG_BASE */
29 30
30#include "clock.h" 31#include "clock.h"
@@ -944,8 +945,10 @@ void __init omap1_clk_late_init(void)
944 /* Find the highest supported frequency and enable it */ 945 /* Find the highest supported frequency and enable it */
945 if (omap1_select_table_rate(&virtual_ck_mpu, ~0)) { 946 if (omap1_select_table_rate(&virtual_ck_mpu, ~0)) {
946 pr_err("System frequencies not set, using default. Check your config.\n"); 947 pr_err("System frequencies not set, using default. Check your config.\n");
947 omap_writew(0x2290, DPLL_CTL); 948 /*
948 omap_writew(cpu_is_omap7xx() ? 0x2005 : 0x0005, ARM_CKCTL); 949 * Reprogramming the DPLL is tricky, it must be done from SRAM.
950 */
951 omap_sram_reprogram_clock(0x2290, 0x0005);
949 ck_dpll1.rate = OMAP1_DPLL1_SANE_VALUE; 952 ck_dpll1.rate = OMAP1_DPLL1_SANE_VALUE;
950 } 953 }
951 propagate_rate(&ck_dpll1); 954 propagate_rate(&ck_dpll1);