<div dir="ltr"><div dir="ltr"><br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, Feb 2, 2021 at 6:44 AM Sebastian Huber <<a href="mailto:sebastian.huber@embedded-brains.de">sebastian.huber@embedded-brains.de</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Add a "Constraints" paragraph to the documentation.  Use function<br>
prototypes for the directives.<br>
<br>
Update #3993.<br>
---<br>
 c-user/object-services/directives.rst   | 97 +++++++++++++++++--------<br>
 c-user/object-services/introduction.rst |  2 +-<br>
 2 files changed, 66 insertions(+), 33 deletions(-)<br>
<br>
diff --git a/c-user/object-services/directives.rst b/c-user/object-services/directives.rst<br>
index 75a0516..364c7ac 100644<br>
--- a/c-user/object-services/directives.rst<br>
+++ b/c-user/object-services/directives.rst<br>
@@ -1,6 +1,6 @@<br>
 .. SPDX-License-Identifier: CC-BY-SA-4.0<br>
<br>
-.. Copyright (C) 2020 embedded brains GmbH (<a href="http://www.embedded-brains.de" rel="noreferrer" target="_blank">http://www.embedded-brains.de</a>)<br>
+.. Copyright (C) 2020, 2021 embedded brains GmbH (<a href="http://www.embedded-brains.de" rel="noreferrer" target="_blank">http://www.embedded-brains.de</a>)<br>
 .. Copyright (C) 1988, 2009 On-Line Applications Research Corporation (OAR)<br>
<br>
 .. This file is part of the RTEMS quality process and was automatically<br>
@@ -47,14 +47,19 @@ components.<br>
<br>
 .. code-block:: c<br>
<br>
-    #define rtems_build_id( api, class, node, index )<br>
+    rtems_id rtems_build_id(<br>
+      uint32_t api,<br>
+      uint32_t the_class,<br>
+      uint32_t node,<br>
+      uint32_t index<br>
+    );<br>
<br>
 .. rubric:: PARAMETERS:<br>
<br>
 ``api``<br>
     This parameter is the API of the object identifier to build.<br>
<br>
-``class``<br>
+``the_class``<br>
     This parameter is the class of the object identifier to build.<br>
<br>
 ``node``<br>
@@ -68,9 +73,13 @@ components.<br>
 Returns the object identifier built from the API, class, MPCI node, and index<br>
 components.<br>
<br>
-.. rubric:: NOTES:<br>
+.. rubric:: CONSTRAINTS:<br>
<br>
-This directive is strictly local and does not impact task scheduling.<br></blockquote><div><br></div><div>I may have missed the discussion, but this note is being removed without being added elsewhere.</div><div><br></div><div>Is it implied that all functions are local and do not impact task scheduling, unless otherwise constrained?</div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
+The following constraints apply to this directive:<br>
+<br>
+* The directive is implemented by a macro and may be called from within C/C++<br>
+  constant expressions.  In addition, a function implementation of the<br>
+  directive exists for bindings to other programming languages.<br>
<br>
 .. Generated from spec:/rtems/object/if/build-name<br>
<br>
@@ -91,7 +100,7 @@ Builds the object name composed of the four characters.<br>
<br>
 .. code-block:: c<br>
<br>
-    #define rtems_build_name( c1, c2, c3, c4 )<br>
+    rtems_name rtems_build_name( char c1, char c2, char c3, char c4 );<br>
<br>
 .. rubric:: PARAMETERS:<br>
<br>
@@ -117,9 +126,13 @@ least significant 8-bits.<br>
<br>
 Returns the object name composed of the four characters.<br>
<br>
-.. rubric:: NOTES:<br>
+.. rubric:: CONSTRAINTS:<br>
<br>
-This directive is strictly local and does not impact task scheduling.<br>
+The following constraints apply to this directive:<br>
+<br>
+* The directive is implemented by a macro and may be called from within C/C++<br>
+  constant expressions.  In addition, a function implementation of the<br>
+  directive exists for bindings to other programming languages.<br>
<br>
 .. Generated from spec:/rtems/object/if/get-classic-name<br>
<br>
@@ -327,7 +340,7 @@ Gets the API component of the object identifier.<br>
<br>
 .. code-block:: c<br>
<br>
-    #define rtems_object_id_get_api( id )<br>
+    int rtems_object_id_get_api( rtems_id id );<br>
<br>
 .. rubric:: PARAMETERS:<br>
<br>
@@ -340,11 +353,15 @@ Returns the API component of the object identifier.<br>
<br>
 .. rubric:: NOTES:<br>
<br>
-This directive is strictly local and does not impact task scheduling.<br>
-<br>
 This directive does not validate the object identifier provided in ``id``.<br>
<br>
-A body is also provided.<br>
+.. rubric:: CONSTRAINTS:<br>
+<br>
+The following constraints apply to this directive:<br>
+<br>
+* The directive is implemented by a macro and may be called from within C/C++<br>
+  constant expressions.  In addition, a function implementation of the<br>
+  directive exists for bindings to other programming languages.<br>
<br>
 .. Generated from spec:/rtems/object/if/id-get-class<br>
<br>
@@ -365,7 +382,7 @@ Gets the class component of the object identifier.<br>
<br>
 .. code-block:: c<br>
<br>
-    #define rtems_object_id_get_class( id )<br>
+    int rtems_object_id_get_class( rtems_id id );<br>
<br>
 .. rubric:: PARAMETERS:<br>
<br>
@@ -378,11 +395,15 @@ Returns the class component of the object identifier.<br>
<br>
 .. rubric:: NOTES:<br>
<br>
-This directive is strictly local and does not impact task scheduling.<br>
-<br>
 This directive does not validate the object identifier provided in ``id``.<br>
<br>
-A body is also provided.<br>
+.. rubric:: CONSTRAINTS:<br>
+<br>
+The following constraints apply to this directive:<br>
+<br>
+* The directive is implemented by a macro and may be called from within C/C++<br>
+  constant expressions.  In addition, a function implementation of the<br>
+  directive exists for bindings to other programming languages.<br>
<br>
 .. Generated from spec:/rtems/object/if/id-get-node<br>
<br>
@@ -403,7 +424,7 @@ Gets the MPCI node component of the object identifier.<br>
<br>
 .. code-block:: c<br>
<br>
-    #define rtems_object_id_get_node( id )<br>
+    int rtems_object_id_get_node( rtems_id id );<br>
<br>
 .. rubric:: PARAMETERS:<br>
<br>
@@ -417,11 +438,15 @@ Returns the MPCI node component of the object identifier.<br>
<br>
 .. rubric:: NOTES:<br>
<br>
-This directive is strictly local and does not impact task scheduling.<br>
-<br>
 This directive does not validate the object identifier provided in ``id``.<br>
<br>
-A body is also provided.<br>
+.. rubric:: CONSTRAINTS:<br>
+<br>
+The following constraints apply to this directive:<br>
+<br>
+* The directive is implemented by a macro and may be called from within C/C++<br>
+  constant expressions.  In addition, a function implementation of the<br>
+  directive exists for bindings to other programming languages.<br>
<br>
 .. Generated from spec:/rtems/object/if/id-get-index<br>
<br>
@@ -442,7 +467,7 @@ Gets the index component of the object identifier.<br>
<br>
 .. code-block:: c<br>
<br>
-    #define rtems_object_id_get_index( id )<br>
+    int rtems_object_id_get_index( rtems_id id );<br>
<br>
 .. rubric:: PARAMETERS:<br>
<br>
@@ -455,11 +480,15 @@ Returns the index component of the object identifier.<br>
<br>
 .. rubric:: NOTES:<br>
<br>
-This directive is strictly local and does not impact task scheduling.<br>
-<br>
 This directive does not validate the object identifier provided in ``id``.<br>
<br>
-A body is also provided.<br>
+.. rubric:: CONSTRAINTS:<br>
+<br>
+The following constraints apply to this directive:<br>
+<br>
+* The directive is implemented by a macro and may be called from within C/C++<br>
+  constant expressions.  In addition, a function implementation of the<br>
+  directive exists for bindings to other programming languages.<br>
<br>
 .. Generated from spec:/rtems/object/if/id-api-minimum<br>
<br>
@@ -480,17 +509,19 @@ Gets the lowest valid value for the API component of an object identifier.<br>
<br>
 .. code-block:: c<br>
<br>
-    #define rtems_object_id_api_minimum()<br>
+    int rtems_object_id_api_minimum( void );<br>
<br>
 .. rubric:: RETURN VALUES:<br>
<br>
 Returns the lowest valid value for the API component of an object identifier.<br>
<br>
-.. rubric:: NOTES:<br>
+.. rubric:: CONSTRAINTS:<br>
<br>
-This directive is strictly local and does not impact task scheduling.<br>
+The following constraints apply to this directive:<br>
<br>
-A body is also provided.<br>
+* The directive is implemented by a macro and may be called from within C/C++<br>
+  constant expressions.  In addition, a function implementation of the<br>
+  directive exists for bindings to other programming languages.<br>
<br>
 .. Generated from spec:/rtems/object/if/id-api-maximum<br>
<br>
@@ -511,17 +542,19 @@ Gets the highest valid value for the API component of an object identifier.<br>
<br>
 .. code-block:: c<br>
<br>
-    #define rtems_object_id_api_maximum()<br>
+    int rtems_object_id_api_maximum( void );<br>
<br>
 .. rubric:: RETURN VALUES:<br>
<br>
 Returns the highest valid value for the API component of an object identifier.<br>
<br>
-.. rubric:: NOTES:<br>
+.. rubric:: CONSTRAINTS:<br>
<br>
-This directive is strictly local and does not impact task scheduling.<br>
+The following constraints apply to this directive:<br>
<br>
-A body is also provided.<br>
+* The directive is implemented by a macro and may be called from within C/C++<br>
+  constant expressions.  In addition, a function implementation of the<br>
+  directive exists for bindings to other programming languages.<br>
<br>
 .. Generated from spec:/rtems/object/if/api-minimum-class<br>
<br>
diff --git a/c-user/object-services/introduction.rst b/c-user/object-services/introduction.rst<br>
index 6d02c9a..d5a33a4 100644<br>
--- a/c-user/object-services/introduction.rst<br>
+++ b/c-user/object-services/introduction.rst<br>
@@ -1,6 +1,6 @@<br>
 .. SPDX-License-Identifier: CC-BY-SA-4.0<br>
<br>
-.. Copyright (C) 2020 embedded brains GmbH (<a href="http://www.embedded-brains.de" rel="noreferrer" target="_blank">http://www.embedded-brains.de</a>)<br>
+.. Copyright (C) 2020, 2021 embedded brains GmbH (<a href="http://www.embedded-brains.de" rel="noreferrer" target="_blank">http://www.embedded-brains.de</a>)<br>
 .. Copyright (C) 1988, 2009 On-Line Applications Research Corporation (OAR)<br>
<br>
 .. This file is part of the RTEMS quality process and was automatically<br>
-- <br>
2.26.2<br>
<br>
_______________________________________________<br>
devel mailing list<br>
<a href="mailto:devel@rtems.org" target="_blank">devel@rtems.org</a><br>
<a href="http://lists.rtems.org/mailman/listinfo/devel" rel="noreferrer" target="_blank">http://lists.rtems.org/mailman/listinfo/devel</a><br>
</blockquote></div></div>