summaryrefslogtreecommitdiff
path: root/supervisor
diff options
context:
space:
mode:
Diffstat (limited to 'supervisor')
-rw-r--r--supervisor/shared/usb/usb.c4
-rw-r--r--supervisor/usb.h1
2 files changed, 5 insertions, 0 deletions
diff --git a/supervisor/shared/usb/usb.c b/supervisor/shared/usb/usb.c
index edf810118..3282bd22b 100644
--- a/supervisor/shared/usb/usb.c
+++ b/supervisor/shared/usb/usb.c
@@ -73,6 +73,10 @@ void usb_init(void) {
#endif
}
+void usb_disconnect(void) {
+ tud_disconnect();
+}
+
void usb_background(void) {
if (usb_enabled()) {
#if CFG_TUSB_OS == OPT_OS_NONE
diff --git a/supervisor/usb.h b/supervisor/usb.h
index 29280c725..fb8d5b45f 100644
--- a/supervisor/usb.h
+++ b/supervisor/usb.h
@@ -40,6 +40,7 @@ void init_usb_hardware(void);
// Shared implementation.
bool usb_enabled(void);
void usb_init(void);
+void usb_disconnect(void);
// Propagate plug/unplug events to the MSC logic.
void usb_msc_mount(void);