5
Last change
on this file since e292beba was
e292beba,
checked in by Sebastian Huber <sebastian.huber@…>, on 11/07/18 at 09:47:48
|
termios: Move default lock functions
Move rtems_termios_device_lock_acquire_default() and
rtems_termios_device_lock_release_default() to a file separate from the
general Termios support. This avoids complex dependencies in printk()
only scenarios.
|
-
Property mode set to
100644
|
File size:
986 bytes
|
Line | |
---|
1 | /** |
---|
2 | * @file |
---|
3 | * |
---|
4 | * @brief Termios Initialization |
---|
5 | * @ingroup Termios |
---|
6 | */ |
---|
7 | |
---|
8 | /* |
---|
9 | * Author: |
---|
10 | * W. Eric Norum |
---|
11 | * Saskatchewan Accelerator Laboratory |
---|
12 | * University of Saskatchewan |
---|
13 | * Saskatoon, Saskatchewan, CANADA |
---|
14 | * eric@skatter.usask.ca |
---|
15 | * |
---|
16 | * The license and distribution terms for this file may be |
---|
17 | * found in the file LICENSE in this distribution or at |
---|
18 | * http://www.rtems.org/license/LICENSE. |
---|
19 | */ |
---|
20 | |
---|
21 | #if HAVE_CONFIG_H |
---|
22 | #include "config.h" |
---|
23 | #endif |
---|
24 | |
---|
25 | #include <rtems/termiostypes.h> |
---|
26 | |
---|
27 | rtems_mutex rtems_termios_ttyMutex = RTEMS_MUTEX_INITIALIZER( "termios" ); |
---|
28 | |
---|
29 | void |
---|
30 | rtems_termios_device_lock_acquire_default( |
---|
31 | rtems_termios_device_context *ctx, |
---|
32 | rtems_interrupt_lock_context *lock_context |
---|
33 | ) |
---|
34 | { |
---|
35 | rtems_interrupt_lock_acquire (&ctx->lock.interrupt, lock_context); |
---|
36 | } |
---|
37 | |
---|
38 | void |
---|
39 | rtems_termios_device_lock_release_default( |
---|
40 | rtems_termios_device_context *ctx, |
---|
41 | rtems_interrupt_lock_context *lock_context |
---|
42 | ) |
---|
43 | { |
---|
44 | rtems_interrupt_lock_release (&ctx->lock.interrupt, lock_context); |
---|
45 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.