summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGregory Nutt <gnutt@nuttx.org>2014-08-28 17:00:03 -0600
committerGregory Nutt <gnutt@nuttx.org>2014-08-28 17:00:03 -0600
commit980f811a45007e70b9c524ea48d2ca098e271e39 (patch)
treecfbf04d8148f5b07c34de4424b0a1d8e2f97ce8f
parent03bee97af3131ec0fa3d3d56be10296c197634bd (diff)
downloadnuttx-980f811a45007e70b9c524ea48d2ca098e271e39.tar.gz
nuttx-980f811a45007e70b9c524ea48d2ca098e271e39.tar.bz2
nuttx-980f811a45007e70b9c524ea48d2ca098e271e39.zip
In some configurations, g_system_tmer must be extern'ed as a private variable
-rw-r--r--nuttx/sched/clock/clock.h17
1 files changed, 14 insertions, 3 deletions
diff --git a/nuttx/sched/clock/clock.h b/nuttx/sched/clock/clock.h
index 976ec117f..f875d3e84 100644
--- a/nuttx/sched/clock/clock.h
+++ b/nuttx/sched/clock/clock.h
@@ -66,14 +66,25 @@
/********************************************************************************
* Global Variables
********************************************************************************/
+#if !defined(CONFIG_SCHED_TICKLESS) && __HAVE_KERNEL_GLOBALS == 0
+ /* The system clock exists (CONFIG_SCHED_TICKLESS), but it not prototyped
+ * globally in include/nuttx/clock.h.
+ */
+
+# ifdef CONFIG_SYSTEM_TIME64
+extern volatile uint64_t g_system_timer;
+# else
+extern volatile uint32_t g_system_timer;
+# endif
+#endif
#ifdef CONFIG_SYSTEM_TIME64
-extern uint64_t g_tickbias;
+extern uint64_t g_tickbias;
#else
-extern uint32_t g_tickbias;
+extern uint32_t g_tickbias;
#endif
-extern struct timespec g_basetime;
+extern struct timespec g_basetime;
/********************************************************************************
* Public Function Prototypes