summaryrefslogtreecommitdiffstats
path: root/firmware
diff options
context:
space:
mode:
authorNils Wallménius <nils@rockbox.org>2007-08-01 08:50:44 +0000
committerNils Wallménius <nils@rockbox.org>2007-08-01 08:50:44 +0000
commit0bfa3e76ce8f2c5465ff568b7f4dcf7b5fbb462f (patch)
treed84ec59c3b9fc00ce46329c01a66b8da46b0e204 /firmware
parent3b3fd4997ee32cf5b0bc7cf07b3ac9a73cbcb388 (diff)
downloadrockbox-0bfa3e76ce8f2c5465ff568b7f4dcf7b5fbb462f.tar.gz
rockbox-0bfa3e76ce8f2c5465ff568b7f4dcf7b5fbb462f.zip
Disable 'Disk spindown' and 'Anti skip buffer' settings and some related stuff for flash storage targets as they make no sense
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@14110 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware')
-rw-r--r--firmware/export/audio.h2
-rw-r--r--firmware/export/config-e200.h3
-rw-r--r--firmware/export/config-ifp7xx.h3
-rw-r--r--firmware/export/config-ipodnano.h3
-rw-r--r--firmware/export/config-ondiofm.h3
-rw-r--r--firmware/export/config-ondiosp.h3
-rw-r--r--firmware/mpeg.c4
7 files changed, 20 insertions, 1 deletions
diff --git a/firmware/export/audio.h b/firmware/export/audio.h
index e6fed90069..933076537e 100644
--- a/firmware/export/audio.h
+++ b/firmware/export/audio.h
@@ -96,7 +96,9 @@ struct mp3entry* audio_next_track(void);
bool audio_has_changed_track(void);
void audio_get_debugdata(struct audio_debug *dbgdata);
void audio_set_crossfade(int type);
+#ifndef HAVE_FLASH_STORAGE
void audio_set_buffer_margin(int seconds);
+#endif
unsigned int audio_error(void);
void audio_error_clear(void);
int audio_get_file_pos(void);
diff --git a/firmware/export/config-e200.h b/firmware/export/config-e200.h
index bbf4ce0c81..b59974ad96 100644
--- a/firmware/export/config-e200.h
+++ b/firmware/export/config-e200.h
@@ -84,6 +84,9 @@
#define BATTERY_CAPACITY_DEFAULT 750 /* default battery capacity */
+/* define this if you have a flash memory storage */
+#define HAVE_FLASH_STORAGE
+
/** Non-simulator section **/
#ifndef SIMULATOR
diff --git a/firmware/export/config-ifp7xx.h b/firmware/export/config-ifp7xx.h
index 435b6ef984..89b2228078 100644
--- a/firmware/export/config-ifp7xx.h
+++ b/firmware/export/config-ifp7xx.h
@@ -57,6 +57,9 @@
#define MAX_CONTRAST_SETTING 63
#define DEFAULT_CONTRAST_SETTING 40
+/* define this if you have a flash memory storage */
+#define HAVE_FLASH_STORAGE
+
#ifndef SIMULATOR
/* Define this if you have a Philips PNX0101 */
diff --git a/firmware/export/config-ipodnano.h b/firmware/export/config-ipodnano.h
index edf7f2dea2..546d9b85fc 100644
--- a/firmware/export/config-ipodnano.h
+++ b/firmware/export/config-ipodnano.h
@@ -70,6 +70,9 @@
/* We can fade the backlight by using PWM */
#define HAVE_BACKLIGHT_PWM_FADING
+/* define this if you have a flash memory storage */
+#define HAVE_FLASH_STORAGE
+
#ifndef SIMULATOR
/* Define this if you have a PortalPlayer PP5022 */
diff --git a/firmware/export/config-ondiofm.h b/firmware/export/config-ondiofm.h
index ea806a4973..93c0fccc8c 100644
--- a/firmware/export/config-ondiofm.h
+++ b/firmware/export/config-ondiofm.h
@@ -48,6 +48,9 @@
#define BATTERY_CAPACITY_DEFAULT 1000 /* default battery capacity */
+/* define this if you have a flash memory storage */
+#define HAVE_FLASH_STORAGE
+
#ifndef SIMULATOR
/* Define this if you have a SH7034 */
diff --git a/firmware/export/config-ondiosp.h b/firmware/export/config-ondiosp.h
index 1d3e98ac0a..22673e82b3 100644
--- a/firmware/export/config-ondiosp.h
+++ b/firmware/export/config-ondiosp.h
@@ -37,6 +37,9 @@
#define BATTERY_CAPACITY_DEFAULT 1000 /* default battery capacity */
+/* define this if you have a flash memory storage */
+#define HAVE_FLASH_STORAGE
+
#ifndef SIMULATOR
/* Define this if you have a SH7034 */
diff --git a/firmware/mpeg.c b/firmware/mpeg.c
index 4ba3f7ead7..278eea4758 100644
--- a/firmware/mpeg.c
+++ b/firmware/mpeg.c
@@ -158,7 +158,7 @@ static int last_dma_tick = 0;
static int last_dma_chunk_size;
static long low_watermark; /* Dynamic low watermark level */
-static long low_watermark_margin; /* Extra time in seconds for watermark */
+static long low_watermark_margin = 0; /* Extra time in seconds for watermark */
static long lowest_watermark_level; /* Debug value to observe the buffer
usage */
#if CONFIG_CODEC == MAS3587F
@@ -592,10 +592,12 @@ static void recalculate_watermark(int bitrate)
}
}
+#ifndef HAVE_FLASH_STORAGE
void audio_set_buffer_margin(int seconds)
{
low_watermark_margin = seconds;
}
+#endif
void audio_get_debugdata(struct audio_debug *dbgdata)
{