summaryrefslogtreecommitdiff
path: root/src/portable/st/stm32_fsdev/fsdev_stm32.h
AgeCommit message (Collapse)Author
2026-07-02license: use SPDX identifiers for src/ headers (#3749)Ha Thach
* license: use SPDX identifiers for src/ headers Replace the full ~20-line MIT license boilerplate on every src/ file with a two-line SPDX tag (SPDX-FileCopyrightText + SPDX-License-Identifier), following the REUSE convention used by CircuitPython and the Linux kernel. Removes ~3500 lines of duplicated boilerplate.
2026-06-18fix(stm32_fsdev): don't enable the unused USB wakeup EXTI IRQ (F1/F3/G4/L1)hathach
The classic-USB STM32 fsdev driver enabled the EXTI-line USB wakeup interrupt (USBWakeUp_IRQn, and USBWakeUp_RMP_IRQn on the F3 remap path) in the NVIC, but never uses it: resume is serviced in-band via ISTR.WKUP in the USB_LP/HP ISR, and the driver never arms or clears that EXTI line. The wakeup EXTI interrupt is only needed to wake the core from STOP mode, which TinyUSB does not implement. Leaving its NVIC vector enabled lets it fire spuriously into an unhandled or looping vector -- the freeze reported in #3696 on STM32G473. USBWakeUp_IRQn is a valid, dedicated USB-wakeup-via-EXTI interrupt (e.g. stm32g473xx.h: =42 "USB Wakeup through EXTI line"), not an "unrelated interrupt"; it is simply unused here. - Comment out USBWakeUp_IRQn for F1/F3/G4/L1 and USBWakeUp_RMP_IRQn on the F3 remap path, kept in place so STOP-mode wakeup is a one-line re-enable. - Keep the STM32L1 USBWakeUp_IRQn -> USB_FS_WKUP_IRQn alias for that re-enable. - Document the rationale in fsdev_stm32.h with a TODO. - Comment out the matching USBWakeUp(_RMP)_IRQHandler in the F1/F3/G4 BSPs, and the FreeRTOS NVIC_SetPriority(USBWakeUp_IRQn) on F1/G4. Fixes #3696 Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
2026-05-25optimize interrupt handling timeHiFiPhile
Signed-off-by: HiFiPhile <[email protected]>
2026-05-10add stm32c5 supportHiFiPHile
Signed-off-by: HiFiPHile <[email protected]>
2026-04-17use single volatile counterhathach
2026-04-10debloat the workaroundHiFiPhile
Signed-off-by: HiFiPhile <[email protected]>
2026-04-10Allow STM32 FSDEV delay override macros to satisfy 32-bit guardcopilot-swe-agent[bot]
Agent-Logs-Url: https://github.com/hathach/tinyusb/sessions/b35badc2-444a-4329-b136-f314591cf693 Co-authored-by: HiFiPhile <[email protected]>
2026-04-09Polish FSDEV delay code readabilitycopilot-swe-agent[bot]
Agent-Logs-Url: https://github.com/hathach/tinyusb/sessions/3ec0d5b6-cb8e-48ff-8606-3371beb1efcb Co-authored-by: HiFiPhile <[email protected]>
2026-04-09Clarify STM32U0 delay-default frequency usagecopilot-swe-agent[bot]
Agent-Logs-Url: https://github.com/hathach/tinyusb/sessions/3ec0d5b6-cb8e-48ff-8606-3371beb1efcb Co-authored-by: HiFiPhile <[email protected]>
2026-04-09Restore compile-time guard for STM32 FSDEV delay defaultscopilot-swe-agent[bot]
Agent-Logs-Url: https://github.com/hathach/tinyusb/sessions/3ec0d5b6-cb8e-48ff-8606-3371beb1efcb Co-authored-by: HiFiPhile <[email protected]>
2026-04-09Refactor STM32 FSDEV PMA errata delay into common helpercopilot-swe-agent[bot]
Agent-Logs-Url: https://github.com/hathach/tinyusb/sessions/3ec0d5b6-cb8e-48ff-8606-3371beb1efcb Co-authored-by: HiFiPhile <[email protected]>
2026-03-16clean up fsdev symbolshathach
2026-03-16Unify USB FSDEV driver implementation for various microcontrollers. Replace ↵hathach
`FSDEV_BUS_32BIT` with `CFG_TUSB_FSDEV_32BIT`, adjust data/address stride macros, and refactor register/PMU access for consistency across platforms.
2026-03-16Consolidate USB FSDEV register definitions for STM32, CH32, and AT32 ↵hathach
microcontrollers. Replace vendor-specific macros with unified `U_`-prefixed equivalents, ensuring consistency and reducing duplication across all platforms.
2026-01-06rename FSDEV_PMA_SIZE CFG_TUSB_FSDEV_PMA_SIZEhathach
2025-12-31update tu_fifo to work with fsdev hwfifo with increased address 16/32bithathach
2025-11-26Merge remote-tracking branch 'tinyusb/master' into hcd_fsdevZixun LI
2025-11-25fsdev: reorganize functionsHiFiPhile
Signed-off-by: HiFiPhile <[email protected]>
2025-11-25hcd: add fsdev driverHiFiPhile
Signed-off-by: HiFiPhile <[email protected]>
2025-11-25dcd/fsdev: re-enable SBUF for STM32U0, no more issueZixun LI
2025-11-01add STM32U3 device (adjusted from STM32U0)tswan22
2025-09-29Disable SBUF_ISO for U0Mengsk
Signed-off-by: Mengsk <[email protected]>
2025-09-29Fix PMA size for U0Mengsk
Signed-off-by: Mengsk <[email protected]>
2025-09-12Update commentHiFiPhile
Signed-off-by: HiFiPhile <[email protected]>
2025-06-25stm32_fsdev: Allow configuring single-buffered isochronous endpoints.milek7
Controlled by the embedder defining CFG_TUD_FSDEV_DOUBLE_BUFFERED_ISO_EP in tusb_config.h. If hardware does have SBUF_ISO bit it will use only one half of endpoint pair register.
2024-11-27Add support for the STM32C0 and the NUCLEO-C071RB.David (Pololu)
2024-10-01support stm32U0 deviceHaefner, Martin
2024-08-02more fsdev clean uphathach
hil test boards in parallel
2024-07-31rename to fsdev_type.h, use FSDDEV_REG instead of USBhathach
2024-07-30add edpt0_open(), slightly update dtoghathach
2024-07-30improve set endpointhathach
2024-06-21Merge pull request #2676 from Okarss/fsdev_documentationHa Thach
[FSDEV] Update the STM32 documentation
2024-06-14Update the STM32 documentationOkarss
2024-05-30Use correct backend.Tinic Uro
2024-05-24add ch32 support for fsdev driver. v20x can select fsdev or usbfs with ↵hathach
make/cmake PORT=0/1. default to fsdev