From 2f572f109a463e7faa46ed544c91198e72e63343 Mon Sep 17 00:00:00 2001 From: gdisirio Date: Sun, 23 Oct 2011 12:21:44 +0000 Subject: USB enhancements, phase two. git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@3451 35acf78f-673a-0410-8e92-d51de3d6d3f4 --- os/hal/include/usb.h | 10 ++++++++++ os/various/shell.c | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) (limited to 'os') diff --git a/os/hal/include/usb.h b/os/hal/include/usb.h index 18842abd3..bc4418f6b 100644 --- a/os/hal/include/usb.h +++ b/os/hal/include/usb.h @@ -321,6 +321,16 @@ typedef const USBDescriptor * (*usbgetdescriptor_t)(USBDriver *usbp, * @name Macro Functions * @{ */ +/** + * @brief Connects the USB device. + */ +#define usbConnectBus(usbp) usb_lld_connect_bus(usbp) + +/** + * @brief Disconnect the USB device. + */ +#define usbDisconnectBus(usbp) usb_lld_disconnect_bus(usbp) + /** * @brief Returns the current frame number. * diff --git a/os/various/shell.c b/os/various/shell.c index a99f2657c..4c84a7b51 100644 --- a/os/various/shell.c +++ b/os/various/shell.c @@ -204,7 +204,7 @@ static msg_t shell_thread(void *p) { there is not a chSysUnlock() because the thread terminates upon return.*/ chSysLock(); chEvtBroadcastI(&shell_terminated); - return msg; + chThdExitS(msg); } /** -- cgit v1.2.3