summaryrefslogtreecommitdiff
path: root/src/common
diff options
context:
space:
mode:
authorhathach <[email protected]>2025-12-12 00:51:57 +0700
committerhathach <[email protected]>2025-12-12 00:51:57 +0700
commit2f5d4dbab3a4b051eda35c7026d2568c7355decd (patch)
treec8d020af17c5e2e14adecd37b04e991d8eccfdef /src/common
parent711879b2f1bcb122c084e6a8bc93c5d2c599ab84 (diff)
fix edpt stream write/read to endpoint not yet opened
Diffstat (limited to 'src/common')
-rw-r--r--src/common/tusb_fifo.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/common/tusb_fifo.c b/src/common/tusb_fifo.c
index ef787c6e6..2faf72ba8 100644
--- a/src/common/tusb_fifo.c
+++ b/src/common/tusb_fifo.c
@@ -289,7 +289,7 @@ static void ff_pull_n(const tu_fifo_t *f, void *app_buf, uint16_t n, uint16_t rd
// Advance an absolute index
// "absolute" index is only in the range of [0..2*depth)
-TU_ATTR_ALWAYS_INLINE static inline uint16_t advance_index(uint16_t depth, uint16_t idx, uint16_t offset) {
+static uint16_t advance_index(uint16_t depth, uint16_t idx, uint16_t offset) {
// We limit the index space of p such that a correct wrap around happens
// Check for a wrap around or if we are in unused index space - This has to be checked first!!
// We are exploiting the wrap around to the correct index
@@ -313,7 +313,7 @@ TU_ATTR_ALWAYS_INLINE static inline uint16_t idx2ptr(uint16_t depth, uint16_t id
// Works on local copies of w
// When an overwritable fifo is overflowed, rd_idx will be re-index so that it forms a full fifo
-TU_ATTR_ALWAYS_INLINE static inline uint16_t correct_read_index(tu_fifo_t *f, uint16_t wr_idx) {
+static uint16_t correct_read_index(tu_fifo_t *f, uint16_t wr_idx) {
uint16_t rd_idx;
if (wr_idx >= f->depth) {
rd_idx = wr_idx - f->depth;