diff options
Diffstat (limited to 'c-user/semaphore/directives.rst')
-rw-r--r-- | c-user/semaphore/directives.rst | 45 |
1 files changed, 28 insertions, 17 deletions
diff --git a/c-user/semaphore/directives.rst b/c-user/semaphore/directives.rst index 54f40a4..a0d12a6 100644 --- a/c-user/semaphore/directives.rst +++ b/c-user/semaphore/directives.rst @@ -1,6 +1,6 @@ .. SPDX-License-Identifier: CC-BY-SA-4.0 -.. Copyright (C) 2020, 2021 embedded brains GmbH (http://www.embedded-brains.de) +.. Copyright (C) 2020, 2021 embedded brains GmbH & Co. KG .. Copyright (C) 1988, 2008 On-Line Applications Research Corporation (OAR) .. This file is part of the RTEMS quality process and was automatically @@ -75,9 +75,9 @@ Creates a semaphore. the attribute set. ``id`` - This parameter is the pointer to an object identifier variable. When the - directive call is successful, the identifier of the created semaphore will - be stored in this variable. + This parameter is the pointer to an :ref:`InterfaceRtemsId` object. When + the directive call is successful, the identifier of the created semaphore + will be stored in this object. .. rubric:: DESCRIPTION: @@ -278,9 +278,9 @@ Identifies a semaphore by the object name. This parameter is the node or node set to search for a matching object. ``id`` - This parameter is the pointer to an object identifier variable. When the - directive call is successful, the object identifier of an object with the - specified name will be stored in this variable. + This parameter is the pointer to an :ref:`InterfaceRtemsId` object. When + the directive call is successful, the object identifier of an object with + the specified name will be stored in this object. .. rubric:: DESCRIPTION: @@ -466,9 +466,9 @@ Obtains the semaphore. This parameter is the option set. ``timeout`` - This parameter is the timeout in clock ticks if the :c:macro:`RTEMS_WAIT` - option is set. Use :c:macro:`RTEMS_NO_TIMEOUT` to wait potentially - forever. + This parameter is the timeout in :term:`clock ticks <clock tick>` if the + :c:macro:`RTEMS_WAIT` option is set. Use :c:macro:`RTEMS_NO_TIMEOUT` to + wait potentially forever. .. rubric:: DESCRIPTION: @@ -525,9 +525,17 @@ scheduler. :c:macro:`RTEMS_INVALID_ID` There was no semaphore associated with the identifier specified by ``id``. +:c:macro:`RTEMS_NOT_DEFINED` + The semaphore uses a priority ceiling and there was no priority ceiling + defined for the :term:`home scheduler` of the calling task. + :c:macro:`RTEMS_UNSATISFIED` The semaphore could not be obtained immediately. +:c:macro:`RTEMS_INVALID_PRIORITY` + The semaphore uses a priority ceiling and the calling task had a current + priority less than the priority ceiling. + :c:macro:`RTEMS_INCORRECT_STATE` Acquiring of the local, binary semaphore by the calling task would have cased a deadlock. @@ -686,7 +694,8 @@ The following constraints apply to this directive: * The directive may be called from within task context. -* The directive may unblock another task which may preempt the calling task. +* The directive may unblock a task. This may cause the calling task to be + preempted. * 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 @@ -805,7 +814,8 @@ The following constraints apply to this directive: * The directive may be called from within task context. -* The directive may unblock another task which may preempt the calling task. +* The directive may unblock a task. This may cause the calling task to be + preempted. * 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 @@ -852,9 +862,10 @@ Sets the priority by scheduler for the semaphore. scheduler. ``old_priority`` - This parameter is the pointer to a task priority variable. When the - directive call is successful, the old priority of the semaphore - corresponding to the specified scheduler will be stored in this variable. + This parameter is the pointer to an :ref:`InterfaceRtemsTaskPriority` + object. When the directive call is successful, the old priority of the + semaphore corresponding to the specified scheduler will be stored in this + object. .. rubric:: DESCRIPTION: @@ -1009,5 +1020,5 @@ The following constraints apply to this directive: * The directive may be called from within task context. -* The directive may change the priority of another task which may preempt the - calling task. +* The directive may change the priority of a task. This may cause the calling + task to be preempted. |