Skip to content

Commit 29d1b64

Browse files
committed
FreeRTOS: associate condition vars with a clock
Signed-off-by: Erik Boasson <[email protected]>
1 parent dc82390 commit 29d1b64

File tree

6 files changed

+189
-200
lines changed

6 files changed

+189
-200
lines changed

src/ddsrt/CMakeLists.txt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -231,8 +231,7 @@ endif()
231231
if(WITH_FREERTOS)
232232
list(APPEND headers
233233
"${source_dir}/include/dds/ddsrt/sync/freertos.h"
234-
"${source_dir}/include/dds/ddsrt/threads/freertos.h"
235-
"${source_dir}/include/dds/ddsrt/time/freertos.h")
234+
"${source_dir}/include/dds/ddsrt/threads/freertos.h")
236235
list(APPEND sources
237236
"${source_dir}/src/environ/posix/environ.c"
238237
"${source_dir}/src/heap/freertos/heap.c"

src/ddsrt/include/dds/ddsrt/sync/freertos.h

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,18 @@ typedef struct {
4545
ddsrt_tasklist_t tasks;
4646
} ddsrt_cond_t;
4747

48+
typedef struct {
49+
ddsrt_cond_t cond;
50+
} ddsrt_cond_wctime_t;
51+
52+
typedef struct {
53+
ddsrt_cond_t cond;
54+
} ddsrt_cond_mtime_t;
55+
56+
typedef struct {
57+
ddsrt_cond_t cond;
58+
} ddsrt_cond_etime_t;
59+
4860
/* This readers-writer lock implementation does not prefer writers over readers
4961
or vice versa. Multiple readers are allowed to hold the lock simultaneously
5062
and can acquire it directly if no writers are queued. However, if a writer

src/ddsrt/include/dds/ddsrt/time.h

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -287,8 +287,4 @@ DDS_EXPORT void ddsrt_etime_to_sec_usec (int32_t *sec, int32_t *usec, ddsrt_etim
287287
}
288288
#endif
289289

290-
#if DDSRT_WITH_FREERTOS
291-
#include "dds/ddsrt/time/freertos.h"
292-
#endif
293-
294290
#endif /* DDSRT_TIME_H */

src/ddsrt/include/dds/ddsrt/time/freertos.h

Lines changed: 0 additions & 52 deletions
This file was deleted.

0 commit comments

Comments
 (0)