-
tget_mpl
-
Acquire variable-sized memory block (with time-out).
ER tget_mpl (ID mplid, UINT blksz, VP *p_blk, TMO tmout);
|
|
|
|
ID mplid;
|
ID number of the variable-sized memory pool.
|
|
UINT blksz;
|
Memory block size to be acquired (in bytes).
|
|
VP *p_blk;
|
Start address of the acquired memory block.
|
|
TMO tmout;
|
Specified time-out (in millisecond).
Value: Specified time-out.
|
This service call acquires a variable-size memory block of the size specified by parameter
blksz from the variable-size memory pool specified by parameter
mplid, and stores its start address into the area specified by parameter
p_blk.
If no variable-size memory blocks could be acquired from the target variable-size memory pool (no successive areas equivalent to the requested size were available) when this service call is issued, this service call does not acquire variable-size memory blocks but queues the invoking task to the target variable-size memory pool wait queue and moves it from the RUNNING state to the WAITING state with time-out (variable-size memory block acquisition wait state).
The WAITING state for a variable-sized memory block is cancelled in the following cases.
WAITING State for a Variable-sized Memory Block Cancel Operation
|
|
The variable-size memory block that satisfies the requested size was returned to the target variable-size memory pool as a result of issuing rel_mpl.
|
|
The task at the top of the transmission wait queue was forcedly released from waiting by following either.
- Forced release from waiting (accept rel_wai while waiting).
- Forced release from waiting (accept irel_wai while waiting).
- Forced release from waiting (accept ter_tsk while waiting).
- The time specified by tmout for tget_mpl has elapsed.
|
|
Forced release from waiting (accept rel_wai while waiting).
|
|
Forced release from waiting (accept irel_wai while waiting).
|
|
The variable-sized memory pool is reset as a result of issuing vrst_mpl.
|
|
The time specified by tmout has elapsed.
|
|
Note 2 Invoking tasks are queued to the target variable-size memory pool wait queue in the FIFO order.
Note 3 The contents of the block are undefined.
Note 5
TMO_FEVR is specified for wait time
tmout, processing equivalent to
get_mpl will be executed. When
TMO_POL is specified, processing equivalent to
pget_mpl will be executed.
|
|
|
|
|
|
|
|
- blksz exceeds the maximum size that can be acquired.
|
|
|
|
|
|
- This service call was issued from a non-task.
- This service call was issued in the CPU locked state.
- This service call was issued in the dispatching disabled state.
- This service call was issued in the status "PSW.IPL > kernel interrupt mask level".
|
|
|
Forced release from the WAITING state.
|
|
|
Polling failure or specified time has elapsed.
|
|
|
Released from WAITING state by the object reset ( vrst_mpl)
|