summaryrefslogtreecommitdiffstats
path: root/cpukit/include/rtems/timecounter.h
diff options
context:
space:
mode:
Diffstat (limited to 'cpukit/include/rtems/timecounter.h')
-rw-r--r--cpukit/include/rtems/timecounter.h45
1 files changed, 29 insertions, 16 deletions
diff --git a/cpukit/include/rtems/timecounter.h b/cpukit/include/rtems/timecounter.h
index d5025d8b1a..891f8d6afd 100644
--- a/cpukit/include/rtems/timecounter.h
+++ b/cpukit/include/rtems/timecounter.h
@@ -1,3 +1,5 @@
+/* SPDX-License-Identifier: BSD-2-Clause */
+
/**
* @file
*
@@ -7,17 +9,28 @@
*/
/*
- * Copyright (c) 2015 embedded brains GmbH. All rights reserved.
+ * Copyright (c) 2015 embedded brains GmbH & Co. KG
*
- * embedded brains GmbH
- * Dornierstr. 4
- * 82178 Puchheim
- * Germany
- * <rtems@embedded-brains.de>
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
*
- * The license and distribution terms for this file may be
- * found in the file LICENSE in this distribution or at
- * http://www.rtems.org/license/LICENSE.
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
+ * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ * POSSIBILITY OF SUCH DAMAGE.
*/
#ifndef _RTEMS_TIMECOUNTER_H
@@ -73,7 +86,7 @@ extern "C" {
* }
* @endcode
*/
-RTEMS_INLINE_ROUTINE void rtems_timecounter_install(
+static inline void rtems_timecounter_install(
struct timecounter *tc
)
{
@@ -83,7 +96,7 @@ RTEMS_INLINE_ROUTINE void rtems_timecounter_install(
/**
* @copydoc _Timecounter_Tick()
*/
-RTEMS_INLINE_ROUTINE void rtems_timecounter_tick(void)
+static inline void rtems_timecounter_tick(void)
{
_Timecounter_Tick();
}
@@ -206,7 +219,7 @@ void rtems_timecounter_simple_install(
*
* @return The scaled value.
*/
-RTEMS_INLINE_ROUTINE uint32_t rtems_timecounter_simple_scale(
+static inline uint32_t rtems_timecounter_simple_scale(
const rtems_timecounter_simple *tc,
uint32_t value
)
@@ -222,7 +235,7 @@ RTEMS_INLINE_ROUTINE uint32_t rtems_timecounter_simple_scale(
* @param[in] at_tick The method to perform work under timecounter lock
* protection at this tick, e.g. clear a pending flag.
*/
-RTEMS_INLINE_ROUTINE void rtems_timecounter_simple_downcounter_tick(
+static inline void rtems_timecounter_simple_downcounter_tick(
rtems_timecounter_simple *tc,
rtems_timecounter_simple_get get,
rtems_timecounter_simple_at_tick at_tick
@@ -251,7 +264,7 @@ RTEMS_INLINE_ROUTINE void rtems_timecounter_simple_downcounter_tick(
* @param[in] at_tick The method to perform work under timecounter lock
* protection at this tick, e.g. clear a pending flag.
*/
-RTEMS_INLINE_ROUTINE void rtems_timecounter_simple_upcounter_tick(
+static inline void rtems_timecounter_simple_upcounter_tick(
rtems_timecounter_simple *tc,
rtems_timecounter_simple_get get,
rtems_timecounter_simple_at_tick at_tick
@@ -278,7 +291,7 @@ RTEMS_INLINE_ROUTINE void rtems_timecounter_simple_upcounter_tick(
* @param[in] is_pending The method which indicates if the interrupt of the
* simple timecounter is pending.
*/
-RTEMS_INLINE_ROUTINE uint32_t rtems_timecounter_simple_downcounter_get(
+static inline uint32_t rtems_timecounter_simple_downcounter_get(
struct timecounter *tc_base,
rtems_timecounter_simple_get get,
rtems_timecounter_simple_is_pending is_pending
@@ -309,7 +322,7 @@ RTEMS_INLINE_ROUTINE uint32_t rtems_timecounter_simple_downcounter_get(
* @param[in] is_pending The method which indicates if the interrupt of the
* simple timecounter is pending.
*/
-RTEMS_INLINE_ROUTINE uint32_t rtems_timecounter_simple_upcounter_get(
+static inline uint32_t rtems_timecounter_simple_upcounter_get(
struct timecounter *tc_base,
rtems_timecounter_simple_get get,
rtems_timecounter_simple_is_pending is_pending