2952 Commits

Author SHA1 Message Date
Jeff Trull
f48ae4aad7 Adjust reserved bitfields to make SDCC happy
- keep each field at or under 16b
- For optimal packing, segment fields to 8b boundaries
2023-02-10 15:54:04 -08:00
hathach
7e48da5b44
update version to 0.15.0
add changelog
2023-02-10 12:47:48 +07:00
hathach
3422e05684
change length in tud_hid_report_complete_cb() from uint8 to uint16 2023-02-04 11:43:23 +07:00
Ha Thach
d6354a2aa7
Merge pull request #1877 from hathach/fix-host-cdc-without-iad
Fix host cdc without iad
2023-02-01 11:18:04 +07:00
Ha Thach
49628d8c18
Merge pull request #1779 from P33M/rp2040_device_babble_fix
rp2040: avoid device-mode state machine hang
2023-01-31 21:38:27 +07:00
hathach
ddb061f639 fix typos 2023-01-31 19:03:31 +07:00
hathach
95403ed9ac fix host issue when mounting an CDC device without IAD 2023-01-31 18:40:07 +07:00
hathach
6759721e9a move errata to end of c file 2023-01-31 17:38:27 +07:00
hathach
19b6cbc616 add e15 prefix or walkaround related functions, also minor refactor 2023-01-31 17:15:42 +07:00
hathach
0cce42fcc6 minor clean up 2023-01-31 11:38:15 +07:00
Ha Thach
b03a688b24
Merge pull request #1768 from ftdigdm/port-ft90x
Port ft90x
2023-01-30 22:13:14 +07:00
hathach
6257123157 Merge branch 'master' into support-iar 2023-01-30 16:44:22 +07:00
hathach
cc18784479 hardcoded configPRIO_BITS for IAR build to pass CI 2023-01-30 16:42:56 +07:00
hathach
6dd40603f9 fix typo 2023-01-30 11:46:52 +07:00
Ha Thach
88f3279c3c
Merge branch 'master' into port-ft90x 2023-01-30 11:40:53 +07:00
Jonathan Bell
0d2078d295 rp2040: shuffle hw_endpoint members
Ordering by element size prevents alignment holes, and as a consequence the
host mode version of the struct is the same size as device, as pad bytes at
the end are used instead.
2023-01-24 12:05:32 +00:00
Jonathan Bell
73b0047efc rp2040: avoid device-mode state machine hang
Don't mark IN buffers as available during the last 200us of a full-speed
frame. This avoids a situation seen with the USB2.0 hub on a Raspberry
Pi 4 where a late IN token before the next full-speed SOF can cause port
babble and a corrupt ACK packet. The nature of the data corruption has a
chance to cause device lockup.

Use the next SOF to mark delayed buffers as available. This reduces
available Bulk IN bandwidth by approximately 20%, and requires that the
SOF interrupt is enabled while these transfers are ongoing.

Inherit the top-level enable from the corresponding Pico-SDK flag.
Applications that will not use the device in a situation where it could
be plugged into a Pi 4 or Pi 400 (for example, when directly connected
to a commodity hub or other host) can turn off the flag in the SDK.

v2: use a field in hw_endpoint to mark pending.

v3: Partial rewrite following review comments

- Stub functions out if the workaround is not required
- Only force-enable SOF while any vulnerable endpoints are active
- Respect dcd_sof_enable() functionality
- Get rid of all but necessary ifdef hackery
- Fix a bug where the "endpoint lock" was used with an uninitialised pointer.
2023-01-24 11:53:28 +00:00
Jonathan Bell
c3e47c31cc rp2040: export hw_endpoint_start_next_buffer() and hw_endpoint_lock_update()
The next change to the driver requires the export of these functions. Leave the
lock unimplemented for now.

Also move hw_set and hw_clear aliases into the top-level header file.
2023-01-23 10:55:20 +00:00
hathach
1bbeb6ad79 update stm32f1 to support iar build 2023-01-21 11:32:37 +07:00
Nathaniel Brough
18c3095346 fix: Change all static variables to thread when fuzzing 2023-01-20 15:45:31 -08:00
hathach
daec3c24d8 fix warnings with arithmetic on void* pointer 2023-01-20 15:30:45 +07:00
hathach
074289caa3 add helper tu_desc_find/find2/find3 2023-01-20 15:30:24 +07:00
Ha Thach
ea098aeda1
Merge pull request #1847 from HiFiPhile/dwc2_iar
dwc2: fix iar warnings
2023-01-18 17:41:33 +07:00
Nathaniel Brough
2e47210c1a fix: Replace device calls to memcpy with tu_memcpy_s
Introduces a new function tu_memcpy_s, which is effectively
a backport of memcpy_s. The change also refactors calls
to memcpy over to the more secure tu_memcpy_s.
2023-01-13 15:20:32 -08:00
Ha Thach
fa9d19027b
Merge pull request #1405 from gregdavill/ch32v307
Add WCH CH32V307 port
2023-01-12 17:51:56 +07:00
hathach
b1021d53f3 add TUP_RHPORT_HIGHSPEED for ch32v307 2023-01-12 15:38:18 +07:00
hathach
3cf21c66b6 add dcd_remote_wakeup() stub 2023-01-12 15:26:48 +07:00
hathach
e61d4aefe6 rename driver with dcd_ to be consitent with other ports 2023-01-12 12:08:56 +07:00
hathach
3cc6cece07 add note for openocd with wch, also add wch-riscv.cfg 2023-01-12 10:25:48 +07:00
MasterPhi
9d19ed940e dwc2: fix IAR warnings. 2023-01-11 18:50:38 +01:00
Ha Thach
8775d55adc
Merge pull request #1843 from HiFiPhile/ip3511
ip3511 : Fix IAR build.
2023-01-09 10:02:59 +07:00
MasterPhi
57de6016f9 ip3511 : Fix IAR build. 2023-01-08 11:23:18 +01:00
Ha Thach
949950e592
Merge branch 'master' into ch32v307 2023-01-07 23:46:46 +07:00
Ha Thach
83cc71feaf
Merge pull request #1820 from Staacks/master
Fix UVC probe and commit on MacOS
2023-01-07 23:30:30 +07:00
hathach
c84de8f06b
minor clean up 2023-01-07 19:40:06 +07:00
hathach
9e551c9f5c
remove _ff_overflowed() due to lack of use 2023-01-07 19:00:04 +07:00
hathach
c29b7643a5
simplify _ff_correct_read_index() 2023-01-07 18:53:00 +07:00
hathach
248025bb6c
reverse idx2ptr() arguments to be consistent 2023-01-07 17:29:43 +07:00
hathach
24bd1c9562
update advance_pointer/backward_pointer to use depth instead of fifo, also rename to advance/backward_index 2023-01-07 17:27:26 +07:00
hathach
507d5b10b0
simplify _tu_fifo_count() and _tu_fifo_remaining(), also rename to _ff_count() and _ff_remaining() 2023-01-07 17:14:17 +07:00
hathach
a804a1ac09
simplify and remove _tu_fifo_empty, _tu_fifo_full. Also correct full condition check 2023-01-07 16:48:07 +07:00
hathach
82457519fa minor clean up 2023-01-07 16:12:35 +07:00
hathach
2a1b81e3c5 minimize tu_fifo size to 16
- remove non_used_index_space
- packed overwritable with item_size
2023-01-06 11:51:17 +07:00
hathach
9c73c1a532 minor clean up 2023-01-06 10:56:19 +07:00
hathach
b42d298b81 Merge branch 'master' into fix-fifo-memory-overflow 2023-01-06 10:52:25 +07:00
Ha Thach
6e23c596cc
Merge pull request #1837 from pete-pjb/master
Fix typo in audio.h. Specifiy _ctrl_xfer struct in CFG_TUSB_MEM_SECTION in usbh.c
2023-01-06 10:24:55 +07:00
Mengsk
8db462bf6e Add fix to dcd_edpt_iso_activate() 2023-01-05 16:54:42 +01:00
Simon Kueppers
d6b612257e Fixed bug where with some devices, the TU_ASSERT inserted with this commit gets triggered for ISOCHRONOUS endpoints. It is necessary for those endpoints to set the NUM_BLOCK and BLSIZE for the receiving buffer in both, USB_COUNTn_TX and USB_COUNTn_RX. Despite the datasheet showing those fields only for the USB_COUNTn_RX register 2023-01-05 16:23:53 +01:00
Mengsk
8c591e2c45 More warning fixes 2023-01-04 12:40:01 +01:00
pete-pjb
f5cffeedec Fix typo in audio.h. Specifiy _ctrl_xfer struct in CFG_TUSB_MEM_SECTION
Add NULL check to loop in list_remove_qhd_by_addr() function in ehci.c
2023-01-03 10:33:36 +00:00