4.115
Last change
on this file since e6f7f81 was
c71b596,
checked in by Sebastian Huber <sebastian.huber@…>, on 07/19/13 at 13:24:04
|
score: Create spinlock implementation header
Move implementation specific parts of corespinlock.h and
corespinlock.inl into new header file corespinlockimpl.h. The
corespinlock.h contains now only the application visible API.
|
-
Property mode set to
100644
|
File size:
840 bytes
|
Line | |
---|
1 | /** |
---|
2 | * @file |
---|
3 | * |
---|
4 | * @brief Initialize a Spinlock |
---|
5 | * |
---|
6 | * @ingroup ScoreSpinlock |
---|
7 | */ |
---|
8 | |
---|
9 | /* |
---|
10 | * COPYRIGHT (c) 1989-2006. |
---|
11 | * On-Line Applications Research Corporation (OAR). |
---|
12 | * |
---|
13 | * The license and distribution terms for this file may be |
---|
14 | * found in the file LICENSE in this distribution or at |
---|
15 | * http://www.rtems.com/license/LICENSE. |
---|
16 | */ |
---|
17 | |
---|
18 | #if HAVE_CONFIG_H |
---|
19 | #include "config.h" |
---|
20 | #endif |
---|
21 | |
---|
22 | #include <rtems/system.h> |
---|
23 | #include <rtems/score/corespinlockimpl.h> |
---|
24 | #include <rtems/score/states.h> |
---|
25 | #include <rtems/score/thread.h> |
---|
26 | #include <rtems/score/threadq.h> |
---|
27 | |
---|
28 | void _CORE_spinlock_Initialize( |
---|
29 | CORE_spinlock_Control *the_spinlock, |
---|
30 | CORE_spinlock_Attributes *the_spinlock_attributes |
---|
31 | ) |
---|
32 | { |
---|
33 | |
---|
34 | the_spinlock->Attributes = *the_spinlock_attributes; |
---|
35 | |
---|
36 | the_spinlock->lock = 0; |
---|
37 | the_spinlock->users = 0; |
---|
38 | the_spinlock->holder = 0; |
---|
39 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.