4.11
Line | |
---|
1 | /** |
---|
2 | * @file |
---|
3 | * |
---|
4 | * @brief Announce a Clock Tick |
---|
5 | * @ingroup ClassicClock |
---|
6 | */ |
---|
7 | |
---|
8 | /* |
---|
9 | * COPYRIGHT (c) 1989-2009. |
---|
10 | * On-Line Applications Research Corporation (OAR). |
---|
11 | * |
---|
12 | * The license and distribution terms for this file may be |
---|
13 | * found in the file LICENSE in this distribution or at |
---|
14 | * http://www.rtems.org/license/LICENSE. |
---|
15 | */ |
---|
16 | |
---|
17 | #if HAVE_CONFIG_H |
---|
18 | #include "config.h" |
---|
19 | #endif |
---|
20 | |
---|
21 | #include <rtems/rtems/clock.h> |
---|
22 | #include <rtems/score/timecounter.h> |
---|
23 | |
---|
24 | rtems_status_code rtems_clock_tick( void ) |
---|
25 | { |
---|
26 | ISR_lock_Context lock_context; |
---|
27 | |
---|
28 | _Timecounter_Acquire( &lock_context ); |
---|
29 | _Timecounter_Tick_simple( |
---|
30 | rtems_configuration_get_microseconds_per_tick(), |
---|
31 | 0, |
---|
32 | &lock_context |
---|
33 | ); |
---|
34 | |
---|
35 | return RTEMS_SUCCESSFUL; |
---|
36 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.