diff options
| author | Miika Pekkarinen <miipekk@ihme.org> | 2006-09-03 16:20:35 +0000 |
|---|---|---|
| committer | Miika Pekkarinen <miipekk@ihme.org> | 2006-09-03 16:20:35 +0000 |
| commit | 630c300660ed6c0aec9f8458b31fa2d7a578429f (patch) | |
| tree | 0ccc0a8228ae933bb667afb31aa34771d5db42a7 | |
| parent | 6ae43305882e71ec2d3c63406314363cdab4d861 (diff) | |
| download | rockbox-630c300660ed6c0aec9f8458b31fa2d7a578429f.zip rockbox-630c300660ed6c0aec9f8458b31fa2d7a578429f.tar.gz rockbox-630c300660ed6c0aec9f8458b31fa2d7a578429f.tar.bz2 rockbox-630c300660ed6c0aec9f8458b31fa2d7a578429f.tar.xz | |
Fixed cpu incorrectly unboosted at boot.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@10871 a1c6a512-1295-4272-9138-f99709370657
| -rw-r--r-- | apps/recorder/recording.c | 16 | ||||
| -rw-r--r-- | apps/tagtree.c | 2 |
2 files changed, 17 insertions, 1 deletions
diff --git a/apps/recorder/recording.c b/apps/recorder/recording.c index e964db1..ff002d7 100644 --- a/apps/recorder/recording.c +++ b/apps/recorder/recording.c @@ -534,6 +534,20 @@ int rec_create_directory(void) } #if CONFIG_CODEC == SWCODEC && !defined(SIMULATOR) + +#ifdef HAVE_ADJUSTABLE_CPU_FREQ +static void rec_boost(bool state) +{ + static bool cpu_boosted = false; + + if (state != cpu_boosted) + { + cpu_boost(state); + cpu_boosted = state; + } +} +#endif + /** * Selects an audio source for recording or playback * powers/unpowers related devices. @@ -567,7 +581,7 @@ void rec_set_source(int source, int flags) #ifdef HAVE_SPDIF_IN if ((source == AUDIO_SRC_SPDIF) != (source == last_source)) - cpu_boost(source == AUDIO_SRC_SPDIF); + rec_boost(source == AUDIO_SRC_SPDIF); #ifdef HAVE_SPDIF_POWER /* Check if S/PDIF output power should be switched off or on. NOTE: assumes diff --git a/apps/tagtree.c b/apps/tagtree.c index 8ef7869..7ef8e89 100644 --- a/apps/tagtree.c +++ b/apps/tagtree.c @@ -1062,6 +1062,7 @@ bool insert_all_playlist(struct tree_context *c, int position, bool queue) if (!tagcache_search(&tcs, tag_filename)) { gui_syncsplash(HZ, true, str(LANG_TAGCACHE_BUSY)); + cpu_boost(false); return false; } @@ -1207,6 +1208,7 @@ struct tagentry* tagtree_get_entry(struct tree_context *c, int id) false) < 0) { logf("retrieve failed"); + cpu_boost(false); return NULL; } realid = id - current_offset; |