summaryrefslogtreecommitdiff
path: root/apps/settings.c
diff options
context:
space:
mode:
authorChristian Gmeiner <christian.gmeiner@gmail.com>2007-09-30 12:25:06 +0000
committerChristian Gmeiner <christian.gmeiner@gmail.com>2007-09-30 12:25:06 +0000
commit0f5d9f9125e53ae62175469e78151ca4cb0be79a (patch)
treef2b1089fd8fe18eeabc36038cb0f8ae9e39c6429 /apps/settings.c
parent6386dbe861bc3395dff1bca5b98e8cbe33ddc703 (diff)
first part of usbstack patches -> show and use selection of usb stack mode only, if
a target supports both modes. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@14916 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/settings.c')
-rw-r--r--apps/settings.c12
1 files changed, 10 insertions, 2 deletions
diff --git a/apps/settings.c b/apps/settings.c
index a020c18e1b..cacf3e5854 100644
--- a/apps/settings.c
+++ b/apps/settings.c
@@ -879,11 +879,19 @@ void settings_apply(void)
if (global_settings.colors_file)
read_color_theme_file();
#endif
-
+
#ifdef HAVE_USBSTACK
+
+#if USBSTACK_CAPS == (CONTROLLER_DEVICE|CONTROLLER_HOST)
usb_controller_select(global_settings.usb_stack_mode);
+#elif USBSTACK_CAPS == (CONTROLLER_DEVICE)
+ usb_controller_select(DEVICE);
+#elif USBSTACK_CAPS == (CONTROLLER_HOST)
+ usb_controller_select(HOST);
+#endif
+
usb_device_driver_bind(global_settings.usb_stack_device_driver);
-#endif
+#endif
}