You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by xi...@apache.org on 2025/02/06 01:22:49 UTC
(nuttx) branch master updated: clock/clock_adjtime.c: fix compile errors
This is an automated email from the ASF dual-hosted git repository.
xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git
The following commit(s) were added to refs/heads/master by this push:
new 0ae633cc08 clock/clock_adjtime.c: fix compile errors
0ae633cc08 is described below
commit 0ae633cc08120b66ce57a36dd611b3ea3fd6d0d1
Author: Michal Lenc <mi...@seznam.cz>
AuthorDate: Wed Feb 5 14:33:32 2025 +0100
clock/clock_adjtime.c: fix compile errors
The missing <nuttx/spinlock.h> header caused following compile errors:
CC: clock/clock_adjtime.c clock/clock_adjtime.c: In function 'adjtime_wdog_callback':
clock/clock_adjtime.c:67:11: error: implicit declaration of function 'spin_lock_irqsave' [-Wimplicit-function-declaration]
67 | flags = spin_lock_irqsave(&g_adjtime_lock);
| ^~~~~~~~~~~~~~~~~
clock/clock_adjtime.c:78:3: error: implicit declaration of function 'spin_unlock_irqrestore' [-Wimplicit-function-declaration]
78 | spin_unlock_irqrestore(&g_adjtime_lock, flags);
Signed-off-by: Michal Lenc <mi...@seznam.cz>
---
sched/clock/clock_adjtime.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/sched/clock/clock_adjtime.c b/sched/clock/clock_adjtime.c
index c497a773f7..a87e0f1e92 100644
--- a/sched/clock/clock_adjtime.c
+++ b/sched/clock/clock_adjtime.c
@@ -36,6 +36,7 @@
#include <nuttx/irq.h>
#include <nuttx/arch.h>
+#include <nuttx/spinlock.h>
#include "clock/clock.h"