Commit Graph

1092 Commits

Author SHA1 Message Date
2b1c7730b7 fix hs port1 build with net endpoint 2020-06-16 00:53:06 +07:00
667eaa6dd6 fix stm32h743 priority with freeRTOS 2020-06-16 00:03:52 +07:00
2dd1be13e5 Enhance EP FIFO allocation for both Fullspeed and Highspeed
- Update shared RX FIFO calculation with FS/HS
- IN FIFO EP
  - Interrupt -> use EPSize
  - Bulk/ISO  -> use  max(EPSize, remaining-fifo / non-opened-EPIN)
2020-06-15 23:17:49 +07:00
4399dd1b06 cherry pick PR399 commit : Interrupt time improvements 2020-06-14 19:13:31 +07:00
f438aedccb overwrite setup packet 2020-06-14 18:29:38 +07:00
95966c2201 improve usbd log for control transfer 2020-06-14 18:29:02 +07:00
a347de6e50 revert CFG_TUSB_RHPORT0_MODE to previous way 2020-06-14 18:28:45 +07:00
e92118635c adding speed detect on bus reset 2020-06-01 13:40:18 +07:00
710c54f8cb allow hs ep open with 512 bytes 2020-06-01 01:36:09 +07:00
f771afe6af fixed EP0 size to 64 since LS is not supported in device mode
- set turn-around and report actual speed in Enum Done
- add dcd_event_bus_reset() helper to report speed
2020-05-31 23:43:29 +07:00
5ffba8536d able to detect as hs 2020-05-31 19:41:22 +07:00
d4bf777c94 try to get synopsys work with OTG HS + external PHY 2020-05-27 11:01:33 +07:00
b4804d1592 random clean up for tdi 2020-05-26 22:15:38 +07:00
0482f0d686 update h743eval with rhport=1 highspeed 2020-05-26 22:15:00 +07:00
947c3eb10d multiple port support for global otg base 2020-05-26 16:07:48 +07:00
b7ab60aa44 suporting multiple port (OTG FS + HS) for stm32 2020-05-26 15:52:02 +07:00
fad088719e merge CFG_TUSB_RHPORT1_MODE into CFG_TUSB_RHPORT0_MODE
each port is 1 byte for easy maintenance
2020-05-26 15:21:23 +07:00
ff9994116e fix nrf hanged (blocking wait) when called within critical section 2020-05-21 21:22:12 +07:00
8b66098335 fix freeRTOS logic 2020-05-20 15:21:11 +07:00
a0fe3a80e7 remove queue lock/unlock per review 2020-05-20 15:09:46 +07:00
d8a15aca77 remove osal_queue_t const qhdl from osal API
since it doesn't make any differences.
2020-05-20 14:38:34 +07:00
88a455a9b9 added tud_task_event_ready()
to check if there is pending events in the tud task without executing
it. Useful to check before entering low power mode with WFI/WFE
2020-05-20 14:31:45 +07:00
4e8d414bc6 added osal_queue_empty() API
ported for osal none/freertos/mynewt
2020-05-20 13:38:41 +07:00
550746097b fix cast-align warning for nuc505 2020-05-18 13:03:41 +07:00
1a8ce043ed enable -Wcast-align
suppress vendor sdk driver at board.mk
2020-05-17 14:24:15 +07:00
b0d49e55de refactor copy to and from fifo 2020-05-14 14:24:55 +07:00
46875a3912 Optimize FIFO for byte transfer.
Signed-off-by: Mengsk <admin@hifiphile.com>
2020-05-13 23:54:23 +02:00
4e6aa0d81d Merge pull request #390 from hathach/detect-nrf-softdevice
detect if SD is actually present on the flash using SD magic
2020-05-12 14:35:45 +07:00
f02ad1d0dc Add IAR compiler attribute and endian support. 2020-05-08 13:29:33 +02:00
eeb076454b add CFG_TUSB_DEBUG_PRINTF() for log retargeting 2020-05-08 12:56:32 +07:00
f9f0873b72 Merge pull request #393 from xobs/fix-debug-warning
device: fix build warning when CFG_TUSB_DEBUG >= 2
2020-05-08 12:38:50 +07:00
63bd8d2e44 device: fix build warning when CFG_TUSB_DEBUG >= 2
The function is defined inside of a function body which generates a
warning.  Circuit Python treats these warnings as errors, and so
refuses to build with debugging enabled:

    ../../lib/tinyusb/src/device/usbd_control.c: In function 'usbd_control_xfer_cb':
    ../../lib/tinyusb/src/device/usbd_control.c:195:19: error: nested extern declaration of 'usbd_driver_print_control_complete_name' [-Werror=nested-externs]
      195 |       extern void usbd_driver_print_control_complete_name(bool (*control_complete) (uint8_t, tusb_control_request_t const *));
          |                   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    cc1: all warnings being treated as errors
    make: *** [../../py/mkrules.mk:55:
    build-simmel/lib/tinyusb/src/device/usbd_control.o] Error 1

Move the declaration to the top of the function to silence this warning.

Signed-off-by: Sean Cross <sean@xobs.io>
2020-05-07 19:03:40 +08:00
58b99e59d4 detect if SD is actually present on the flash using SD magic
even with SOFTDEVICE_PRESENT defined, SD may not be present on actual
flash.
2020-05-05 23:07:56 +07:00
101f234a16 Merge pull request #387 from duempel/redesign_transmit_synopsys
Redesign of Synopsys device transmission
2020-05-04 14:41:20 +07:00
fd69cc3dcc clean up
renaming function and variables
changing indent size
2020-05-04 07:59:13 +02:00
0e30afa691 abstract all UDP_CSR 2020-05-02 18:24:23 +07:00
3ad0cd041b clean up 2020-05-02 16:29:22 +07:00
ac3c645dc1 fix EP0 data toggle issue 2020-05-02 16:09:28 +07:00
2a479175ae remove toggle walkaround, fix control stall race condition 2020-05-02 14:51:21 +07:00
a74a823b0a fix dcd samd race condition with setup packet
setup packet can complete together with previous status (in & out).
Always make sure to prepare valid buffer for holding setup packet when
queuing control status.
2020-04-30 00:29:47 +07:00
59ff208c65 Changed switch into if statements 2020-04-29 12:37:29 +02:00
3e6feb7f6d Redesign of Synopsys device transmission
Changes:
  - checking if tx buffer empty interrupt is masked
  - process more than one packet in isr
  - mask tx buffer empty just after all bytes were written
  - use of transmit_fifo_packet instead of transmit_packet
2020-04-29 11:32:22 +02:00
6f4b6a1d03 remove the use of TU_VERIFY_HDLR 2020-04-29 11:31:27 +07:00
d4511186a2 Merge pull request #383 from kasjer/kasjer/fox-busy-flag-race-condition
Fix endpoint busy flag race condition
2020-04-29 10:12:31 +07:00
fcdb22b2f9 fix typo 2020-04-28 10:53:43 +07:00
63cefb7615 Fix endpoint busy flag race condition
Busy flag was set to true after call to dcd_edpt_xfer().
In some cased it was possible that transfer finished before function
ended.
In this case busy flag could be set to false before it was set to
true.
Then setting it to true after dcd_edpt_xfer() made edpoint busy forever.

This change marks endpoint as busy before transfer is started to
avoid race condition.
2020-04-27 16:42:35 +02:00
958b5510cb added comment for hw clearing TXFE 2020-04-27 13:17:47 +07:00
e785b09118 TXFE is read only bit 2020-04-27 12:06:14 +07:00
d0487088ac revert a change to net driver 2020-04-26 23:04:17 +07:00
00fcf829a1 sync synopsis fix for esp32s2 2020-04-26 22:41:04 +07:00