testhal: add missing sduWakeupHookI() call to KINETIS usb_serial demos
Add the missing call to sduWakeupHookI() to the USB_EVENT_WAKEUP event, with proper locking around them.
This commit is contained in:
parent
2b9cfccc76
commit
b403f064d4
|
@ -289,6 +289,12 @@ static void usb_event(USBDriver *usbp, usbevent_t event) {
|
||||||
chSysUnlockFromISR();
|
chSysUnlockFromISR();
|
||||||
return;
|
return;
|
||||||
case USB_EVENT_WAKEUP:
|
case USB_EVENT_WAKEUP:
|
||||||
|
chSysLockFromISR();
|
||||||
|
|
||||||
|
/* Disconnection event on suspend */
|
||||||
|
sduWakeupHookI(&SDU1);
|
||||||
|
|
||||||
|
chSysUnlockFromISR();
|
||||||
return;
|
return;
|
||||||
case USB_EVENT_STALLED:
|
case USB_EVENT_STALLED:
|
||||||
return;
|
return;
|
||||||
|
|
|
@ -289,6 +289,12 @@ static void usb_event(USBDriver *usbp, usbevent_t event) {
|
||||||
chSysUnlockFromISR();
|
chSysUnlockFromISR();
|
||||||
return;
|
return;
|
||||||
case USB_EVENT_WAKEUP:
|
case USB_EVENT_WAKEUP:
|
||||||
|
chSysLockFromISR();
|
||||||
|
|
||||||
|
/* Disconnection event on suspend */
|
||||||
|
sduWakeupHookI(&SDU1);
|
||||||
|
|
||||||
|
chSysUnlockFromISR();
|
||||||
return;
|
return;
|
||||||
case USB_EVENT_STALLED:
|
case USB_EVENT_STALLED:
|
||||||
return;
|
return;
|
||||||
|
|
|
@ -289,6 +289,12 @@ static void usb_event(USBDriver *usbp, usbevent_t event) {
|
||||||
chSysUnlockFromISR();
|
chSysUnlockFromISR();
|
||||||
return;
|
return;
|
||||||
case USB_EVENT_WAKEUP:
|
case USB_EVENT_WAKEUP:
|
||||||
|
chSysLockFromISR();
|
||||||
|
|
||||||
|
/* Disconnection event on suspend */
|
||||||
|
sduWakeupHookI(&SDU1);
|
||||||
|
|
||||||
|
chSysUnlockFromISR();
|
||||||
return;
|
return;
|
||||||
case USB_EVENT_STALLED:
|
case USB_EVENT_STALLED:
|
||||||
return;
|
return;
|
||||||
|
|
|
@ -289,6 +289,12 @@ static void usb_event(USBDriver *usbp, usbevent_t event) {
|
||||||
chSysUnlockFromISR();
|
chSysUnlockFromISR();
|
||||||
return;
|
return;
|
||||||
case USB_EVENT_WAKEUP:
|
case USB_EVENT_WAKEUP:
|
||||||
|
chSysLockFromISR();
|
||||||
|
|
||||||
|
/* Disconnection event on suspend */
|
||||||
|
sduWakeupHookI(&SDU1);
|
||||||
|
|
||||||
|
chSysUnlockFromISR();
|
||||||
return;
|
return;
|
||||||
case USB_EVENT_STALLED:
|
case USB_EVENT_STALLED:
|
||||||
return;
|
return;
|
||||||
|
|
|
@ -289,6 +289,12 @@ static void usb_event(USBDriver *usbp, usbevent_t event) {
|
||||||
chSysUnlockFromISR();
|
chSysUnlockFromISR();
|
||||||
return;
|
return;
|
||||||
case USB_EVENT_WAKEUP:
|
case USB_EVENT_WAKEUP:
|
||||||
|
chSysLockFromISR();
|
||||||
|
|
||||||
|
/* Disconnection event on suspend */
|
||||||
|
sduWakeupHookI(&SDU1);
|
||||||
|
|
||||||
|
chSysUnlockFromISR();
|
||||||
return;
|
return;
|
||||||
case USB_EVENT_STALLED:
|
case USB_EVENT_STALLED:
|
||||||
return;
|
return;
|
||||||
|
|
Loading…
Reference in New Issue