[PATCH] c-user: Fix message manager documentation

Frank Kühndel frank.kuehndel at embedded-brains.de
Wed Sep 15 09:35:05 UTC 2021



On 9/14/21 5:52 PM, Sebastian Huber wrote:
> Remove bogus return status from rtems_message_queue_receive().  Clarify
> rtems_message_queue_flush().
> 
> Close #4508.
> ---
>  c-user/message/directives.rst | 19 ++++++++++---------
>  1 file changed, 10 insertions(+), 9 deletions(-)
> 
> diff --git a/c-user/message/directives.rst b/c-user/message/directives.rst
> index f320350..7317eb4 100644
> --- a/c-user/message/directives.rst
> +++ b/c-user/message/directives.rst
> @@ -891,10 +891,6 @@ queue.
>  :c:macro:`RTEMS_UNSATISFIED`
>      The queue was empty.
>  
> -:c:macro:`RTEMS_UNSATISFIED`
> -    The queue was flushed while the calling task was waiting to receive a
> -    message.
> -
>  :c:macro:`RTEMS_TIMEOUT`
>      The timeout happened while the calling task was waiting to receive a
>      message
> @@ -1039,17 +1035,22 @@ present on the queue, count is set to zero.
>      The ``count`` parameter was `NULL
>      <https://en.cppreference.com/w/c/types/NULL>`_.
>  
> +.. rubric:: NOTES:
> +
> +The directive does not flush tasks waiting to receive a message from the
> +:term:`wait queue` of the message queue.
> +
>  .. rubric:: CONSTRAINTS:
>  
>  The following constraints apply to this directive:
>  
> -* The directive may be called from within task context.
> -
>  * The directive may be called from within interrupt context.
>  
> -* When the directive operates on a remote object, the directive sends a message
> -  to the remote node and waits for a reply.  This will preempt the calling
> -  task.
> +* The directive may be called from within device driver initialization context.
> +
> +* The directive may be called from within task context.
> +
> +* The directive will not cause the calling task to be preempted.
>  
>  .. Generated from spec:/rtems/message/if/buffer

Hi Sebastian,

the text for the `count` parameter needs to be changed too. Currently it
says:

| count
|
|     This parameter is the pointer to an uint32_t object. When the
| directive call is successful, the number of unblocked tasks will be
| stored in this object.

It should instead read:

| count
|
|     This parameter is the pointer to an uint32_t object. When the
| directive call is successful, the number of messages removed will be
| stored in this object.

Greetings
fk






More information about the devel mailing list