diff options
author | Mark Arigo <markarigo@gmail.com> | 2008-05-13 02:50:31 +0000 |
---|---|---|
committer | Mark Arigo <markarigo@gmail.com> | 2008-05-13 02:50:31 +0000 |
commit | 3e743ec6c9685ef3b7d9729e2b21236bf66bed93 (patch) | |
tree | 199570de7b6cb44ef7ccf26090fbbaa061b6101c /firmware/target/arm/ata-sd-pp.c | |
parent | 76567482215b9d786ba329072b715729ea506b7e (diff) | |
download | rockbox-3e743ec6c9685ef3b7d9729e2b21236bf66bed93.tar.gz rockbox-3e743ec6c9685ef3b7d9729e2b21236bf66bed93.zip |
Preparing for the Philips SA9200 part 2. Since the SA9200 doesn't have a microsd card (no hotswap), use HAVE_ATA_SD for the Sansa flash driver so we don't rely on HAVE_HOTSWAP in some places.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@17488 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/target/arm/ata-sd-pp.c')
-rw-r--r-- | firmware/target/arm/ata-sd-pp.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/firmware/target/arm/ata-sd-pp.c b/firmware/target/arm/ata-sd-pp.c index 8c7ebcddc7..e4ab922f24 100644 --- a/firmware/target/arm/ata-sd-pp.c +++ b/firmware/target/arm/ata-sd-pp.c | |||
@@ -18,9 +18,7 @@ | |||
18 | ****************************************************************************/ | 18 | ****************************************************************************/ |
19 | #include "fat.h" | 19 | #include "fat.h" |
20 | #include "hotswap.h" | 20 | #include "hotswap.h" |
21 | #ifdef BOOTLOADER | ||
22 | #include "ata-sd-target.h" | 21 | #include "ata-sd-target.h" |
23 | #endif | ||
24 | #include "ata_idle_notify.h" | 22 | #include "ata_idle_notify.h" |
25 | #include "system.h" | 23 | #include "system.h" |
26 | #include <string.h> | 24 | #include <string.h> |
@@ -1278,16 +1276,20 @@ tCardInfo *card_get_info_target(int card_no) | |||
1278 | return &card; | 1276 | return &card; |
1279 | } | 1277 | } |
1280 | 1278 | ||
1281 | #ifdef HAVE_HOTSWAP | ||
1282 | bool card_detect_target(void) | 1279 | bool card_detect_target(void) |
1283 | { | 1280 | { |
1281 | #ifdef HAVE_HOTSWAP | ||
1284 | #ifdef SANSA_E200 | 1282 | #ifdef SANSA_E200 |
1285 | return (GPIOA_INPUT_VAL & 0x80) == 0; /* low active */ | 1283 | return (GPIOA_INPUT_VAL & 0x80) == 0; /* low active */ |
1286 | #elif defined SANSA_C200 | 1284 | #elif defined SANSA_C200 |
1287 | return (GPIOL_INPUT_VAL & 0x08) != 0; /* high active */ | 1285 | return (GPIOL_INPUT_VAL & 0x08) != 0; /* high active */ |
1288 | #endif | 1286 | #endif |
1287 | #else | ||
1288 | return false; | ||
1289 | #endif | ||
1289 | } | 1290 | } |
1290 | 1291 | ||
1292 | #ifdef HAVE_HOTSWAP | ||
1291 | static bool sd1_oneshot_callback(struct timeout *tmo) | 1293 | static bool sd1_oneshot_callback(struct timeout *tmo) |
1292 | { | 1294 | { |
1293 | (void)tmo; | 1295 | (void)tmo; |