[rtems commit] posix: Doxygen Enhancement Task #1

Gedare Bloom gedare at rtems.org
Sat Dec 15 12:20:35 UTC 2012


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

Author:    Alex Ivanov <alexivanov97 at gmail.com>
Date:      Sat Dec 15 07:25:05 2012 -0500

posix: Doxygen Enhancement Task #1

http://www.google-melange.com/gci/task/view/google/gci2012/7987220

---

 cpukit/posix/include/mqueue.h                  |   26 ++++++++++++++++++--
 cpukit/posix/include/rtems/posix/mutex.h       |   16 +++++++++++-
 cpukit/posix/include/rtems/posix/priority.h    |   10 ++++++++
 cpukit/posix/include/rtems/posix/psignalimpl.h |   11 ++++++++
 cpukit/posix/include/rtems/posix/rwlock.h      |   10 +++++++-
 cpukit/posix/include/semaphore.h               |   23 ++++++++++++++----
 cpukit/posix/src/adjtime.c                     |   16 +++++++-----
 cpukit/posix/src/condattrgetpshared.c          |   10 ++++++-
 cpukit/posix/src/conddestroy.c                 |   10 ++++++-
 cpukit/posix/src/condsignal.c                  |   10 ++++++-
 cpukit/posix/src/execve.c                      |   12 ++++++++-
 cpukit/posix/src/keycreate.c                   |   10 ++++++-
 cpukit/posix/src/mqueuereceive.c               |   25 +++++--------------
 cpukit/posix/src/mqueuetimedsend.c             |   21 +++-------------
 cpukit/posix/src/mutexattrsettype.c            |    7 +++++
 cpukit/posix/src/mutextranslatereturncode.c    |   20 +++++----------
 cpukit/posix/src/prwlockdestroy.c              |   22 ++++++++--------
 cpukit/posix/src/prwlocktranslatereturncode.c  |   20 +++++----------
 cpukit/posix/src/psignalchecksignal.c          |   12 +++++----
 cpukit/posix/src/pspinlock.c                   |   25 ++++++++++---------
 cpukit/posix/src/psxpriorityisvalid.c          |    7 +++++
 cpukit/posix/src/pthreadatfork.c               |   30 +++++++++++++++--------
 cpukit/posix/src/pthreadattrgetschedpolicy.c   |   12 ++++++++-
 cpukit/posix/src/semdestroy.c                  |   11 +++++---
 cpukit/posix/src/sempost.c                     |   11 +++++---
 cpukit/posix/src/semwait.c                     |   13 +++++----
 26 files changed, 256 insertions(+), 144 deletions(-)

diff --git a/cpukit/posix/include/mqueue.h b/cpukit/posix/include/mqueue.h
index 56a97a0..f41866b 100644
--- a/cpukit/posix/include/mqueue.h
+++ b/cpukit/posix/include/mqueue.h
@@ -2,6 +2,18 @@
  * @file mqueue.h
  *
  * This file contains the definitions related to POSIX Message Queues.
+ * 
+ * The structure of the routines is identical to that of POSIX
+ * Message_queues to leave the option of having unnamed message
+ * queues at a future date.  They are currently not part of the
+ * POSIX standard but unnamed message_queues are.  This is also
+ * the reason for the apparently unnecessary tracking of
+ * the process_shared attribute.  [In addition to the fact that
+ * it would be trivial to add pshared to the mq_attr structure
+ * and have process private message queues.]
+ *
+ * This code ignores the O_RDONLY/O_WRONLY/O_RDWR flag at open
+ * time.
  */
 
 /*
@@ -115,6 +127,13 @@ int mq_send(
 
 #include <time.h>
 
+/**
+ *  @brief Send a Message to a Message Queue
+ * 
+ *  15.2.4 Send a Message to a Message Queue, P1003.1b-1993, p. 277
+ *
+ *  @note P1003.4b/D8, p. 45 adds mq_timedsend().
+ */
 int mq_timedsend(
   mqd_t                  mqdes,
   const char            *msg_ptr,
@@ -125,12 +144,13 @@ int mq_timedsend(
 
 #endif /* _POSIX_TIMEOUTS */
 
-/*
+/**
+ *  @brief Receive a Message From a Message Queue 
+ * 
  *  15.2.5 Receive a Message From a Message Queue, P1003.1b-1993, p. 279
  *
- *  NOTE: P1003.4b/D8, p. 45 adds mq_timedreceive().
+ *  @note P1003.4b/D8, p. 45 adds mq_timedreceive().
  */
-
 ssize_t mq_receive(
   mqd_t         mqdes,
   char         *msg_ptr,
diff --git a/cpukit/posix/include/rtems/posix/mutex.h b/cpukit/posix/include/rtems/posix/mutex.h
index dc133d5..0d73022 100644
--- a/cpukit/posix/include/rtems/posix/mutex.h
+++ b/cpukit/posix/include/rtems/posix/mutex.h
@@ -21,6 +21,14 @@
 extern "C" {
 #endif
 
+/**
+ * @defgroup POSIX_MUTEX POSIX Mutex Support
+ *
+ * @ingroup POSIX
+ *
+ * @brief Private Support Information for POSIX Mutex
+ */
+
 #include <rtems/score/coremutex.h>
 #include <pthread.h>
 
@@ -129,13 +137,17 @@ int _POSIX_Mutex_Lock_support(
   Watchdog_Interval          timeout
 );
 
-/*
- *  _POSIX_Mutex_Translate_core_mutex_return_code
+/**
+ *  @brief POSIX Mutex Translate Core Mutex Return Code
  *
  *  DESCRIPTION:
  *
  *  A support routine which converts core mutex status codes into the
  *  appropriate POSIX status values.
+ * 
+ *  @param[in] the_mutex_status is the mutex status code to translate
+ * 
+ *  @return the translated POSIX status code
  */
 
 int _POSIX_Mutex_Translate_core_mutex_return_code(
diff --git a/cpukit/posix/include/rtems/posix/priority.h b/cpukit/posix/include/rtems/posix/priority.h
index 62ec9fb..a6a3c28 100644
--- a/cpukit/posix/include/rtems/posix/priority.h
+++ b/cpukit/posix/include/rtems/posix/priority.h
@@ -17,6 +17,14 @@
 #ifndef _RTEMS_POSIX_PRIORITY_H
 #define _RTEMS_POSIX_PRIORITY_H
 
+/**
+ * @defgroup POSIX_PRIORITY POSIX Priority Support
+ *
+ * @ingroup POSIX
+ *
+ * @brief Interface to the POSIX Priority Implementation
+ */
+
 #include <rtems/score/priority.h>
 
 /**
@@ -44,6 +52,8 @@
 #define POSIX_SCHEDULER_MINIMUM_PRIORITY (1)
 
 /**
+ *  @brief POSIX Is Priority Valid
+ * 
  *  1003.1b-1993,2.2.2.80 definition of priority, p. 19
  *
  *  "Numerically higher values represent higher priorities."
diff --git a/cpukit/posix/include/rtems/posix/psignalimpl.h b/cpukit/posix/include/rtems/posix/psignalimpl.h
index 6c46f3c..d9ba884 100644
--- a/cpukit/posix/include/rtems/posix/psignalimpl.h
+++ b/cpukit/posix/include/rtems/posix/psignalimpl.h
@@ -16,6 +16,14 @@
 #ifndef _RTEMS_POSIX_PSIGNALIMPL_H
 #define _RTEMS_POSIX_PSIGNALIMPL_H
 
+/**
+ * @defgroup POSIX_SIGNALS POSIX Signals Support
+ *
+ * @ingroup POSIX
+ *
+ * @brief Internal Information about POSIX Signals
+ */
+
 #include <rtems/posix/psignal.h>
 #include <rtems/posix/pthread.h>
 #include <rtems/posix/sigset.h>
@@ -76,6 +84,9 @@ bool _POSIX_signals_Unblock_thread(
   siginfo_t       *info
 );
 
+/**
+ *  @brief POSIX Signals Check Signal
+ */
 bool _POSIX_signals_Check_signal(
   POSIX_API_Control  *api,
   int                 signo,
diff --git a/cpukit/posix/include/rtems/posix/rwlock.h b/cpukit/posix/include/rtems/posix/rwlock.h
index c4f2d7e..411384c 100644
--- a/cpukit/posix/include/rtems/posix/rwlock.h
+++ b/cpukit/posix/include/rtems/posix/rwlock.h
@@ -27,6 +27,14 @@
 extern "C" {
 #endif
 
+/**
+ * @defgroup POSIX_RWLOCK POSIX RWLock Manager
+ *
+ * @ingroup POSIX
+ *
+ * @brief Constants and Structures Associated with the POSIX RWLock Manager
+ */
+
 #include <rtems/score/object.h>
 #include <rtems/score/corerwlock.h>
 
@@ -60,7 +68,7 @@ POSIX_EXTERN Objects_Information  _POSIX_RWLock_Information;
 void _POSIX_RWLock_Manager_initialization(void);
 
 /**
- *  @brief _POSIX_RWLock_Translate_core_RWLock_return_code (
+ *  @brief POSIX RWLock Translate Core RWLock Return Code
  *
  *  This routine translates SuperCore RWLock status codes into the
  *  corresponding POSIX ones.
diff --git a/cpukit/posix/include/semaphore.h b/cpukit/posix/include/semaphore.h
index 9172200..1dc82be 100644
--- a/cpukit/posix/include/semaphore.h
+++ b/cpukit/posix/include/semaphore.h
@@ -21,6 +21,14 @@
 extern "C" {
 #endif
 
+/**
+ * @defgroup POSIX_SEMAPHORE POSIX Semaphores Support
+ *
+ * @ingroup POSIX
+ *
+ * @brief Private Support Information for POSIX Semaphores
+ */
+
 #include <unistd.h>
 
 #if defined(_POSIX_SEMAPHORES)
@@ -46,7 +54,9 @@ int sem_init(
   unsigned int   value
 );
 
-/*
+/**
+ *  @brief Destroy an Unnamed Semaphore
+ * 
  *  11.2.2 Destroy an Unnamed Semaphore, P1003.1b-1993, p.220
  */
 int sem_destroy(
@@ -78,10 +88,12 @@ int sem_unlink(
   const char *name
 );
 
-/*
+/**
+ *  @brief Lock a Semaphore
+ * 
  *  11.2.6 Lock a Semaphore, P1003.1b-1993, p.226
  *
- *  NOTE: P1003.4b/D8 adds sem_timedwait(), p. 27
+ *  @note P1003.4b/D8 adds sem_timedwait(), p. 27
  */
 int sem_wait(
   sem_t *sem
@@ -98,10 +110,11 @@ int sem_timedwait(
 );
 #endif
 
-/*
+/**
+ *  @brief Unlock a Semaphore
+ * 
  *  11.2.7 Unlock a Semaphore, P1003.1b-1993, p.227
  */
-
 int sem_post(
   sem_t  *sem
 );
diff --git a/cpukit/posix/src/adjtime.c b/cpukit/posix/src/adjtime.c
index db88c92..23f7d3a 100644
--- a/cpukit/posix/src/adjtime.c
+++ b/cpukit/posix/src/adjtime.c
@@ -1,9 +1,8 @@
-/*
- *  adjime() function
+/**
+ *  @file
  *
- *  This method was initially added as part of porting NTP to RTEMS.
- *  It is a BSD compatability function and now is available on
- *  GNU/Linux.
+ *  @brief Correct the Time to Synchronize the System Clock
+ *  @ingroup POSIX
  */
 
 /*
@@ -31,12 +30,15 @@
 #include <rtems/score/thread.h>
 #include <rtems/score/timespec.h>
 
-/*
+/**
+ * This method was initially added as part of porting NTP to RTEMS.
+ *  It is a BSD compatability function and now is available on
+ *  GNU/Linux.
+ * 
  *  At one point there was a static variable named adjustment
  *  used by this implementation.  I don't see any reason for it
  *  to be here based upon the GNU/Linux documentation.
  */
-
 int  adjtime(
   const struct timeval *delta,
   struct timeval *olddelta
diff --git a/cpukit/posix/src/condattrgetpshared.c b/cpukit/posix/src/condattrgetpshared.c
index a35f85e..298c261 100644
--- a/cpukit/posix/src/condattrgetpshared.c
+++ b/cpukit/posix/src/condattrgetpshared.c
@@ -1,3 +1,10 @@
+/**
+ *  @file
+ *
+ *  @brief Get the Process-Shared Condition Variable Attributes
+ *  @ingroup POSIX
+ */
+
 /*
  *  COPYRIGHT (c) 1989-2007.
  *  On-Line Applications Research Corporation (OAR).
@@ -22,11 +29,10 @@
 #include <rtems/posix/time.h>
 #include <rtems/posix/mutex.h>
 
-/*
+/**
  *  11.4.1 Condition Variable Initialization Attributes,
  *            P1003.1c/Draft 10, p. 96
  */
-
 int pthread_condattr_getpshared(
   const pthread_condattr_t *attr,
   int                      *pshared
diff --git a/cpukit/posix/src/conddestroy.c b/cpukit/posix/src/conddestroy.c
index 905fb1e..0f32b89 100644
--- a/cpukit/posix/src/conddestroy.c
+++ b/cpukit/posix/src/conddestroy.c
@@ -1,3 +1,10 @@
+/**
+ *  @file
+ *
+ *  @brief Destroy a Condition Variable
+ *  @ingroup POSIX
+ */
+
 /*
  *  COPYRIGHT (c) 1989-2007.
  *  On-Line Applications Research Corporation (OAR).
@@ -22,11 +29,10 @@
 #include <rtems/posix/time.h>
 #include <rtems/posix/mutex.h>
 
-/*
+/**
  *  11.4.2 Initializing and Destroying a Condition Variable,
  *         P1003.1c/Draft 10, p. 87
  */
-
 int pthread_cond_destroy(
   pthread_cond_t           *cond
 )
diff --git a/cpukit/posix/src/condsignal.c b/cpukit/posix/src/condsignal.c
index 8b5c2c9..debc110 100644
--- a/cpukit/posix/src/condsignal.c
+++ b/cpukit/posix/src/condsignal.c
@@ -1,3 +1,10 @@
+/**
+ *  @file
+ *
+ *  @brief Signal a Condition 
+ *  @ingroup POSIX
+ */
+
 /*
  *  COPYRIGHT (c) 1989-2007.
  *  On-Line Applications Research Corporation (OAR).
@@ -22,10 +29,9 @@
 #include <rtems/posix/time.h>
 #include <rtems/posix/mutex.h>
 
-/*
+/**
  *  11.4.3 Broadcasting and Signaling a Condition, P1003.1c/Draft 10, p. 101
  */
-
 int pthread_cond_signal(
   pthread_cond_t   *cond
 )
diff --git a/cpukit/posix/src/execve.c b/cpukit/posix/src/execve.c
index c6f6ede..03320e5 100644
--- a/cpukit/posix/src/execve.c
+++ b/cpukit/posix/src/execve.c
@@ -1,6 +1,11 @@
-/*
- *  execve() - POSIX 1003.1b 3.1.2
+/**
+ *  @file
  *
+ *  @brief Execute a Program
+ *  @ingroup POSIX
+ */
+
+/*
  *  COPYRIGHT (c) 1989-2007.
  *  On-Line Applications Research Corporation (OAR).
  *
@@ -18,6 +23,9 @@
 #include <errno.h>
 #include <rtems/seterr.h>
 
+/**
+ *  POSIX 1003.1b 3.1.2
+ */
 int execve(
   const char *path,
   char *const argv[],
diff --git a/cpukit/posix/src/keycreate.c b/cpukit/posix/src/keycreate.c
index 493b6fb..3ac462d 100644
--- a/cpukit/posix/src/keycreate.c
+++ b/cpukit/posix/src/keycreate.c
@@ -1,3 +1,10 @@
+/**
+ *  @file
+ *
+ *  @brief Thread-Specific Data Key Create
+ *  @ingroup POSIX
+ */
+
 /*
  *  COPYRIGHT (c) 1989-2010.
  *  On-Line Applications Research Corporation (OAR).
@@ -21,10 +28,9 @@
 #include <rtems/score/wkspace.h>
 #include <rtems/posix/key.h>
 
-/*
+/**
  *  17.1.1 Thread-Specific Data Key Create, P1003.1c/Draft 10, p. 163
  */
-
 int pthread_key_create(
   pthread_key_t  *key,
   void          (*destructor)( void * )
diff --git a/cpukit/posix/src/mqueuereceive.c b/cpukit/posix/src/mqueuereceive.c
index 44defc2..c5f9257 100644
--- a/cpukit/posix/src/mqueuereceive.c
+++ b/cpukit/posix/src/mqueuereceive.c
@@ -1,16 +1,11 @@
-/*
- *  NOTE:  The structure of the routines is identical to that of POSIX
- *         Message_queues to leave the option of having unnamed message
- *         queues at a future date.  They are currently not part of the
- *         POSIX standard but unnamed message_queues are.  This is also
- *         the reason for the apparently unnecessary tracking of
- *         the process_shared attribute.  [In addition to the fact that
- *         it would be trivial to add pshared to the mq_attr structure
- *         and have process private message queues.]
- *
- *         This code ignores the O_RDONLY/O_WRONLY/O_RDWR flag at open
- *         time.
+/**
+ *  @file
  *
+ *  @brief Receive a Message From a Message Queue 
+ *  @ingroup POSIX_MQUEUE
+ */
+
+/*
  *  COPYRIGHT (c) 1989-2008.
  *  On-Line Applications Research Corporation (OAR).
  *
@@ -37,12 +32,6 @@
 #include <rtems/posix/mqueue.h>
 #include <rtems/posix/time.h>
 
-/*
- *  15.2.5 Receive a Message From a Message Queue, P1003.1b-1993, p. 279
- *
- *  NOTE: P1003.4b/D8, p. 45 adds mq_timedreceive().
- */
-
 ssize_t mq_receive(
   mqd_t         mqdes,
   char         *msg_ptr,
diff --git a/cpukit/posix/src/mqueuetimedsend.c b/cpukit/posix/src/mqueuetimedsend.c
index f06197f..da7e0e1 100644
--- a/cpukit/posix/src/mqueuetimedsend.c
+++ b/cpukit/posix/src/mqueuetimedsend.c
@@ -1,15 +1,8 @@
-/*
- *  NOTE:  The structure of the routines is identical to that of POSIX
- *         Message_queues to leave the option of having unnamed message
- *         queues at a future date.  They are currently not part of the
- *         POSIX standard but unnamed message_queues are.  This is also
- *         the reason for the apparently unnecessary tracking of
- *         the process_shared attribute.  [In addition to the fact that
- *         it would be trivial to add pshared to the mq_attr structure
- *         and have process private message queues.]
+/**
+ *  @file
  *
- *         This code ignores the O_RDONLY/O_WRONLY/O_RDWR flag at open
- *         time.
+ *  @brief Send a Message to a Message Queue
+ *  @ingroup POSIX_MQUEUE
  */
 
 /*
@@ -39,12 +32,6 @@
 #include <rtems/posix/mqueue.h>
 #include <rtems/posix/time.h>
 
-/*
- *  15.2.4 Send a Message to a Message Queue, P1003.1b-1993, p. 277
- *
- *  NOTE: P1003.4b/D8, p. 45 adds mq_timedsend().
- */
-
 int mq_timedsend(
   mqd_t                  mqdes,
   const char            *msg_ptr,
diff --git a/cpukit/posix/src/mutexattrsettype.c b/cpukit/posix/src/mutexattrsettype.c
index a005747..861e616 100644
--- a/cpukit/posix/src/mutexattrsettype.c
+++ b/cpukit/posix/src/mutexattrsettype.c
@@ -1,3 +1,10 @@
+/**
+ *  @file
+ *
+ *  @brief Set a Mutex Type
+ *  @ingroup POSIX
+ */
+
 /*
  *  COPYRIGHT (c) 1989-2009.
  *  On-Line Applications Research Corporation (OAR).
diff --git a/cpukit/posix/src/mutextranslatereturncode.c b/cpukit/posix/src/mutextranslatereturncode.c
index 53b5b0e..8c2d9af 100644
--- a/cpukit/posix/src/mutextranslatereturncode.c
+++ b/cpukit/posix/src/mutextranslatereturncode.c
@@ -1,6 +1,11 @@
-/*
- *  POSIX Mutex Error Translation
+/**
+ *  @file
  *
+ *  @brief POSIX Mutex Translate Core Mutex Return Code
+ *  @ingroup POSIX_MUTEX
+ */
+
+/*
  *  COPYRIGHT (c) 1989-2008.
  *  On-Line Applications Research Corporation (OAR).
  *
@@ -20,17 +25,6 @@
 #include <rtems/score/coremutex.h>
 #include <rtems/posix/mutex.h>
 
-/*
- *  _POSIX_Mutex_Translate_core_mutex_return_code
- *
- *  Input parameters:
- *    the_mutex_status - mutex status code to translate
- *
- *  Output parameters:
- *    status code - translated POSIX status code
- *
- */
-
 static int _POSIX_Mutex_Return_codes[CORE_MUTEX_STATUS_LAST + 1] = {
   0,                      /* CORE_MUTEX_STATUS_SUCCESSFUL */
   EBUSY,                  /* CORE_MUTEX_STATUS_UNSATISFIED_NOWAIT */
diff --git a/cpukit/posix/src/prwlockdestroy.c b/cpukit/posix/src/prwlockdestroy.c
index 684e173..9b644ba 100644
--- a/cpukit/posix/src/prwlockdestroy.c
+++ b/cpukit/posix/src/prwlockdestroy.c
@@ -1,6 +1,10 @@
-/*
- *  POSIX RWLock Manager -- Destroy a RWLock
+/**
+ *  @file
  *
+ *  @brief Destroy a RWLock
+ *  @ingroup POSIX
+ */
+/*
  *  COPYRIGHT (c) 1989-2007.
  *  On-Line Applications Research Corporation (OAR).
  *
@@ -19,21 +23,17 @@
 #include <rtems/system.h>
 #include <rtems/posix/rwlock.h>
 
-/*
- *  pthread_rwlock_destroy
- *
+/**
  *  This directive allows a thread to delete a rwlock specified by
  *  the rwlock id.  The rwlock is freed back to the inactive
  *  rwlock chain.
  *
- *  Input parameters:
- *    rwlock - rwlock id
+ *  @param[in] rwlock is the rwlock id
  *
- *  Output parameters:
- *    0           - if successful
- *    error code  - if unsuccessful
+ *  @return This method returns 0 if there was not an
+ *  error. Otherwise, a status code is returned indicating the
+ *  source of the error.
  */
-
 int pthread_rwlock_destroy(
   pthread_rwlock_t *rwlock
 )
diff --git a/cpukit/posix/src/prwlocktranslatereturncode.c b/cpukit/posix/src/prwlocktranslatereturncode.c
index 3c75e10..48be176 100644
--- a/cpukit/posix/src/prwlocktranslatereturncode.c
+++ b/cpukit/posix/src/prwlocktranslatereturncode.c
@@ -1,6 +1,11 @@
-/*
- *  RWLock Manager -- Translate SuperCore Status
+/**
+ *  @file
  *
+ *  @brief POSIX RWLock Translate Core RWLock Return Code
+ *  @ingroup POSIX_RWLOCK
+ */
+
+/*
  *  COPYRIGHT (c) 1989-2007.
  *  On-Line Applications Research Corporation (OAR).
  *
@@ -19,17 +24,6 @@
 #include <rtems/system.h>
 #include <rtems/posix/rwlock.h>
 
-/*
- *  _POSIX_RWLock_Translate_core_rwlock_return_code
- *
- *  Input parameters:
- *    the_rwlock_status - rwlock status code to translate
- *
- *  Output parameters:
- *    status code - translated POSIX status code
- *
- */
-
 static int _POSIX_RWLock_Return_codes[CORE_RWLOCK_STATUS_LAST + 1] = {
   0,                        /* CORE_RWLOCK_SUCCESSFUL */
   EINVAL,                   /* CORE_RWLOCK_DELETED */
diff --git a/cpukit/posix/src/psignalchecksignal.c b/cpukit/posix/src/psignalchecksignal.c
index 171d7c8..57237d3 100644
--- a/cpukit/posix/src/psignalchecksignal.c
+++ b/cpukit/posix/src/psignalchecksignal.c
@@ -1,3 +1,10 @@
+/**
+ *  @file
+ *
+ *  @brief POSIX Signals Check Signal
+ *  @ingroup POSIX_SIGNALS
+ */
+
 /*
  *  COPYRIGHT (c) 1989-2007.
  *  On-Line Applications Research Corporation (OAR).
@@ -31,11 +38,6 @@
 #include <rtems/posix/time.h>
 #include <stdio.h>
 
-
-/*
- *  _POSIX_signals_Check_signal
- */
-
 bool    _POSIX_signals_Check_signal(
   POSIX_API_Control  *api,
   int                 signo,
diff --git a/cpukit/posix/src/pspinlock.c b/cpukit/posix/src/pspinlock.c
index ce1a2bb..7f6793c 100644
--- a/cpukit/posix/src/pspinlock.c
+++ b/cpukit/posix/src/pspinlock.c
@@ -1,6 +1,11 @@
-/*
- *  POSIX Spinlock Manager -- Wait at a Spinlock
+/**
+ *  @file
  *
+ *  @brief Wait at a Spinlock
+ *  @ingroup POSIX
+ */
+
+/*
  *  COPYRIGHT (c) 1989-2007.
  *  On-Line Applications Research Corporation (OAR).
  *
@@ -19,19 +24,15 @@
 #include <rtems/system.h>
 #include <rtems/posix/spinlock.h>
 
-/*
- *  pthread_spin_lock
- *
+/**
  *  This directive allows a thread to wait at a spinlock.
  *
- *  Input parameters:
- *    spinlock    - spinlock id
- *
- *  Output parameters:
- *    0          - if successful
- *    error code - if unsuccessful
+ *  @param[in] spinlock is spinlock id
+ * 
+ *  @return This method returns 0 if there was not an
+ *  error. Otherwise, a status code is returned indicating the
+ *  source of the error.
  */
-
 int pthread_spin_lock(
   pthread_spinlock_t *spinlock
 )
diff --git a/cpukit/posix/src/psxpriorityisvalid.c b/cpukit/posix/src/psxpriorityisvalid.c
index 3ef7a1e..eda424e 100644
--- a/cpukit/posix/src/psxpriorityisvalid.c
+++ b/cpukit/posix/src/psxpriorityisvalid.c
@@ -1,3 +1,10 @@
+/**
+ *  @file
+ *
+ *  @brief POSIX Is Priority Valid
+ *  @ingroup POSIX_PRIORITY
+ */
+
 /*
  *  COPYRIGHT (c) 1989-2008.
  *  On-Line Applications Research Corporation (OAR).
diff --git a/cpukit/posix/src/pthreadatfork.c b/cpukit/posix/src/pthreadatfork.c
index 767f113..558bc77 100644
--- a/cpukit/posix/src/pthreadatfork.c
+++ b/cpukit/posix/src/pthreadatfork.c
@@ -1,15 +1,11 @@
-/*
- *  pthread_atfork() - POSIX 1003.1b 3.1.3
- *
- *  3.1.3 Register Fork Handlers, P1003.1c/Draft 10, P1003.1c/Draft 10, p. 27
- *
- *  RTEMS does not support processes, so we fall under this and do not
- *  provide this routine:
- *
- *  "Either the implementation shall support the pthread_atfork() function
- *   as described above or the pthread_atfork() funciton shall not be
- *   provided."
+/**
+ *  @file
  *
+ *  @brief Register Fork Handlers
+ *  @ingroup POSIX
+ */
+
+/*
  *  COPYRIGHT (c) 1989-2007.
  *  On-Line Applications Research Corporation (OAR).
  *
@@ -27,6 +23,18 @@
 #include <errno.h>
 #include <rtems/seterr.h>
 
+/**
+ *  POSIX 1003.1b 3.1.3
+ *
+ *  3.1.3 Register Fork Handlers, P1003.1c/Draft 10, P1003.1c/Draft 10, p. 27
+ *
+ *  RTEMS does not support processes, so we fall under this and do not
+ *  provide this routine:
+ *
+ *  "Either the implementation shall support the pthread_atfork() function
+ *   as described above or the pthread_atfork() funciton shall not be
+ *   provided."
+ */
 int pthread_atfork(
   void (*prepare)(void) __attribute__((unused)),
   void (*parent)(void) __attribute__((unused)),
diff --git a/cpukit/posix/src/pthreadattrgetschedpolicy.c b/cpukit/posix/src/pthreadattrgetschedpolicy.c
index 1a79711..6b57e8a 100644
--- a/cpukit/posix/src/pthreadattrgetschedpolicy.c
+++ b/cpukit/posix/src/pthreadattrgetschedpolicy.c
@@ -1,6 +1,11 @@
-/*
- *  13.5.1 Thread Creation Scheduling Parameters, P1003.1c/Draft 10, p. 120
+/**
+ *  @file
  *
+ *  @brief Get The Schedpolicy Attribute
+ *  @ingroup POSIX
+ */
+
+/*
  *  COPYRIGHT (c) 1989-1999.
  *  On-Line Applications Research Corporation (OAR).
  *
@@ -16,6 +21,9 @@
 #include <pthread.h>
 #include <errno.h>
 
+/**
+ *  13.5.1 Thread Creation Scheduling Parameters, P1003.1c/Draft 10, p. 120
+ */
 int pthread_attr_getschedpolicy(
   const pthread_attr_t  *attr,
   int                   *policy
diff --git a/cpukit/posix/src/semdestroy.c b/cpukit/posix/src/semdestroy.c
index b2a03f5..14ba520 100644
--- a/cpukit/posix/src/semdestroy.c
+++ b/cpukit/posix/src/semdestroy.c
@@ -1,3 +1,10 @@
+/**
+ *  @file
+ *
+ *  @brief Destroy an Unnamed Semaphore
+ *  @ingroup POSIX_SEMAPHORE
+ */
+
 /*
  *  COPYRIGHT (c) 1989-2007.
  *  On-Line Applications Research Corporation (OAR).
@@ -25,10 +32,6 @@
 #include <rtems/posix/time.h>
 #include <rtems/seterr.h>
 
-/*
- *  11.2.2 Destroy an Unnamed Semaphore, P1003.1b-1993, p.220
- */
-
 int sem_destroy(
   sem_t *sem
 )
diff --git a/cpukit/posix/src/sempost.c b/cpukit/posix/src/sempost.c
index e1d6221..7ce3679 100644
--- a/cpukit/posix/src/sempost.c
+++ b/cpukit/posix/src/sempost.c
@@ -1,3 +1,10 @@
+/**
+ *  @file
+ *
+ *  @brief Unlock a Semaphore
+ *  @ingroup POSIX_SEMAPHORE
+ */
+
 /*
  *  COPYRIGHT (c) 1989-2007.
  *  On-Line Applications Research Corporation (OAR).
@@ -25,10 +32,6 @@
 #include <rtems/posix/time.h>
 #include <rtems/seterr.h>
 
-/*
- *  11.2.7 Unlock a Semaphore, P1003.1b-1993, p.227
- */
-
 int sem_post(
   sem_t  *sem
 )
diff --git a/cpukit/posix/src/semwait.c b/cpukit/posix/src/semwait.c
index 32b896a..16fc907 100644
--- a/cpukit/posix/src/semwait.c
+++ b/cpukit/posix/src/semwait.c
@@ -1,3 +1,10 @@
+/**
+ *  @file
+ *
+ *  @brief Lock a Semaphore
+ *  @ingroup POSIX_SEMAPHORE
+ */
+
 /*
  *  COPYRIGHT (c) 1989-2008.
  *  On-Line Applications Research Corporation (OAR).
@@ -25,12 +32,6 @@
 #include <rtems/posix/time.h>
 #include <rtems/seterr.h>
 
-/*
- *  11.2.6 Lock a Semaphore, P1003.1b-1993, p.226
- *
- *  NOTE: P1003.4b/D8 adds sem_timedwait(), p. 27
- */
-
 int sem_wait(
   sem_t *sem
 )




More information about the vc mailing list