[rtems commit] rtems: Clarify task set/get scheduler parameters

Sebastian Huber sebh at rtems.org
Tue May 20 07:57:50 UTC 2014


Module:    rtems
Branch:    master
Commit:    e5274df1d958a3252dcf3b56b4330047aea552fa
Changeset: http://git.rtems.org/rtems/commit/?id=e5274df1d958a3252dcf3b56b4330047aea552fa

Author:    Sebastian Huber <sebastian.huber at embedded-brains.de>
Date:      Tue May 20 10:03:35 2014 +0200

rtems: Clarify task set/get scheduler parameters

---

 cpukit/rtems/include/rtems/rtems/tasks.h |   12 ++++++------
 cpukit/rtems/src/taskgetscheduler.c      |    4 ++--
 cpukit/rtems/src/tasksetscheduler.c      |    4 ++--
 doc/user/smp.t                           |   12 +++++++-----
 4 files changed, 17 insertions(+), 15 deletions(-)

diff --git a/cpukit/rtems/include/rtems/rtems/tasks.h b/cpukit/rtems/include/rtems/rtems/tasks.h
index a14e865..76653fd 100644
--- a/cpukit/rtems/include/rtems/rtems/tasks.h
+++ b/cpukit/rtems/include/rtems/rtems/tasks.h
@@ -544,8 +544,8 @@ rtems_status_code rtems_task_set_affinity(
 /**
  * @brief Gets the scheduler of a task.
  *
- * @param[in] id Identifier of the task.  Use @ref RTEMS_SELF to select the
- * executing task.
+ * @param[in] task_id Identifier of the task.  Use @ref RTEMS_SELF to select
+ * the executing task.
  * @param[out] scheduler_id Identifier of the scheduler.
  *
  * @retval RTEMS_SUCCESSFUL Successful operation.
@@ -553,7 +553,7 @@ rtems_status_code rtems_task_set_affinity(
  * @retval RTEMS_INVALID_ID Invalid task identifier.
  */
 rtems_status_code rtems_task_get_scheduler(
-  rtems_id  id,
+  rtems_id  task_id,
   rtems_id *scheduler_id
 );
 
@@ -563,8 +563,8 @@ rtems_status_code rtems_task_get_scheduler(
  * The scheduler of a task is initialized to the scheduler of the task that
  * created it.
  *
- * @param[in] id Identifier of the task.  Use @ref RTEMS_SELF to select the
- * executing task.
+ * @param[in] task_id Identifier of the task.  Use @ref RTEMS_SELF to select
+ * the executing task.
  * @param[in] scheduler_id Identifier of the scheduler.
  *
  * @retval RTEMS_SUCCESSFUL Successful operation.
@@ -573,7 +573,7 @@ rtems_status_code rtems_task_get_scheduler(
  * @see rtems_scheduler_ident().
  */
 rtems_status_code rtems_task_set_scheduler(
-  rtems_id id,
+  rtems_id task_id,
   rtems_id scheduler_id
 );
 
diff --git a/cpukit/rtems/src/taskgetscheduler.c b/cpukit/rtems/src/taskgetscheduler.c
index 7111093..47895a4 100644
--- a/cpukit/rtems/src/taskgetscheduler.c
+++ b/cpukit/rtems/src/taskgetscheduler.c
@@ -20,7 +20,7 @@
 #include <rtems/score/schedulerimpl.h>
 
 rtems_status_code rtems_task_get_scheduler(
-  rtems_id  id,
+  rtems_id  task_id,
   rtems_id *scheduler_id
 )
 {
@@ -31,7 +31,7 @@ rtems_status_code rtems_task_get_scheduler(
     Objects_Locations        location;
     const Scheduler_Control *scheduler;
 
-    the_thread = _Thread_Get( id, &location );
+    the_thread = _Thread_Get( task_id, &location );
 
     switch ( location ) {
       case OBJECTS_LOCAL:
diff --git a/cpukit/rtems/src/tasksetscheduler.c b/cpukit/rtems/src/tasksetscheduler.c
index 30c7c6b..e055530 100644
--- a/cpukit/rtems/src/tasksetscheduler.c
+++ b/cpukit/rtems/src/tasksetscheduler.c
@@ -20,7 +20,7 @@
 #include <rtems/score/schedulerimpl.h>
 
 rtems_status_code rtems_task_set_scheduler(
-  rtems_id id,
+  rtems_id task_id,
   rtems_id scheduler_id
 )
 {
@@ -31,7 +31,7 @@ rtems_status_code rtems_task_set_scheduler(
     Thread_Control    *the_thread;
     Objects_Locations  location;
 
-    the_thread = _Thread_Get( id, &location );
+    the_thread = _Thread_Get( task_id, &location );
 
     switch ( location ) {
       case OBJECTS_LOCAL:
diff --git a/doc/user/smp.t b/doc/user/smp.t
index 1844315..a040b70 100644
--- a/doc/user/smp.t
+++ b/doc/user/smp.t
@@ -446,7 +446,7 @@ None.
 @ifset is-C
 @example
 rtems_status_code rtems_task_get_scheduler(
-  rtems_id  id,
+  rtems_id  task_id,
   rtems_id *scheduler_id
 );
 @end example
@@ -463,7 +463,8 @@ rtems_status_code rtems_task_get_scheduler(
 
 @subheading DESCRIPTION:
 
-Returns the scheduler identifier of a task in @code{scheduler_id}.
+Returns the scheduler identifier of a task identified by @code{task_id} in
+ at code{scheduler_id}.
 
 @subheading NOTES:
 
@@ -480,7 +481,7 @@ None.
 @ifset is-C
 @example
 rtems_status_code rtems_task_set_scheduler(
-  rtems_id id,
+  rtems_id task_id,
   rtems_id scheduler_id
 );
 @end example
@@ -498,8 +499,9 @@ perform a scheduler change
 
 @subheading DESCRIPTION:
 
-Sets the scheduler of a task specified by @code{scheduler_id}.  The scheduler
-of a task is initialized to the scheduler of the task that created it.
+Sets the scheduler of a task identified by @code{task_id} to the scheduler
+identified by @code{scheduler_id}.  The scheduler of a task is initialized to
+the scheduler of the task that created it.
 
 @subheading NOTES:
 




More information about the vc mailing list