summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFrank Gevaerts <frank@gevaerts.be>2008-03-10 20:57:56 +0000
committerFrank Gevaerts <frank@gevaerts.be>2008-03-10 20:57:56 +0000
commitf10f891bb4bd05c699344a782e798d3a1c1a63ea (patch)
treef1c4c3f4e8e3437cd5b5fe8ebd891790d17c831a
parent745133014e6161c4d8c7a7eab137b7d9b1174c55 (diff)
downloadrockbox-f10f891bb4bd05c699344a782e798d3a1c1a63ea.tar.gz
rockbox-f10f891bb4bd05c699344a782e798d3a1c1a63ea.zip
provide a debug menu item to virtually reinsert drives for usb storage when the player is back to normal after "ejecting" all drives
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@16618 a1c6a512-1295-4272-9138-f99709370657
-rw-r--r--apps/debug_menu.c17
1 files changed, 16 insertions, 1 deletions
diff --git a/apps/debug_menu.c b/apps/debug_menu.c
index f93755a293..b77a09a18c 100644
--- a/apps/debug_menu.c
+++ b/apps/debug_menu.c
@@ -102,9 +102,12 @@
102#include "as3514.h" 102#include "as3514.h"
103#endif 103#endif
104 104
105#if defined(HAVE_USBSTACK) && defined(ROCKBOX_HAS_LOGF) 105#if defined(HAVE_USBSTACK)
106#include "usb_core.h" 106#include "usb_core.h"
107#endif 107#endif
108#ifdef USB_STORAGE
109#include "../firmware/usbstack/usb_storage.h"
110#endif
108 111
109/*---------------------------------------------------*/ 112/*---------------------------------------------------*/
110/* SPECIAL DEBUG STUFF */ 113/* SPECIAL DEBUG STUFF */
@@ -2378,6 +2381,15 @@ static bool logf_usb_serial(void)
2378} 2381}
2379#endif 2382#endif
2380 2383
2384#if defined(HAVE_USBSTACK) && defined(USB_STORAGE)
2385static bool usb_reconnect(void)
2386{
2387 gui_syncsplash(HZ, "Reconnect mass storage");
2388 usb_storage_reconnect();
2389 return false;
2390}
2391#endif
2392
2381 2393
2382/****** The menu *********/ 2394/****** The menu *********/
2383struct the_menu_item { 2395struct the_menu_item {
@@ -2460,6 +2472,9 @@ static const struct the_menu_item menuitems[] = {
2460#if defined(HAVE_USBSTACK) && defined(ROCKBOX_HAS_LOGF) && defined(USB_SERIAL) 2472#if defined(HAVE_USBSTACK) && defined(ROCKBOX_HAS_LOGF) && defined(USB_SERIAL)
2461 {"logf over usb",logf_usb_serial }, 2473 {"logf over usb",logf_usb_serial },
2462#endif 2474#endif
2475#if defined(HAVE_USBSTACK) && defined(USB_STORAGE)
2476 {"reconnect usb storage",usb_reconnect},
2477#endif
2463#ifdef CPU_BOOST_LOGGING 2478#ifdef CPU_BOOST_LOGGING
2464 {"cpu_boost log",cpu_boost_log}, 2479 {"cpu_boost log",cpu_boost_log},
2465#endif 2480#endif