1
0
mirror of git://projects.qi-hardware.com/ben-wpan.git synced 2025-04-21 12:27:27 +03:00

atusb/fw/usb/: we were busy-looping on TXINI. Mask the interrupt when idle.

- usb/usb.h (usb_ep_change), usb/atu2.c (usb_ep_change): new function
  called by the USB stack to notify the hardware-specific driver of
  an endpoint state change (EP_TX or EP_RX)
- usb/usb.c (usb_io): call usb_ep_change
- usb/atu2.c (handle_ep): mask TXINI if we have nothing to send
This commit is contained in:
Werner Almesberger
2011-06-11 14:17:44 -03:00
parent d03beb2257
commit 376236949b
3 changed files with 13 additions and 0 deletions

View File

@@ -51,6 +51,7 @@ void usb_io(struct ep_descr *ep, enum ep_state state, uint8_t *buf,
ep->end = buf+size;
ep->callback = callback;
ep->user = user;
usb_ep_change(ep);
}