vrst_mbf

Outline

Reset message buffer.

C format

 ER      vrst_mbf (ID mbfid);
Parameter(s)

I/O

Parameter

Description

I

 ID      mbfid;
ID number of the message buffer.



Explanation

This service call reset the message buffer specified by parameter mbfid.

The messages having been accumulated by the message buffer area are annulled. The tasks to wait to send message to the target message buffer are released from the WAITING state, and EV_RST is returned as a return value for the tasks.

Note 1 In this service call, the tasks to wait to receive message do not released from the WAITING state.

Note 2 This service call is the function outside mITRON4.0 specification.

Return value

Macro

Value

Description

E_OK

0

Normal completion.

E_ID

-18

Invalid ID number.

- mbfid < 0

- mbfid > VTMAX_MBF

E_CTX

-25

Context error.

- 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 status "PSW.IPL > kernel interrupt mask level".

E_MACV

-26

Memory access violation.

- Stack pointer points out of user stack for invoking task.

E_NOEXS

-42

Non-existent object.

- The message buffer specified by mbfid does not exist.