summaryrefslogtreecommitdiff
path: root/kernel
diff options
context:
space:
mode:
authorAllan Stephens <allan.stephens@windriver.com>2016-10-07 15:54:11 -0500
committerPeter Mitsis <peter.mitsis@windriver.com>2016-10-13 13:54:00 +0000
commit1d07bd1bffa1f86871d6e6c942847a903965692c (patch)
tree6fd811cfbbe0f68a68249ba659534ebb18f9cd39 /kernel
parent018cd9a65678277834d194a22d62a81c8a50f98b (diff)
unified: Eliminate support for dynamic timers
Gets rid of official support for dynamic timer allocation in the unified kernel, since users can easily define and initialize timers at any time. Legacy support for dynamic timers is maintained for backwards compatibility reasons for the time being ... Change-Id: I12b3e25914fe11e3886065bee4e96fb96f59b299 Signed-off-by: Allan Stephens <allan.stephens@windriver.com>
Diffstat (limited to 'kernel')
-rw-r--r--kernel/unified/timer.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/kernel/unified/timer.c b/kernel/unified/timer.c
index af82085d4..5f9686d7e 100644
--- a/kernel/unified/timer.c
+++ b/kernel/unified/timer.c
@@ -83,6 +83,8 @@ void k_timer_init(struct k_timer *timer, void *data)
#if (CONFIG_NUM_DYNAMIC_TIMERS > 0)
+/* Implements legacy API support for dynamic timers */
+
static struct k_timer _dynamic_timers[CONFIG_NUM_DYNAMIC_TIMERS];
static sys_dlist_t _timer_pool;
@@ -110,7 +112,7 @@ static int init_dyamic_timers(struct device *dev)
*
* @return pointer to the new timer structure
*/
-struct k_timer *k_timer_alloc(void)
+struct k_timer *_k_timer_alloc(void)
{
k_sched_lock();
@@ -133,7 +135,7 @@ struct k_timer *k_timer_alloc(void)
*
* @return N/A
*/
-void k_timer_free(struct k_timer *timer)
+void _k_timer_free(struct k_timer *timer)
{
k_timer_stop(timer);
k_sched_lock();
@@ -147,7 +149,7 @@ void k_timer_free(struct k_timer *timer)
*
* @return true if the timer pool is empty, false otherwise
*/
-bool k_timer_pool_is_empty(void)
+bool _k_timer_pool_is_empty(void)
{
k_sched_lock();