summaryrefslogtreecommitdiffstats
path: root/firmware
diff options
context:
space:
mode:
authorFrank Gevaerts <frank@gevaerts.be>2009-07-20 19:46:36 +0000
committerFrank Gevaerts <frank@gevaerts.be>2009-07-20 19:46:36 +0000
commit534cd216a0747d66b5b37f29a858119448d67fde (patch)
tree6abd9ffa270e322c603254a91f6f330c3e0797a3 /firmware
parentb6d92e8a1b332317cc02426a2906d94ff28286ac (diff)
downloadrockbox-534cd216a0747d66b5b37f29a858119448d67fde.tar.gz
rockbox-534cd216a0747d66b5b37f29a858119448d67fde.tar.bz2
rockbox-534cd216a0747d66b5b37f29a858119448d67fde.zip
sd_first_drive is only used when HAVE_HOTSWAP is defined, so add appropriate #ifdefs
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@21985 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware')
-rw-r--r--firmware/target/arm/ata-sd-pp.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/firmware/target/arm/ata-sd-pp.c b/firmware/target/arm/ata-sd-pp.c
index 78a2a4f3a4..f2efd02e9d 100644
--- a/firmware/target/arm/ata-sd-pp.c
+++ b/firmware/target/arm/ata-sd-pp.c
@@ -180,7 +180,9 @@ static const char sd_thread_name[] = "ata/sd";
static struct mutex sd_mtx SHAREDBSS_ATTR;
static struct event_queue sd_queue;
+#ifdef HAVE_HOTSWAP
static int sd_first_drive = 0;
+#endif
/* Posted when card plugged status has changed */
#define SD_HOTSWAP 1
@@ -1359,8 +1361,12 @@ bool sd_present(IF_MD_NONVOID(int drive))
#ifdef CONFIG_STORAGE_MULTI
int sd_num_drives(int first_drive)
{
+#ifdef HAVE_HOTSWAP
/* Store which logical drive number(s) we have been assigned */
sd_first_drive = first_drive;
+#else
+ (void)first_drive;
+#endif
#ifdef HAVE_MULTIDRIVE
return 2;