From 444a9fbcd6b7d6c33fea68187ed81e8729657a2c Mon Sep 17 00:00:00 2001 From: hujun5 Date: Mon, 29 Apr 2024 10:41:17 +0800 Subject: [PATCH] pthread: We should not directly include arch/spinlock.h as it may cause compilation errors in C++. Instead, we should use nuttx/spinlock.h. Signed-off-by: hujun5 --- include/nuttx/spinlock.h | 1 - include/pthread.h | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/include/nuttx/spinlock.h b/include/nuttx/spinlock.h index 8ead10d776..e484c233c0 100644 --- a/include/nuttx/spinlock.h +++ b/include/nuttx/spinlock.h @@ -35,7 +35,6 @@ #include #include -#include #if defined(CONFIG_TICKET_SPINLOCK) || defined(CONFIG_RW_SPINLOCK) # include diff --git a/include/pthread.h b/include/pthread.h index 0418dfacd0..97eca7a536 100644 --- a/include/pthread.h +++ b/include/pthread.h @@ -49,7 +49,7 @@ * SP_LOCKED and SP_UNLOCKED must constants of type spinlock_t. */ -# include +# include #endif /****************************************************************************