diff options
author | gdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4> | 2012-08-14 15:13:41 +0000 |
---|---|---|
committer | gdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4> | 2012-08-14 15:13:41 +0000 |
commit | f0323b067c40d2a7eec4f67942606a371044654f (patch) | |
tree | 60f379f5fb778971f4e91a29c7d188fc241504c0 /os/hal/platforms/STM32/OTGv1 | |
parent | 0bae8867882af833d47fd0f09358fb13d1031570 (diff) | |
download | ChibiOS-f0323b067c40d2a7eec4f67942606a371044654f.tar.gz ChibiOS-f0323b067c40d2a7eec4f67942606a371044654f.tar.bz2 ChibiOS-f0323b067c40d2a7eec4f67942606a371044654f.zip |
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@4569 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'os/hal/platforms/STM32/OTGv1')
-rw-r--r-- | os/hal/platforms/STM32/OTGv1/usb_lld.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/os/hal/platforms/STM32/OTGv1/usb_lld.c b/os/hal/platforms/STM32/OTGv1/usb_lld.c index 34034d7ca..43bc9d17c 100644 --- a/os/hal/platforms/STM32/OTGv1/usb_lld.c +++ b/os/hal/platforms/STM32/OTGv1/usb_lld.c @@ -542,7 +542,7 @@ static void otg_epout_handler(USBDriver *usbp, usbep_t ep) { }
/*===========================================================================*/
-/* Driver interrupt handlers. */
+/* Driver interrupt handlers and threads. */
/*===========================================================================*/
#if STM32_USB_USE_OTG1 || defined(__DOXYGEN__)
@@ -561,28 +561,26 @@ CH_IRQ_HANDLER(STM32_OTG1_HANDLER) { CH_IRQ_PROLOGUE();
sts = OTG->GINTSTS & OTG->GINTMSK;
+ OTG->GINTSTS = sts;
/* Reset interrupt handling.*/
if (sts & GINTSTS_USBRST) {
_usb_reset(usbp);
_usb_isr_invoke_event_cb(usbp, USB_EVENT_RESET);
- OTG->GINTSTS = GINTSTS_USBRST;
}
/* Enumeration done.*/
if (sts & GINTSTS_ENUMDNE) {
(void)OTG->DSTS;
- OTG->GINTSTS = GINTSTS_ENUMDNE;
}
/* SOF interrupt handling.*/
if (sts & GINTSTS_SOF) {
_usb_isr_invoke_sof_cb(usbp);
- OTG->GINTSTS = GINTSTS_SOF;
}
/* RX FIFO not empty handling.*/
- if (sts & GINTMSK_RXFLVLM) {
+ if (sts & GINTSTS_RXFLVL) {
otg_rxfifo_handler(usbp);
}
|