diff options
author | Jens Arnold <amiconn@rockbox.org> | 2004-10-12 00:02:51 +0000 |
---|---|---|
committer | Jens Arnold <amiconn@rockbox.org> | 2004-10-12 00:02:51 +0000 |
commit | 7f6b640b1e47583ba451a46263053a0803ff862e (patch) | |
tree | 75c60009f8619d34e9bc7e2f7762f66478fed920 /apps/misc.c | |
parent | 1acc38f9d9186ba32f54cdf5d124586d0d2b628c (diff) |
Request to remove MMC before acknowledging USB (Ondio)
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@5254 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/misc.c')
-rw-r--r-- | apps/misc.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/apps/misc.c b/apps/misc.c index ced0668ae6..96d23a8388 100644 --- a/apps/misc.c +++ b/apps/misc.c @@ -34,6 +34,9 @@ #include "ata.h" #include "kernel.h" #include "power.h" +#ifdef HAVE_MMC +#include "ata_mmc.h" +#endif #define ONE_KILOBYTE 1024 #define ONE_MEGABYTE (1024*1024) @@ -231,7 +234,10 @@ int default_event_handler(int event) switch(event) { case SYS_USB_CONNECTED: - usb_screen(); +#ifdef HAVE_MMC + if (!mmc_detect() || (mmc_remove_request() == SYS_MMC_EXTRACTED)) +#endif + usb_screen(); return SYS_USB_CONNECTED; } return 0; |