diff options
author | zvecr <git@zvecr.com> | 2022-02-25 23:45:40 +0000 |
---|---|---|
committer | zvecr <git@zvecr.com> | 2022-02-25 23:45:40 +0000 |
commit | e7931289918221081cbe2a7ea5df27a5d86324db (patch) | |
tree | 0b06145520f8aaf5ff5cb928aa5176fc2dd23619 /quantum/ring_buffer.h | |
parent | c0ee3d2c79388187883b1b1b1d1a0b6842acf741 (diff) | |
parent | cf31355f08dca311a013168eb3eb995e2fc6a3d1 (diff) |
Merge remote-tracking branch 'origin/develop'
Diffstat (limited to 'quantum/ring_buffer.h')
-rw-r--r-- | quantum/ring_buffer.h | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/quantum/ring_buffer.h b/quantum/ring_buffer.h index 284745ca8e..85419de11b 100644 --- a/quantum/ring_buffer.h +++ b/quantum/ring_buffer.h @@ -36,9 +36,13 @@ static inline uint8_t rbuf_dequeue(void) { } static inline bool rbuf_has_data(void) { bool has_data; - ATOMIC_BLOCK(ATOMIC_RESTORESTATE) { has_data = (rbuf_head != rbuf_tail); } + ATOMIC_BLOCK(ATOMIC_RESTORESTATE) { + has_data = (rbuf_head != rbuf_tail); + } return has_data; } static inline void rbuf_clear(void) { - ATOMIC_BLOCK(ATOMIC_RESTORESTATE) { rbuf_head = rbuf_tail = 0; } + ATOMIC_BLOCK(ATOMIC_RESTORESTATE) { + rbuf_head = rbuf_tail = 0; + } } |