spinlock: Fix compilation error with atomic.h.

This commit fixed compilation error with atomic.h included.

Signed-off-by: ouyangxiangzhen <ouyangxiangzhen@xiaomi.com>
This commit is contained in:
ouyangxiangzhen 2025-06-11 15:52:44 +08:00 committed by Xiang Xiao
parent 5fee15f4bc
commit 0717928b0e
5 changed files with 6 additions and 5 deletions

View file

@ -30,7 +30,7 @@
#include <nuttx/config.h>
#include <nuttx/irq.h>
#include <nuttx/mutex.h>
#include <nuttx/spinlock.h>
#include <nuttx/spinlock_type.h>
#include <debug.h>
#include <errno.h>

View file

@ -36,7 +36,7 @@
#include <nuttx/macro.h>
#include <nuttx/sched.h>
#include <nuttx/spinlock.h>
#include <nuttx/spinlock_type.h>
/* For system call numbers definition */

View file

@ -37,9 +37,7 @@
#include <nuttx/irq.h>
#include <nuttx/arch.h>
#if defined(CONFIG_TICKET_SPINLOCK) || defined(CONFIG_RW_SPINLOCK)
#include <nuttx/atomic.h>
#endif
#include <nuttx/spinlock_type.h>

View file

@ -40,6 +40,8 @@
#include <nuttx/clock.h>
#include <nuttx/trace.h>
#include <nuttx/spinlock.h>
#include "clock/clock.h"
#ifdef CONFIG_CLOCK_TIMEKEEPING
# include "clock/clock_timekeeping.h"

View file

@ -26,6 +26,7 @@
#include <nuttx/arch.h>
#include <nuttx/notifier.h>
#include <nuttx/spinlock.h>
#include <sys/types.h>