RetroArch
Macros | Typedefs | Functions
message.h File Reference

Thread subsystem II. More...

#include <gctypes.h>
Include dependency graph for message.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define MQ_BOX_NULL   0xffffffff
 
#define MQ_ERROR_SUCCESSFUL   0
 
#define MQ_ERROR_TOOMANY   -5
 
#define MQ_MSG_BLOCK   0
 
#define MQ_MSG_NOBLOCK   1
 

Typedefs

typedef u32 mqbox_t
 typedef for the message queue handle More...
 
typedef voidmqmsg_t
 typedef for the message pointer More...
 

Functions

s32 MQ_Init (mqbox_t *mqbox, u32 count)
 Initializes a message queue. More...
 
void MQ_Close (mqbox_t mqbox)
 Closes the message queue and releases all memory. More...
 
BOOL MQ_Send (mqbox_t mqbox, mqmsg_t msg, u32 flags)
 Sends a message to the given message queue. More...
 
BOOL MQ_Jam (mqbox_t mqbox, mqmsg_t msg, u32 flags)
 Sends a message to the given message queue and jams it in front of the queue. More...
 
BOOL MQ_Receive (mqbox_t mqbox, mqmsg_t *msg, u32 flags)
 Sends a message to the given message queue. More...
 

Detailed Description

Thread subsystem II.

Macro Definition Documentation

◆ MQ_BOX_NULL

#define MQ_BOX_NULL   0xffffffff

◆ MQ_ERROR_SUCCESSFUL

#define MQ_ERROR_SUCCESSFUL   0

◆ MQ_ERROR_TOOMANY

#define MQ_ERROR_TOOMANY   -5

◆ MQ_MSG_BLOCK

#define MQ_MSG_BLOCK   0

◆ MQ_MSG_NOBLOCK

#define MQ_MSG_NOBLOCK   1

Typedef Documentation

◆ mqbox_t

typedef for the message queue handle

◆ mqmsg_t

typedef for the message pointer

Function Documentation

◆ MQ_Close()

void MQ_Close ( mqbox_t  mqbox)

Closes the message queue and releases all memory.

Parameters
[in]mqboxhandle to the mqbox_t structure.
Returns
none
Here is the call graph for this function:
Here is the caller graph for this function:

◆ MQ_Init()

u32 MQ_Init ( mqbox_t mqbox,
u32  count 
)

Initializes a message queue.

Parameters
[out]mqboxpointer to the mqbox_t handle.
[in]countmaximum number of messages the queue can hold
Returns
0 on success, <0 on error
Here is the call graph for this function:
Here is the caller graph for this function:

◆ MQ_Jam()

BOOL MQ_Jam ( mqbox_t  mqbox,
mqmsg_t  msg,
u32  flags 
)

Sends a message to the given message queue and jams it in front of the queue.

Parameters
[in]mqboxmqbox_t handle to the message queue
[in]msgmessage to send
[in]flagsmessage flags (MQ_MSG_BLOCK, MQ_MSG_NOBLOCK)
Returns
bool result
Here is the call graph for this function:

◆ MQ_Receive()

BOOL MQ_Receive ( mqbox_t  mqbox,
mqmsg_t msg,
u32  flags 
)

Sends a message to the given message queue.

Parameters
[in]mqboxmqbox_t handle to the message queue
[in]msgpointer to a mqmsg_t_t-type message to receive.
[in]flagsmessage flags (MQ_MSG_BLOCK, MQ_MSG_NOBLOCK)
Returns
bool result
Here is the call graph for this function:
Here is the caller graph for this function:

◆ MQ_Send()

BOOL MQ_Send ( mqbox_t  mqbox,
mqmsg_t  msg,
u32  flags 
)

Sends a message to the given message queue.

Parameters
[in]mqboxmqbox_t handle to the message queue
[in]msgmessage to send
[in]flagsmessage flags (MQ_MSG_BLOCK, MQ_MSG_NOBLOCK)
Returns
bool result
Here is the call graph for this function:
Here is the caller graph for this function: