From d26466bf3bbd15d609e471202edb09dbc555fbe6 Mon Sep 17 00:00:00 2001 From: Kenny Levinsen Date: Sat, 1 Aug 2020 23:10:24 +0200 Subject: Remove ALWAYS_INLINE Didn't do what I wanted it to anyway. --- common/connection.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'common/connection.c') diff --git a/common/connection.c b/common/connection.c index 0c2a0b6..a6739c0 100644 --- a/common/connection.c +++ b/common/connection.c @@ -6,22 +6,21 @@ #include #include -#include "compiler.h" #include "connection.h" -ALWAYS_INLINE static uint32_t connection_buffer_mask(const uint32_t idx) { +static inline uint32_t connection_buffer_mask(const uint32_t idx) { return idx & (CONNECTION_BUFFER_SIZE - 1); } -ALWAYS_INLINE static uint32_t connection_buffer_size(const struct connection_buffer *b) { +static inline uint32_t connection_buffer_size(const struct connection_buffer *b) { return b->head - b->tail; } -ALWAYS_INLINE static void connection_buffer_consume(struct connection_buffer *b, const size_t size) { +static inline void connection_buffer_consume(struct connection_buffer *b, const size_t size) { b->tail += size; } -ALWAYS_INLINE static void connection_buffer_restore(struct connection_buffer *b, const size_t size) { +static inline void connection_buffer_restore(struct connection_buffer *b, const size_t size) { b->tail -= size; } -- cgit v1.2.3