summaryrefslogtreecommitdiff
path: root/firmware/backlight.c
diff options
context:
space:
mode:
authorJens Arnold <amiconn@rockbox.org>2005-10-03 09:24:36 +0000
committerJens Arnold <amiconn@rockbox.org>2005-10-03 09:24:36 +0000
commitcfb073c452c0218a82e23fb5f5f89043719f2c07 (patch)
tree5aff8555b218e10037c086aaad3aaec1b4d677c8 /firmware/backlight.c
parent7190cf2ed9cfa854d81e7bf9c0e8a1ef71935c1f (diff)
downloadrockbox-cfb073c452c0218a82e23fb5f5f89043719f2c07.tar.gz
rockbox-cfb073c452c0218a82e23fb5f5f89043719f2c07.zip
Coldfire: New timer handling on CPU frequency change, adjusting the prescaler on the fly, for both tick and user timer. Precondition is that the higher frequencies are integer multiples of the base: now NORMAL is 45 MHz and MAX is 124 MHz. Removes the need for applications with longer timer periods (>= 10 ms) to boost the CPU all the time, e.g. the grayscale lib. Timer counts are now always based on the base frequency (CPU_FREQ). * Adjusted the RAM refresh timers to the new frequencies (all frequencies for H100) * All: Fixed the tick timer count being off by one.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@7576 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/backlight.c')
-rw-r--r--firmware/backlight.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/firmware/backlight.c b/firmware/backlight.c
index 675237157b..ecd4403d88 100644
--- a/firmware/backlight.c
+++ b/firmware/backlight.c
@@ -81,7 +81,7 @@ static void backlight_isr(void)
81 int timer_period; 81 int timer_period;
82 bool idle = false; 82 bool idle = false;
83 83
84 timer_period = FREQ / 1000 * BL_PWM_INTERVAL / 1000; 84 timer_period = CPU_FREQ / 1000 * BL_PWM_INTERVAL / 1000;
85 switch (bl_dim_state) 85 switch (bl_dim_state)
86 { 86 {
87 /* New cycle */ 87 /* New cycle */