-
cre_mtx
acre_mtx
-
ER cre_mtx (ID mtxid, T_CMTX *pk_cmtx );
ER_ID acre_mtx ( T_CMTX *pk_cmtx );
|
|
|
|
ID mtxid;
|
|
|
T_CMTX *pk_cmtx;
|
Pointer to the packet containing the mutex creation information.
|
[Mutex creation information packet : T_CMTX]
typedef struct t_cmtx {
ATR mtxatr; /*Mutex attribute*/
PRI ceilpri; /*Ceiling priority*/
} T_CMTX;
|
This service call can be called from tasks that belong to
Trusted Domain.
The cre_mtx creates a mutex with mutex ID indicated by
mtxid according to the content of
pk_cmtx. The acre_mtx creates a mutex according to the content of
pk_cmtx, and returns the created mutex ID.
1 ) Mutex attribute (
mtxatr)
Only TA_CEILING can be specified for
mtxatr.
Note Task wait queue is managed in task current priority order. Note, tasks of the same current priority are managed in FIFO order.
2 ) Ceiling priority (
ceilpri)
The current task priority of the task which locks a mutex rises to the
ceilpri.
Ranges of the value that can be specified are from 1 to
TMAX_TPRI.
|
|
|
|
|
Normal completion of acre_mtx. (Created mutex ID)
|
|
|
Normal completion of cre_mtx.
|
|
|
|
|
|
|
|
|
Invalid ID number. (only for cre_mtx)
|
|
|
- This service call was issued in the CPU locked state.
- This service call was issued from non-task.
- This service call was issued in the status "PSW.IPL > kernel interrupt mask level".
|
|
|
- Stack pointer points out of user stack for invoking task.
- The operand-read access to the area indicated by pk_cmtx has not been permitted to the invoking task.
|
|
|
- The invoking task does not belong to trusted domain.
|
|
|
No ID number available.(only for acre_mtx)
|
|
|
Object state error. (only for cre_mtx)
- The mutex specified by mtxid exists.
|