Files | |
file | msg.c |
Message handling functions. | |
Functions | |
RT_TASK * | rt_send (RT_TASK *task, unsigned long msg) |
Send a message. | |
RT_TASK * | rt_send_if (RT_TASK *task, unsigned long msg) |
Send a message, only if the calling task will not be blocked. | |
RT_TASK * | rt_send_until (RT_TASK *task, unsigned long msg, RTIME time) |
RT_TASK * | rt_send_timed (RT_TASK *task, unsigned long msg, RTIME delay) |
RT_TASK * | rt_evdrp (RT_TASK *task, void *msg) |
Eavedrop (spy) the content of a message. | |
RT_TASK * | rt_receive (RT_TASK *task, void *msg) |
Receive a message. | |
RT_TASK * | rt_receive_if (RT_TASK *task, void *msg) |
Receive a message, only if the calling task is not blocked. | |
RT_TASK * | rt_receive_until (RT_TASK *task, void *msg, RTIME time) |
Receive a message with an absolute timeout. | |
RT_TASK * | rt_receive_timed (RT_TASK *task, void *msg, RTIME delay) |
Receive a message with a relative timeout. | |
RT_TASK * | rt_sendx (RT_TASK *task, void *msg, int size) |
Send an extended message. | |
RT_TASK * | rt_sendx_if (RT_TASK *task, void *msg, int size) |
Send an extended message, only if the calling task will not be blocked. | |
RT_TASK * | rt_sendx_until (RT_TASK *task, void *msg, int size, RTIME time) |
Send an extended message with absolute timeout. | |
RT_TASK * | rt_sendx_timed (RT_TASK *task, void *msg, int size, RTIME delay) |
Send an extended message with relative timeout. | |
RT_TASK * | rt_evdrpx (RT_TASK *task, void *msg, int size, int *len) |
Eavedrop (spy) the content of an extended message. | |
RT_TASK * | rt_receivex (RT_TASK *task, void *msg, int size, int *len) |
Receive an extended message. | |
RT_TASK * | rt_receivex_if (RT_TASK *task, void *msg, int size, int *len) |
Receive an extended message, only if the calling task is not blocked. | |
RT_TASK * | rt_receivex_until (RT_TASK *task, void *msg, int size, int *len, RTIME time) |
Receive an extended message with an absolute timeout. | |
RT_TASK * | rt_receivex_timed (RT_TASK *task, void *msg, int size, int *len, RTIME delay) |
Receive an extended message with a relative timeout. |
|
Eavedrop (spy) the content of a message. rt_evdrp spies the content of a message from the task specified by task while leaving it on the queue. To actually receive the message any of the rt_receive function must be used specifically. If task is equal to 0, the caller eavdrops the first message of its receive queue, if any. rt_evdrp never blocks.
References MSG_ERR, RT_SCHED_RPC, RT_SCHED_SEND, RT_TASK, and task. Referenced by RT_evdrp(), and rt_evdrpx(). |
|
Eavedrop (spy) the content of an extended message. rt_evdrpx spies the content of a message from the task specified by task while leaving it on the queue. To actually receive the message any of the rt_receivex function must be used specifically. If task is equal to 0, the caller eavdrops the first message of its receive queue, if any. rt_evdrpix never blocks.
References DO_RCV_MSG, rt_evdrp(), RT_TASK, and task. Referenced by RT_evdrpx(). Here is the call graph for this function: ![]() |
|
Receive a message. rt_receive gets a message from the task specified by task. If task is equal to 0, the caller accepts messages from any task. If there is a pending message, rt_receive does not block but can be preempted if the task that rt_sent the just received message has a higher priority. The task will not block if it receives rpced messages since rpcing tasks always waits for a returned message. Moreover it inheredits the highest priority of any rpcing task waiting on the receive queue. The receiving task will then recover its priority as explained in rt_return. Otherwise the caller task is blocked waiting for any message to be sent/rpced.
References cpuid, dequeue_blocked(), enqueue_blocked(), flags, MSG_ERR, rt_return(), RT_SCHED_DELAYED, RT_SCHED_READY, RT_SCHED_RECEIVE, RT_SCHED_RETURN, RT_SCHED_RPC, RT_SCHED_SEND, rt_schedule(), RT_TASK, and task. Referenced by rt_Receive(), RT_receive(), and rt_receivex(). Here is the call graph for this function: ![]() |
|
Receive a message, only if the calling task is not blocked. rt_receive_if tries to get a message from the task specified by task. If task is equal to 0, the caller accepts messages from any task. The caller task is never blocked but can be preempted if the task that rt_sent the just received message has a higher priority. The task will not block if it receives rpced messages since rpcing tasks always waits for a returned message. Moreover it inheredits the highest priority of any rpcing task waiting on the receive queue. The receiving task will then recover its priority as explained in rt_return. Otherwise the caller task is blocked waiting for any message to be sent/rpced.
References cpuid, dequeue_blocked(), enqueue_blocked(), flags, MSG_ERR, rt_return(), RT_SCHED_DELAYED, RT_SCHED_READY, RT_SCHED_RETURN, RT_SCHED_RPC, RT_SCHED_SEND, RT_TASK, and task. Referenced by rt_Creceive(), RT_receive_if(), and rt_receivex_if(). Here is the call graph for this function: ![]() |
|
Receive a message with a relative timeout. rt_receive_timed receives a message from the task specified by task. If task is equal to 0, the caller accepts messages from any task. If there is a pending message, rt_receive does not block but but can be preempted if the task that rt_sent the just received message has a higher priority. The task will not block if it receives rpced messages since rpcing tasks always waits for a returned message. Moreover it inheredits the highest priority of any rpcing task waiting on the receive queue. The receiving task will then recover its priority as explained in rt_return. Otherwise the caller task is blocked waiting for any message to be sent/rpced. In this case these functions return if: a sender sends a message and has a lower priority; any rpced message is received;
References rt_receive_until(), RT_TASK, RTIME, and task. Referenced by rt_Creceive(), RT_receive_timed(), and rt_receivex_timed(). Here is the call graph for this function: ![]() |
|
Receive a message with an absolute timeout. rt_receive_until receives a message from the task specified by task. If task is equal to 0, the caller accepts messages from any task. If there is a pending message, rt_receive does not block but but can be preempted if the task that rt_sent the just received message has a higher priority. The task will not block if it receives rpced messages since rpcing tasks always waits for a returned message. Moreover it inheredits the highest priority of any rpcing task waiting on the receive queue. The receiving task will then recover its priority as explained in rt_return. Otherwise the caller task is blocked waiting for any message to be sent/rpced. In this case these functions return if: a sender sends a message and has a lower priority; any rpced message is received;
References cpuid, dequeue_blocked(), enqueue_blocked(), flags, MSG_ERR, rt_return(), RT_SCHED_DELAYED, RT_SCHED_READY, RT_SCHED_RECEIVE, RT_SCHED_RETURN, RT_SCHED_RPC, RT_SCHED_SEND, rt_schedule(), RT_TASK, RTIME, and task. Referenced by rt_receive_timed(), RT_receive_until(), and rt_receivex_until(). Here is the call graph for this function: ![]() |
|
Receive an extended message. rt_receivex gets an extended message msg of size size from the task specified by task task. If task is equal to 0, the caller accepts messages from any task. If there is a pending message, rt_receivex does not block but can be preempted if the task that rt_sent the just received message has a higher priority. The task will not block if it receives rpcxed messages since rpcxing tasks always wait for a returned message. Moreover it inheredits the highest priority of any rpcxing task waiting on the receive queue. The receiving task will then recover its priority as explained in rt_returnx. Otherwise the caller task is blocked waiting for any message to be sentx/rpcxed.
References DO_RCV_MSG, rt_receive(), RT_TASK, and task. Referenced by RT_receivex(). Here is the call graph for this function: ![]() |
|
Receive an extended message, only if the calling task is not blocked. rt_receivex gets an extended message msg of size size from the task specified by task task. If task is equal to 0, the caller accepts messages from any task. The caller task is never blocked but can be preempted if the task that rt_sentx the just received message has a higher priority. The task will not block if it receives rpcxed messages since rpcxing tasks always wait for a returned message. Moreover it inheredits the highest priority of any rpcxing task waiting on the receive queue. The receiving task will then recover its priority as explained in rt_returnx. Otherwise the caller task is blocked waiting for any message to be sentx/rpcxed.
References DO_RCV_MSG, rt_receive_if(), RT_TASK, and task. Referenced by RT_receivex_if(). Here is the call graph for this function: ![]() |
|
Receive an extended message with a relative timeout. rt_receivex_until gets an extended message msg of size size from the task specified by task task. If task is equal to 0, the caller accepts messages from any task. If there is a pending message, rt_receivex does not block but can be preempted if the task that rt_sent the just received message has a higher priority. The task will not block if it receives rpcxed messages since rpcxing tasks always wait for a returned message. Moreover it inheredits the highest priority of any rpcxing task waiting on the receive queue. The receiving task will then recover its priority as explained in rt_returnx. Otherwise the caller task is blocked waiting for any message to be sentx/rpcxed. In this case these functions return if: a sender sendxs a message and has a lower priority; any rpcxed message is received;
References DO_RCV_MSG, rt_receive_timed(), RT_TASK, RTIME, and task. Referenced by RT_receivex_timed(). Here is the call graph for this function: ![]() |
|
Receive an extended message with an absolute timeout. rt_receivex_until gets an extended message msg of size size from the task specified by task task. If task is equal to 0, the caller accepts messages from any task. If there is a pending message, rt_receivex does not block but can be preempted if the task that rt_sent the just received message has a higher priority. The task will not block if it receives rpcxed messages since rpcxing tasks always wait for a returned message. Moreover it inheredits the highest priority of any rpcxing task waiting on the receive queue. The receiving task will then recover its priority as explained in rt_returnx. Otherwise the caller task is blocked waiting for any message to be sentx/rpcxed. In this case these functions return if: a sender sendxs a message and has a lower priority; any rpcxed message is received;
References DO_RCV_MSG, rt_receive_until(), RT_TASK, RTIME, and task. Referenced by RT_receivex_until(). Here is the call graph for this function: ![]() |
|
Send a message. rt_send sends the message msg to the task task. If the receiver task is ready to get the message rt_send does not block the sending task, but its execution can be preempted if the receiving task has a higher priority. Otherwise the caller task is blocked and queued up in priority order on the receive list of the sent task.
References cpuid, enqueue_blocked(), flags, MSG_ERR, RT_SCHED_DELAYED, RT_SCHED_READY, RT_SCHED_RECEIVE, RT_SCHED_SEND, rt_schedule(), RT_TASK, and task. Referenced by RT_send(), and rt_sendx(). Here is the call graph for this function: ![]() |
|
Send a message, only if the calling task will not be blocked. rt_send_if sends the message msg to the task task if the latter is ready to receive, so that the caller task is never blocked, but its execution can be preempted if the receiving task is ready to receive and has a higher priority.
References cpuid, flags, MSG_ERR, RT_SCHED_DELAYED, RT_SCHED_READY, RT_SCHED_RECEIVE, RT_TASK, and task. Referenced by RT_send_if(), and rt_sendx_if(). |
|
brief Send a message with a relative timeout. rt_send_timed sends the message msg to the task task. If the receiver task is ready to get the message, this function does not block the sending task, but its execution can be preempted if the receiving task has a higher priority. Otherwise the caller task is blocked and queued up in priority order on the receive list of the sent task. In this case the function returns if:
References rt_send_until(), RT_TASK, RTIME, and task. Referenced by RT_send_timed(), and rt_sendx_timed(). Here is the call graph for this function: ![]() |
|
brief Send a message with an absolute timeout. rt_send_until sends the message msg to the task task. If the receiver task is ready to get the message, this function does not block the sending task, but its execution can be preempted if the receiving task has a higher priority. Otherwise the caller task is blocked and queued up in priority order on the receive list of the sent task. In this case the function returns if:
References cpuid, dequeue_blocked(), enqueue_blocked(), flags, MSG_ERR, RT_SCHED_DELAYED, RT_SCHED_READY, RT_SCHED_RECEIVE, RT_SCHED_SEND, rt_schedule(), RT_TASK, RTIME, and task. Referenced by rt_send_timed(), RT_send_until(), and rt_sendx_until(). Here is the call graph for this function: ![]() |
|
Send an extended message. rt_sendx sends an arbitrary message msg of size size bytes to the task task. If the receiver task is ready to get the message rt_sendx does not block the sending task, but its execution can be preempted if the receiving task has a higher priority. Otherwise the caller task is blocked and queued up in priority order on the receive list of the sent task.
References rt_send(), RT_TASK, SET_SEND_MCB, task, and task_mcb. Referenced by RT_sendx(). Here is the call graph for this function: ![]() |
|
Send an extended message, only if the calling task will not be blocked. rt_sendx_if sends an arbitrary message msg of size size bytes to the task task if the latter is ready to receive. So the caller task in never blocked but its execution can be preempted if the receiving task has a higher priority.
References rt_send_if(), RT_TASK, SET_SEND_MCB, task, and task_mcb. Referenced by RT_sendx_if(). Here is the call graph for this function: ![]() |
|
Send an extended message with relative timeout. rt_sendx_until sends an arbitrary message msg of size size bytes to the task task. If the receiver task is ready to get the message rt_sendx_until does not block the sending task, but its execution can be preempted if the receiving task has a higher priority. Otherwise the caller task is blocked and queued up in priority order on the receive list of the sent task. In this case the function returns if:
References rt_send_timed(), RT_TASK, RTIME, SET_SEND_MCB, task, and task_mcb. Referenced by RT_sendx_timed(). Here is the call graph for this function: ![]() |
|
Send an extended message with absolute timeout. rt_sendx_until sends an arbitrary message msg of size size bytes to the task task. If the receiver task is ready to get the message rt_sendx_until does not block the sending task, but its execution can be preempted if the receiving task has a higher priority. Otherwise the caller task is blocked and queued up in priority order on the receive list of the sent task. In this case the function returns if:
References rt_send_until(), RT_TASK, RTIME, SET_SEND_MCB, task, and task_mcb. Referenced by RT_sendx_until(). Here is the call graph for this function: ![]() |