mirror of
https://github.com/apache/nuttx.git
synced 2026-05-22 05:42:05 +08:00
fix compile error
Error: /github/workspace/sources/nuttx/include/nuttx/spinlock_type.h:57:3: error: unknown type name 'atomic_t' 368 57 | atomic_t owner; 369 | ^~~~~~~~ 370Error: /github/workspace/sources/nuttx/include/nuttx/spinlock_type.h:58:3: error: unknown type name 'atomic_t' 371 58 | atomic_t next; 372 | ^~~~~~~~ Signed-off-by: hujun5 <hujun5@xiaomi.com>
This commit is contained in:
@@ -32,6 +32,7 @@
|
||||
#include <nuttx/kmalloc.h>
|
||||
#include <nuttx/rpmsg/rpmsg.h>
|
||||
#include <nuttx/mutex.h>
|
||||
#include <nuttx/spinlock.h>
|
||||
#include <nuttx/timers/rpmsg_rtc.h>
|
||||
#include <nuttx/timers/arch_rtc.h>
|
||||
|
||||
|
||||
@@ -29,6 +29,10 @@
|
||||
|
||||
#include <nuttx/config.h>
|
||||
|
||||
#if defined(CONFIG_RW_SPINLOCK) || defined(CONFIG_TICKET_SPINLOCK)
|
||||
#include <nuttx/atomic.h>
|
||||
#endif
|
||||
|
||||
#undef EXTERN
|
||||
#if defined(__cplusplus)
|
||||
#define EXTERN extern "C"
|
||||
|
||||
Reference in New Issue
Block a user