RTEMS Logo

RTEMS 4.7.99.2 On-Line Library


Fixed Block Manager ref_mpf - Reference Fixed-Size Memorypool Status

PREV UP next Bookshelf RTEMS ITRON 3.0 API User's Guide

10.4.7: ref_mpf - Reference Fixed-Size Memorypool Status

CALLING SEQUENCE:

ER ref_mpf(
  T_RMPF *pk_rmpf,
  ID mpfid
);

STATUS CODES:

E_OK - Normal Completion

E_ID - Invalid ID number (mpfid was invalid or could not be used)

E_NOEXS - Object does not exist \(the memorypool specified by mpfid does not exist.)

E_OACV - Object access violation (A mpfid less than -4 was specified from a user task. This is implementation dependent.)

E_PAR - Parameter error (the packet address for the return parameters could not be used)

DESCRIPTION:

This system call refers to the state of the fixed-size memorypool specified by mpfid, and returns the current number of free blocks (frbcnt), information of a task waiting to be allocated memory (wtsk), and its extended information (exinf). Wtsk indicates whether or not there is a task waiting to be allocated memory from the fixed-size memorypool specified. If there is no waiting task, wtsk is returned as FALSE = 0. If there is a waiting task, wtsk is returned as a value other than 0.

NOTES:

While the frsz return parameter of ref_mpl returns the total size of free memory, the frbcnt return parameter of ref_mpf returns the number of free blocks.

Depending on the implementation, additional information besides wtsk and frbcnt (such as memorypool attributes, mpfatr) may also be referred.


PREV UP next Bookshelf RTEMS ITRON 3.0 API User's Guide

Copyright © 1988-2004 OAR Corporation