Function Number | Function |
0x10 | Open message queue |
0x1E | Open re-entrant message port (no queue) |
0x1F | Open system message port (no queue) |
0x20 | Send Message |
0x30 | Get message (with waiting) |
0x31 | Check for message (without waiting) |
This opens a message queue for the current thread. The message queue belongs to the current thread (you can't get a message from the queue unless you do it using the correct thread).
Input
None
Output
EBX Message port ID
AL Status
0x1E Open re-entrant message port (no queue)
This opens a re-entrant message port. When a message is sent to a message port the code attached to the message port is called via a far call. Code called in this way should be as quick as storing a message on a queue if possible (the message sender waits).
Input
EBX Address (EIP)
CX Code ID (CS)
Output
EBX Message port ID
AL Status
0x1F Open system message port (no queue)
This opens a message port that is not re-entrant. When a message is sent to a message port the code attached to the message port is called via a far call. Code called in this way should be as quick as storing a message on a queue if possible (the message sender waits). Unlike function 0x1E the kernel will prevent 2 threads from calling the attached code at the same time.
Input
EBX Address (EIP)
CX Code ID (CS)
Output
EBX Message port ID
AL Status
This sends a message from one message port to another message port..
Input
EBX Senders ID
ECX Address of message buffer
EDX Receivers ID
Output
AL Status
0x30 Get message (with waiting)
This function waits until a message arrives and copies it into the message buffer. The message is removed from the queue.
Input
EBX Message Port ID
ECX Address of message buffer
Output
EBX Senders message port ID
AL Status
0x31
Check for message (without waiting)
This function will copy a message from a queue into a buffer (like function 0x30) but rather than waiting for a message (if the queue is empty) it returns an error. If a message is returned it is removed from the queue.
Input
EBX Message Port ID
ECX Address of message buffer
Output
EBX Senders message port ID
AL Status