summaryrefslogtreecommitdiff
path: root/payloads/libpayload/drivers/usb/usb.c
diff options
context:
space:
mode:
Diffstat (limited to 'payloads/libpayload/drivers/usb/usb.c')
-rw-r--r--payloads/libpayload/drivers/usb/usb.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/payloads/libpayload/drivers/usb/usb.c b/payloads/libpayload/drivers/usb/usb.c
index 4f423327d5..995b4c2918 100644
--- a/payloads/libpayload/drivers/usb/usb.c
+++ b/payloads/libpayload/drivers/usb/usb.c
@@ -68,6 +68,22 @@ detach_controller (hci_t *controller)
}
/**
+ * Shut down all controllers
+ */
+int
+usb_exit (void)
+{
+ if (usb_hcs == 0)
+ return 0;
+ hci_t *controller = usb_hcs;
+ while (controller != 0) {
+ controller->shutdown(controller);
+ controller = controller->next;
+ }
+ return 0;
+}
+
+/**
* Polls all hubs on all USB controllers, to find out about device changes
*/
void