1
10
13
14
20
21
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
77
78
79
84
85
86
87
88
89
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
...
...
...
#define TX_SOURCE_CODE
#include "tx_api.h"
#include "tx_mutex.h"
#include "txm_module.h"
...
...
UINT _txm_module_manager_maximum_module_priority_set(TXM_MODULE_INSTANCE *module_instance, UINT priority)
{
if (_txm_module_manager_ready != TX_TRUE)
{
return(TX_NOT_AVAILABLE);
}if (_txm_module_manager_ready != TX_TRUE) { ... }
if (module_instance == TX_NULL)
{
return(TX_PTR_ERROR);
}if (module_instance == TX_NULL) { ... }
_tx_mutex_get(&_txm_module_manager_mutex, TX_WAIT_FOREVER);
if (module_instance -> txm_module_instance_id != TXM_MODULE_ID)
{
_tx_mutex_put(&_txm_module_manager_mutex);
return(TX_PTR_ERROR);
}if (module_instance -> txm_module_instance_id != TXM_MODULE_ID) { ... }
if ((module_instance -> txm_module_instance_state != TXM_MODULE_LOADED) && (module_instance -> txm_module_instance_state != TXM_MODULE_STOPPED))
{
_tx_mutex_put(&_txm_module_manager_mutex);
return(TX_START_ERROR);
}if ((module_instance -> txm_module_instance_state != TXM_MODULE_LOADED) && (module_instance -> txm_module_instance_state != TXM_MODULE_STOPPED)) { ... }
module_instance->txm_module_instance_maximum_priority = priority;
_tx_mutex_put(&_txm_module_manager_mutex);
return(TX_SUCCESS);
}{ ... }