RTEMS
Main Page
Related Pages
Modules
+
Classes
Class List
Class Index
+
Class Members
+
All
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
y
+
Variables
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
y
+
Files
File List
+
File Members
+
All
_
a
b
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
u
v
w
+
Functions
_
b
c
g
m
p
r
s
t
u
v
+
Variables
_
b
c
r
+
Typedefs
b
c
f
h
i
o
p
r
s
t
u
w
+
Enumerations
c
h
i
m
o
p
r
s
t
w
+
Enumerator
c
h
i
m
p
r
s
t
w
+
Macros
_
a
b
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
w
•
All
Classes
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Macros
Modules
Pages
cpukit
rtems
src
timercancel.c
1
/*
2
* Timer Manager - rtems_timer_cancel directive
3
*
4
*
5
* COPYRIGHT (c) 1989-2007.
6
* On-Line Applications Research Corporation (OAR).
7
*
8
* The license and distribution terms for this file may be
9
* found in the file LICENSE in this distribution or at
10
* http://www.rtems.org/license/LICENSE.
11
*/
12
13
#ifdef HAVE_CONFIG_H
14
#include "config.h"
15
#endif
16
17
#include <
rtems/rtems/timerimpl.h
>
18
19
rtems_status_code
rtems_timer_cancel
(
20
rtems_id
id
21
)
22
{
23
Timer_Control
*the_timer;
24
ISR_lock_Context
lock_context;
25
26
the_timer = _Timer_Get(
id
, &lock_context );
27
if
( the_timer != NULL ) {
28
Per_CPU_Control
*cpu;
29
30
cpu = _Timer_Acquire_critical( the_timer, &lock_context );
31
_Timer_Cancel( cpu, the_timer );
32
_Timer_Release( cpu, &lock_context );
33
return
RTEMS_SUCCESSFUL
;
34
}
35
36
return
RTEMS_INVALID_ID
;
37
}
timerimpl.h
Classic Timer Implementation.
RTEMS_SUCCESSFUL
This status code indicates successful completion.
Definition:
status.h:86
rtems_status_code
rtems_status_code
This enumeration provides status codes for directives of the Classic API.
Definition:
status.h:82
Per_CPU_Control
Per CPU Core Structure.
Definition:
percpu.h:347
RTEMS_INVALID_ID
This status code indicates that an object identifier was invalid.
Definition:
status.h:106
rtems_id
Objects_Id rtems_id
Values of this type identify an RTEMS object.
Definition:
types.h:99
rtems_timer_cancel
rtems_status_code rtems_timer_cancel(rtems_id id)
%
Definition:
timercancel.c:19
ISR_lock_Context
Local ISR lock context for acquire and release pairs.
Definition:
isrlock.h:65
Timer_Control
Definition:
timerdata.h:41
Generated by
1.8.14