Module: xenomai-forge Branch: next Commit: f957b8e1c18a07b27afb66de2ade2b3136f7f6b8 URL: http://git.xenomai.org/?p=xenomai-forge.git;a=commit;h=f957b8e1c18a07b27afb66de2ade2b3136f7f6b8
Author: Philippe Gerum <r...@xenomai.org> Date: Wed Jun 11 19:59:31 2014 +0200 doc: general fixup of the doxygen-based contents hierarchy (WIP) --- include/cobalt/kernel/rtdm/driver.h | 159 ++++++++++++++++++++--------------- kernel/cobalt/rtdm/drvlib.c | 30 +++---- kernel/cobalt/synch.c | 4 +- kernel/cobalt/thread.c | 2 + lib/alchemy/alarm.c | 3 + lib/alchemy/buffer.c | 3 + lib/alchemy/cond.c | 22 +++-- lib/alchemy/event.c | 5 +- lib/alchemy/heap.c | 3 + lib/alchemy/mutex.c | 7 +- lib/alchemy/pipe.c | 18 ++++ lib/alchemy/queue.c | 8 ++ lib/alchemy/sem.c | 7 +- 13 files changed, 174 insertions(+), 97 deletions(-) diff --git a/include/cobalt/kernel/rtdm/driver.h b/include/cobalt/kernel/rtdm/driver.h index 2898e10..68bcabc 100644 --- a/include/cobalt/kernel/rtdm/driver.h +++ b/include/cobalt/kernel/rtdm/driver.h @@ -550,6 +550,7 @@ static inline void rtdm_lock_put(rtdm_lock_t *lock) } /** + * @fn void rtdm_lock_get_irqsave(rtdm_lock_t *lock, rtdm_lockctx_t context) * Acquire lock and disable preemption, by stalling the head domain. * * @param lock Address of lock variable @@ -568,16 +569,16 @@ static inline void rtdm_lock_put(rtdm_lock_t *lock) */ static inline rtdm_lockctx_t __rtdm_lock_get_irqsave(rtdm_lock_t *lock) { - rtdm_lockctx_t s; + rtdm_lockctx_t context; - s = ipipe_test_and_stall_head(); + context = ipipe_test_and_stall_head(); spin_lock(lock); __xnsched_lock(); - return s; + return context; } -#define rtdm_lock_get_irqsave(__lock, __s) \ - ((__s) = __rtdm_lock_get_irqsave(__lock)) +#define rtdm_lock_get_irqsave(__lock, __context) \ + ((__context) = __rtdm_lock_get_irqsave(__lock)) /** * Release lock and restore preemption state @@ -597,11 +598,11 @@ static inline rtdm_lockctx_t __rtdm_lock_get_irqsave(rtdm_lock_t *lock) * Rescheduling: possible. */ static inline -void rtdm_lock_put_irqrestore(rtdm_lock_t *lock, rtdm_lockctx_t s) +void rtdm_lock_put_irqrestore(rtdm_lock_t *lock, rtdm_lockctx_t context) { spin_unlock(lock); __xnsched_unlock(); - ipipe_restore_head(s); + ipipe_restore_head(context); } /** @@ -707,6 +708,7 @@ typedef struct rtdm_waitqueue rtdm_waitqueue_t; DEFINE_RTDM_WAITQUEUE(__name) /** + * @fn void rtdm_waitqueue_init(struct rtdm_waitqueue *wq) * @brief Initialize a RTDM wait queue * * Sets up a wait queue structure for further use. @@ -719,6 +721,7 @@ static inline void rtdm_waitqueue_init(struct rtdm_waitqueue *wq) } /** + * @fn void rtdm_waitqueue_destroy(struct rtdm_waitqueue *wq) * @brief Deletes a RTDM wait queue * * Dismantles a wait queue structure, releasing all resources attached @@ -741,25 +744,26 @@ static inline int __rtdm_timedwait(struct rtdm_waitqueue *wq, } /** - * @brief Timed sleep on a locked waitqueue until a condition gets true + * @fn rtdm_timedwait_condition_locked(struct rtdm_wait_queue *wq, condition, nanosecs_rel_t timeout, rtdm_toseq_t *toseq) + * @brief Timed sleep on a locked waitqueue until a condition gets true * - * The calling task is put to sleep until @a __cond evaluates to true - * or a timeout occurs. The condition is checked each time the - * waitqueue @a __wq is signaled. + * The calling task is put to sleep until @a condition evaluates to + * true or a timeout occurs. The condition is checked each time the + * waitqueue @a wq is signaled. * * The waitqueue must have been locked by a call to * rtdm_waitqueue_lock() prior to calling this service. * - * @param __wq locked waitqueue to wait on. The waitqueue lock is + * @param wq locked waitqueue to wait on. The waitqueue lock is * dropped when sleeping, then reacquired before this service returns * to the caller. * - * @param __cond C expression for the event to wait for. + * @param condition C expression for the event to wait for. * - * @param __timeout relative timeout in nanoseconds, see + * @param timeout relative timeout in nanoseconds, see * @ref RTDM_TIMEOUT_xxx for special values. * - * @param[in,out] __toseq handle of a timeout sequence as returned by + * @param[in,out] toseq handle of a timeout sequence as returned by * rtdm_toseq_init() or NULL. * * @return 0 on success, otherwise: @@ -773,7 +777,7 @@ static inline int __rtdm_timedwait(struct rtdm_waitqueue *wq, * @note rtdm_waitqueue_signal() has to be called after changing any * variable that could change the result of the wait condition. * - * @note Passing RTDM_TIMEOUT_NONE to @a __timeout makes no sense for + * @note Passing RTDM_TIMEOUT_NONE to @a timeout makes no sense for * such service, and might cause unexpected behavior. */ #define rtdm_timedwait_condition_locked(__wq, __cond, __timeout, __toseq) \ @@ -785,20 +789,21 @@ static inline int __rtdm_timedwait(struct rtdm_waitqueue *wq, }) /** - * @brief Sleep on a locked waitqueue until a condition gets true + * @fn rtdm_wait_condition_locked(struct rtdm_wait_queue *wq, condition) + * @brief Sleep on a locked waitqueue until a condition gets true * - * The calling task is put to sleep until @a __cond evaluates to - * true. The condition is checked each time the waitqueue @a __wq is + * The calling task is put to sleep until @a condition evaluates to + * true. The condition is checked each time the waitqueue @a wq is * signaled. * * The waitqueue must have been locked by a call to * rtdm_waitqueue_lock() prior to calling this service. * - * @param __wq locked waitqueue to wait on. The waitqueue lock is + * @param wq locked waitqueue to wait on. The waitqueue lock is * dropped when sleeping, then reacquired before this service returns * to the caller. * - * @param __cond C expression for the event to wait for. + * @param cond C expression for the event to wait for. * * @return 0 on success, otherwise: * @@ -818,20 +823,21 @@ static inline int __rtdm_timedwait(struct rtdm_waitqueue *wq, }) /** - * @brief Timed sleep on a waitqueue until a condition gets true + * @fn rtdm_timedwait_condition(struct rtdm_wait_queue *wq, condition, nanosecs_rel_t timeout, rtdm_toseq_t *toseq) + * @brief Timed sleep on a waitqueue until a condition gets true * - * The calling task is put to sleep until @a __cond evaluates to true - * or a timeout occurs. The condition is checked each time the - * waitqueue @a __wq is signaled. + * The calling task is put to sleep until @a condition evaluates to + * true or a timeout occurs. The condition is checked each time the + * waitqueue @a wq is signaled. * - * @param __wq waitqueue to wait on. + * @param wq waitqueue to wait on. * - * @param __cond C expression for the event to wait for. + * @param cond C expression for the event to wait for. * - * @param __timeout relative timeout in nanoseconds, see + * @param timeout relative timeout in nanoseconds, see * @ref RTDM_TIMEOUT_xxx for special values. * - * @param[in,out] __toseq handle of a timeout sequence as returned by + * @param[in,out] toseq handle of a timeout sequence as returned by * rtdm_toseq_init() or NULL. * * @return 0 on success, otherwise: @@ -845,7 +851,7 @@ static inline int __rtdm_timedwait(struct rtdm_waitqueue *wq, * @note rtdm_waitqueue_signal() has to be called after changing any * variable that could change the result of the wait condition. * - * @note Passing RTDM_TIMEOUT_NONE to @a __timeout makes no sense for + * @note Passing RTDM_TIMEOUT_NONE to @a timeout makes no sense for * such service, and might cause unexpected behavior. */ #define rtdm_timedwait_condition(__wq, __cond, __timeout, __toseq) \ @@ -860,18 +866,19 @@ static inline int __rtdm_timedwait(struct rtdm_waitqueue *wq, }) /** + * @fn rtdm_timedwait(struct rtdm_wait_queue *wq, nanosecs_rel_t timeout, rtdm_toseq_t *toseq) * @brief Timed sleep on a waitqueue unconditionally * * The calling task is put to sleep until the waitqueue is signaled by * either rtdm_waitqueue_signal() or rtdm_waitqueue_broadcast(), or * flushed by a call to rtdm_waitqueue_flush(), or a timeout occurs. * - * @param __wq waitqueue to wait on. + * @param wq waitqueue to wait on. * - * @param __timeout relative timeout in nanoseconds, see + * @param timeout relative timeout in nanoseconds, see * @ref RTDM_TIMEOUT_xxx for special values. * - * @param[in,out] __toseq handle of a timeout sequence as returned by + * @param[in,out] toseq handle of a timeout sequence as returned by * rtdm_toseq_init() or NULL. * * @return 0 on success, otherwise: @@ -883,13 +890,14 @@ static inline int __rtdm_timedwait(struct rtdm_waitqueue *wq, * - -ETIMEDOUT is returned if the if the request has not been satisfied * within the specified amount of time. * - * @note Passing RTDM_TIMEOUT_NONE to @a __timeout makes no sense for + * @note Passing RTDM_TIMEOUT_NONE to @a timeout makes no sense for * such service, and might cause unexpected behavior. */ #define rtdm_timedwait(__wq, __timeout, __toseq) \ __rtdm_timedwait(__wq, __timeout, __toseq) /** + * @fn rtdm_timedwait_locked(struct rtdm_wait_queue *wq, nanosecs_rel_t timeout, rtdm_toseq_t *toseq) * @brief Timed sleep on a locked waitqueue unconditionally * * The calling task is put to sleep until the waitqueue is signaled by @@ -899,14 +907,14 @@ static inline int __rtdm_timedwait(struct rtdm_waitqueue *wq, * The waitqueue must have been locked by a call to * rtdm_waitqueue_lock() prior to calling this service. * - * @param __wq locked waitqueue to wait on. The waitqueue lock is + * @param wq locked waitqueue to wait on. The waitqueue lock is * dropped when sleeping, then reacquired before this service returns * to the caller. * - * @param __timeout relative timeout in nanoseconds, see + * @param timeout relative timeout in nanoseconds, see * @ref RTDM_TIMEOUT_xxx for special values. * - * @param[in,out] __toseq handle of a timeout sequence as returned by + * @param[in,out] toseq handle of a timeout sequence as returned by * rtdm_toseq_init() or NULL. * * @return 0 on success, otherwise: @@ -918,22 +926,23 @@ static inline int __rtdm_timedwait(struct rtdm_waitqueue *wq, * - -ETIMEDOUT is returned if the if the request has not been satisfied * within the specified amount of time. * - * @note Passing RTDM_TIMEOUT_NONE to @a __timeout makes no sense for + * @note Passing RTDM_TIMEOUT_NONE to @a timeout makes no sense for * such service, and might cause unexpected behavior. */ #define rtdm_timedwait_locked(__wq, __timeout, __toseq) \ rtdm_timedwait(__wq, __timeout, __toseq) /** - * @brief Sleep on a waitqueue until a condition gets true + * @fn rtdm_wait_condition(struct rtdm_wait_queue *wq, condition) + * @brief Sleep on a waitqueue until a condition gets true * - * The calling task is put to sleep until @a __cond evaluates to - * true. The condition is checked each time the waitqueue @a __wq is + * The calling task is put to sleep until @a condition evaluates to + * true. The condition is checked each time the waitqueue @a wq is * signaled. * - * @param __wq waitqueue to wait on + * @param wq waitqueue to wait on * - * @param __cond C expression for the event to wait for. + * @param condition C expression for the event to wait for. * * @return 0 on success, otherwise: * @@ -954,13 +963,14 @@ static inline int __rtdm_timedwait(struct rtdm_waitqueue *wq, }) /** + * @fn rtdm_wait(struct rtdm_wait_queue *wq) * @brief Sleep on a waitqueue unconditionally * * The calling task is put to sleep until the waitqueue is signaled by * either rtdm_waitqueue_signal() or rtdm_waitqueue_broadcast(), or * flushed by a call to rtdm_waitqueue_flush(). * - * @param __wq waitqueue to wait on. + * @param wq waitqueue to wait on. * * @return 0 on success, otherwise: * @@ -972,6 +982,7 @@ static inline int __rtdm_timedwait(struct rtdm_waitqueue *wq, xnsynch_sleep_on(&(__wq)->wait, XN_INFINITE, XN_RELATIVE) /** + * @fn rtdm_wait_locked(struct rtdm_wait_queue *wq) * @brief Sleep on a locked waitqueue unconditionally * * The calling task is put to sleep until the waitqueue is signaled by @@ -981,7 +992,7 @@ static inline int __rtdm_timedwait(struct rtdm_waitqueue *wq, * The waitqueue must have been locked by a call to * rtdm_waitqueue_lock() prior to calling this service. * - * @param __wq locked waitqueue to wait on. The waitqueue lock is + * @param wq locked waitqueue to wait on. The waitqueue lock is * dropped when sleeping, then reacquired before this service returns * to the caller. * @@ -994,11 +1005,12 @@ static inline int __rtdm_timedwait(struct rtdm_waitqueue *wq, #define rtdm_wait_locked(__wq) rtdm_wait(__wq) /** + * @fn rtdm_waitqueue_lock(struct rtdm_wait_queue *wq, rtdm_lockctx_t context) * @brief Lock a waitqueue * - * Acquires the lock on the waitqueue @a __wq. + * Acquires the lock on the waitqueue @a wq. * - * @param __wq waitqueue to lock. + * @param wq waitqueue to lock. * * @param context name of local variable to store the context in. * @@ -1008,23 +1020,25 @@ static inline int __rtdm_timedwait(struct rtdm_waitqueue *wq, #define rtdm_waitqueue_lock(__wq, __context) cobalt_atomic_enter(__context) /** + * @fn rtdm_waitqueue_unlock(struct rtdm_wait_queue *wq, rtdm_lockctx_t context) * @brief Unlock a waitqueue * - * Releases the lock on the waitqueue @a __wq. + * Releases the lock on the waitqueue @a wq. * - * @param __wq waitqueue to unlock. + * @param wq waitqueue to unlock. * - * @param context name of local variable to store the context in. + * @param context name of local variable to retrieve the context from. */ #define rtdm_waitqueue_unlock(__wq, __context) cobalt_atomic_leave(__context) /** + * @fn rtdm_waitqueue_signal(struct rtdm_wait_queue *wq) * @brief Signal a waitqueue * - * Signals the waitqueue @a __wq, waking up a single waiter (if + * Signals the waitqueue @a wq, waking up a single waiter (if * any). * - * @param __wq waitqueue to signal. + * @param wq waitqueue to signal. * * @return non-zero if a task has been readied as a result of this * call, zero otherwise. @@ -1046,12 +1060,13 @@ static inline int __rtdm_timedwait(struct rtdm_waitqueue *wq, }) /** + * @fn rtdm_waitqueue_broadcast(struct rtdm_wait_queue *wq) * @brief Broadcast a waitqueue * - * Broadcast the waitqueue @a __wq, waking up all waiters. Each + * Broadcast the waitqueue @a wq, waking up all waiters. Each * readied task may assume to have received the wake up event. * - * @param __wq waitqueue to broadcast. + * @param wq waitqueue to broadcast. * * @return non-zero if at least one task has been readied as a result * of this call, zero otherwise. @@ -1060,12 +1075,13 @@ static inline int __rtdm_timedwait(struct rtdm_waitqueue *wq, __rtdm_waitqueue_flush(__wq, 0) /** + * @fn rtdm_waitqueue_flush(struct rtdm_wait_queue *wq) * @brief Flush a waitqueue * - * Flushes the waitqueue @a __wq, unblocking all waiters with an error + * Flushes the waitqueue @a wq, unblocking all waiters with an error * status (-EINTR). * - * @param __wq waitqueue to flush. + * @param wq waitqueue to flush. * * @return non-zero if at least one task has been readied as a result * of this call, zero otherwise. @@ -1074,14 +1090,15 @@ static inline int __rtdm_timedwait(struct rtdm_waitqueue *wq, __rtdm_waitqueue_flush(__wq, XNBREAK) /** + * @fn rtdm_waitqueue_wakeup(struct rtdm_wait_queue *wq, rtdm_task_t waiter) * @brief Signal a particular waiter on a waitqueue * - * Signals the waitqueue @a __wq, waking up waiter @a __waiter only, + * Signals the waitqueue @a wq, waking up waiter @a waiter only, * which must be currently sleeping on the waitqueue. * - * @param __wq waitqueue to signal. + * @param wq waitqueue to signal. * - * @param __waiter RTDM task to wake up. + * @param waiter RTDM task to wake up. */ #define rtdm_waitqueue_wakeup(__wq, __waiter) \ do { \ @@ -1090,19 +1107,20 @@ static inline int __rtdm_timedwait(struct rtdm_waitqueue *wq, } while (0) /** + * @fn rtdm_for_each_waiter(rtdm_task_t pos, struct rtdm_wait_queue *wq) * @brief Simple iterator for waitqueues * * This construct traverses the wait list of a given waitqueue - * @a __wq, assigning each RTDM task pointer to the cursor variable - * @a __pos, which must be of type rtdm_task_t. + * @a wq, assigning each RTDM task pointer to the cursor variable + * @a pos, which must be of type rtdm_task_t. * - * @a __wq must have been locked by a call to rtdm_waitqueue_lock() + * @a wq must have been locked by a call to rtdm_waitqueue_lock() * prior to traversing its wait list. * - * @param __pos cursor variable holding a pointer to the RTDM task + * @param pos cursor variable holding a pointer to the RTDM task * being fetched. * - * @param __wq waitqueue to scan. + * @param wq waitqueue to scan. * * @note The waitqueue should not be signaled, broadcast or flushed * during the traversal, unless the loop is aborted immediately @@ -1114,24 +1132,25 @@ static inline int __rtdm_timedwait(struct rtdm_waitqueue *wq, xnsynch_for_each_sleeper(__pos, &(__wq)->wait) /** + * @fn rtdm_for_each_waiter_safe(rtdm_task_t pos, rtdm_task_t tmp, struct rtdm_wait_queue *wq) * @brief Safe iterator for waitqueues * * This construct traverses the wait list of a given waitqueue - * @a __wq, assigning each RTDM task pointer to the cursor variable - * @a __pos, which must be of type rtdm_task_t. + * @a wq, assigning each RTDM task pointer to the cursor variable + * @a pos, which must be of type rtdm_task_t. * * Unlike with rtdm_for_each_waiter(), the waitqueue may be signaled, * broadcast or flushed during the traversal. * - * @a __wq must have been locked by a call to rtdm_waitqueue_lock() + * @a wq must have been locked by a call to rtdm_waitqueue_lock() * prior to traversing its wait list. * - * @param __pos cursor variable holding a pointer to the RTDM task + * @param pos cursor variable holding a pointer to the RTDM task * being fetched. * - * @param __tmp temporary cursor variable. + * @param tmp temporary cursor variable. * - * @param __wq waitqueue to scan. + * @param wq waitqueue to scan. */ #define rtdm_for_each_waiter_safe(__pos, __tmp, __wq) \ xnsynch_for_each_sleeper_safe(__pos, __tmp, &(__wq)->wait) diff --git a/kernel/cobalt/rtdm/drvlib.c b/kernel/cobalt/rtdm/drvlib.c index 67be98f..209c4f5 100644 --- a/kernel/cobalt/rtdm/drvlib.c +++ b/kernel/cobalt/rtdm/drvlib.c @@ -1933,7 +1933,7 @@ static int rtdm_do_mmap(struct rtdm_fd *fd, /** * Map a kernel memory range into the address space of the user. * - * @param[in] user_info User information pointer as passed to the invoked + * @param[in] fd RTDM file descriptor as passed to the invoked * device operation handler * @param[in] src_addr Kernel virtual address to be mapped * @param[in] len Length of the memory range @@ -2005,7 +2005,7 @@ EXPORT_SYMBOL_GPL(rtdm_mmap_to_user); /** * Map an I/O memory range into the address space of the user. * - * @param[in] user_info User information pointer as passed to the invoked + * @param[in] fd RTDM file descriptor as passed to the invoked * device operation handler * @param[in] src_addr physical I/O address to be mapped * @param[in] len Length of the memory range @@ -2073,7 +2073,7 @@ EXPORT_SYMBOL_GPL(rtdm_iomap_to_user); /** * Unmap a user memory range. * - * @param[in] user_info User information pointer as passed to + * @param[in] fd RTDM file descriptor as passed to * rtdm_mmap_to_user() when requesting to map the memory range * @param[in] ptr User address or the memory range * @param[in] len Length of the memory range @@ -2112,11 +2112,11 @@ EXPORT_SYMBOL_GPL(rtdm_munmap); /** * @brief Enforces a rate limit * - * This function enforces a rate limit: not more than @rs->burst callbacks - * in every @rs->interval. + * This function enforces a rate limit: not more than @a rs->burst callbacks + * in every @a rs->interval. * - * @param[in,out] rtdm_ratelimit_state data - * @param[in] name of calling function + * @param[in,out] rs rtdm_ratelimit_state data + * @param[in] func name of calling function * * @return 0 means callback will be suppressed and 1 means go ahead and do it * @@ -2253,7 +2253,7 @@ void rtdm_free(void *ptr); /** * Check if read access to user-space memory block is safe * - * @param[in] user_info User information pointer as passed to the invoked + * @param[in] fd RTDM file descriptor as passed to the invoked * device operation handler * @param[in] ptr Address of the user-provided memory block * @param[in] size Size of the memory block @@ -2277,7 +2277,7 @@ int rtdm_read_user_ok(struct rtdm_fd *fd, const void __user *ptr, /** * Check if read/write access to user-space memory block is safe * - * @param[in] user_info User information pointer as passed to the invoked + * @param[in] fd RTDM file descriptor as passed to the invoked * device operation handler * @param[in] ptr Address of the user-provided memory block * @param[in] size Size of the memory block @@ -2301,7 +2301,7 @@ int rtdm_rw_user_ok(struct rtdm_fd *fd, const void __user *ptr, /** * Copy user-space memory block to specified buffer * - * @param[in] user_info User information pointer as passed to the invoked + * @param[in] fd RTDM file descriptor as passed to the invoked * device operation handler * @param[in] dst Destination buffer address * @param[in] src Address of the user-space memory block @@ -2331,7 +2331,7 @@ int rtdm_copy_from_user(struct rtdm_fd *fd, void *dst, * Check if read access to user-space memory block and copy it to specified * buffer * - * @param[in] user_info User information pointer as passed to the invoked + * @param[in] fd RTDM file descriptor as passed to the invoked * device operation handler * @param[in] dst Destination buffer address * @param[in] src Address of the user-space memory block @@ -2360,7 +2360,7 @@ int rtdm_safe_copy_from_user(struct rtdm_fd *fd, void *dst, /** * Copy specified buffer to user-space memory block * - * @param[in] user_info User information pointer as passed to the invoked + * @param[in] fd RTDM file descriptor as passed to the invoked * device operation handler * @param[in] dst Address of the user-space memory block * @param[in] src Source buffer address @@ -2390,7 +2390,7 @@ int rtdm_copy_to_user(struct rtdm_fd *fd, void __user *dst, * Check if read/write access to user-space memory block is safe and copy * specified buffer to it * - * @param[in] user_info User information pointer as passed to the invoked + * @param[in] fd RTDM file descriptor as passed to the invoked * device operation handler * @param[in] dst Address of the user-space memory block * @param[in] src Source buffer address @@ -2419,7 +2419,7 @@ int rtdm_safe_copy_to_user(struct rtdm_fd *fd, void __user *dst, /** * Copy user-space string to specified buffer * - * @param[in] user_info User information pointer as passed to the invoked + * @param[in] fd RTDM file descriptor as passed to the invoked * device operation handler * @param[in] dst Destination buffer address * @param[in] src Address of the user-space string @@ -2468,7 +2468,7 @@ int rtdm_in_rt_context(void); /** * Test if the caller is capable of running in real-time context * - * @param[in] user_info User information pointer as passed to the invoked + * @param[in] fd RTDM file descriptor as passed to the invoked * device operation handler * * @return Non-zero is returned if the caller is able to execute in real-time diff --git a/kernel/cobalt/synch.c b/kernel/cobalt/synch.c index b9f67ed..a8877cd 100644 --- a/kernel/cobalt/synch.c +++ b/kernel/cobalt/synch.c @@ -559,7 +559,7 @@ static struct xnthread *transfer_ownership(struct xnsynch *synch, } /** - * @fn struct xnthread *xnsynch_release(struct xnsynch *synch, struct xnthread *owner); + * @fn struct xnthread *xnsynch_release(struct xnsynch *synch, struct xnthread *thread) * @brief Give the resource ownership to the next waiting thread. * * This service releases the ownership of the given synchronization @@ -573,7 +573,7 @@ static struct xnthread *transfer_ownership(struct xnsynch *synch, * @param synch The descriptor address of the synchronization object * whose ownership is changed. * - * @param owner The descriptor address of the current owner. + * @param thread The descriptor address of the current owner. * * @return The descriptor address of the unblocked thread. * diff --git a/kernel/cobalt/thread.c b/kernel/cobalt/thread.c index 1b29ee5..8a3ae3c 100644 --- a/kernel/cobalt/thread.c +++ b/kernel/cobalt/thread.c @@ -1168,6 +1168,8 @@ EXPORT_SYMBOL_GPL(xnthread_unblock); * xnthread_wait_period() will delay the thread until the next * periodic release point in the processor timeline is reached. * + * @param thread The core thread to make periodic. + * * @param idate The initial (absolute) date of the first release * point, expressed in nanoseconds. The affected thread will be * delayed by the first call to xnthread_wait_period() until this diff --git a/lib/alchemy/alarm.c b/lib/alchemy/alarm.c index d76bc88..ea6e077 100644 --- a/lib/alchemy/alarm.c +++ b/lib/alchemy/alarm.c @@ -370,6 +370,9 @@ out: * @param alarm The descriptor address of the alarm to get the status * of. * + * @param info A pointer to the @ref RT_ALARM_INFO "return + * buffer" to copy the information to. + * * @return Zero is returned and status information is written to the * structure pointed at by @a info upon success. Otherwise: * diff --git a/lib/alchemy/buffer.c b/lib/alchemy/buffer.c index c950408..64bd8c2 100644 --- a/lib/alchemy/buffer.c +++ b/lib/alchemy/buffer.c @@ -841,6 +841,9 @@ out: * @param bf The descriptor address of the buffer to get the status * of. * + * @param info A pointer to the @ref RT_BUFFER_INFO "return + * buffer" to copy the information to. + * * @return Zero is returned and status information is written to the * structure pointed at by @a info upon success. Otherwise: * diff --git a/lib/alchemy/cond.c b/lib/alchemy/cond.c index fb3dc2d..f803181 100644 --- a/lib/alchemy/cond.c +++ b/lib/alchemy/cond.c @@ -224,7 +224,7 @@ out: * immediately unblocks the first waiting task (by queuing priority * order). * - * @param The descriptor address of the condition variable to signal. + * @param cond The descriptor address of the condition variable to signal. * * @return Zero is returned upon success. Otherwise: * @@ -247,12 +247,12 @@ int rt_cond_signal(RT_COND *cond) /** * @fn int rt_cond_broadcast(RT_COND *cond) - * @brief Broadcast a condition variable. + * @brief Broadcast a condition variable * * All tasks currently waiting on the condition variable are * immediately unblocked. * - * @param The descriptor address of the condition variable to + * @param cond The descriptor address of the condition variable to * broadcast. * * @return Zero is returned upon success. Otherwise: @@ -284,6 +284,9 @@ int rt_cond_broadcast(RT_COND *cond) * @param cond The descriptor address of the condition variable to * wait on. * + * @param mutex The address of the mutex serializing the access to the + * shared data. + * * @param timeout A delay expressed in clock ticks. */ @@ -297,6 +300,9 @@ int rt_cond_broadcast(RT_COND *cond) * @param cond The descriptor address of the condition variable to * wait on. * + * @param mutex The address of the mutex serializing the access to the + * shared data. + * * @param abs_timeout An absolute date expressed in clock ticks. */ @@ -312,6 +318,9 @@ int rt_cond_broadcast(RT_COND *cond) * @param cond The descriptor address of the condition variable to * wait on. * + * @param mutex The address of the mutex serializing the access to the + * shared data. + * * @param abs_timeout An absolute date expressed in clock ticks, * specifying a time limit to wait for the condition variable to be * signaled (see note). Passing NULL causes the caller to @@ -380,8 +389,11 @@ int rt_cond_wait_timed(RT_COND *cond, RT_MUTEX *mutex, * This routine returns the status information about the specified * condition variable. * - * @param The descriptor address of the condition variable to get the - * status of. + * @param cond The descriptor address of the condition variable to get + * the status of. + * + * @param info A pointer to the @ref RT_COND_INFO "return + * buffer" to copy the information to. * * @return Zero is returned and status information is written to the * structure pointed at by @a info upon success. Otherwise: diff --git a/lib/alchemy/event.c b/lib/alchemy/event.c index 3c1dfdf..827d082 100644 --- a/lib/alchemy/event.c +++ b/lib/alchemy/event.c @@ -423,7 +423,7 @@ out: * request satisfied as a result of this operation are immediately * readied. * - * @param The descriptor address of the event flag group to signal. + * @param event The descriptor address of the event flag group to signal. * * @param mask The set of events to be posted. * @@ -503,6 +503,9 @@ out: * @param event The descriptor address of the event flag group to get * the status of. * + * @param info A pointer to the @ref RT_EVENT_INFO "return + * buffer" to copy the information to. + * * @return Zero is returned and status information is written to the * structure pointed at by @a info upon success. Otherwise: * diff --git a/lib/alchemy/heap.c b/lib/alchemy/heap.c index c61af41..5fc840c 100644 --- a/lib/alchemy/heap.c +++ b/lib/alchemy/heap.c @@ -561,6 +561,9 @@ out: * @param heap The descriptor address of the heap to get the status * of. * + * @param info A pointer to the @ref RT_HEAP_INFO "return + * buffer" to copy the information to. + * * @return Zero is returned and status information is written to the * structure pointed at by @a info upon success. Otherwise: * diff --git a/lib/alchemy/mutex.c b/lib/alchemy/mutex.c index 093f0ab..ae21115 100644 --- a/lib/alchemy/mutex.c +++ b/lib/alchemy/mutex.c @@ -28,7 +28,7 @@ * @ingroup alchemy * @defgroup alchemy_mutex Mutex services * - * POSIXish mutual exclusion services + * POSIXish mutual exclusion servicesl * * A mutex is a MUTual EXclusion object, and is useful for protecting * shared data structures from concurrent modifications, and @@ -404,7 +404,10 @@ int rt_mutex_release(RT_MUTEX *mutex) * This routine returns the status information about the specified * mutex. * - * @param The descriptor address of the mutex to get the status of. + * @param mutex The descriptor address of the mutex to get the status of. + * + * @param info A pointer to the @ref RT_MUTEX_INFO "return + * buffer" to copy the information to. * * @return Zero is returned and status information is written to the * structure pointed at by @a info upon success. Otherwise: diff --git a/lib/alchemy/pipe.c b/lib/alchemy/pipe.c index 438a802..d355427 100644 --- a/lib/alchemy/pipe.c +++ b/lib/alchemy/pipe.c @@ -284,6 +284,12 @@ out: * @param buf A pointer to a memory area which will be written upon * success with the message received. * + * @param size The count of bytes from the received message to read up + * into @a buf. If @a size is lower than the actual message size, + * -ENOBUFS is returned since the incompletely received message would + * be lost. If @a size is zero, this call returns immediately with no + * other action. + * * @param timeout A delay expressed in clock ticks. */ @@ -300,6 +306,12 @@ out: * @param buf A pointer to a memory area which will be written upon * success with the message received. * + * @param size The count of bytes from the received message to read up + * into @a buf. If @a size is lower than the actual message size, + * -ENOBUFS is returned since the incompletely received message would + * be lost. If @a size is zero, this call returns immediately with no + * other action. + * * @param abs_timeout An absolute date expressed in clock ticks. */ @@ -315,6 +327,12 @@ out: * @param buf A pointer to a memory area which will be written upon * success with the message received. * + * @param size The count of bytes from the received message to read up + * into @a buf. If @a size is lower than the actual message size, + * -ENOBUFS is returned since the incompletely received message would + * be lost. If @a size is zero, this call returns immediately with no + * other action. + * * @param abs_timeout An absolute date expressed in clock ticks, * specifying a time limit to wait for a message to be available from * the pipe (see note). Passing NULL causes the caller to block diff --git a/lib/alchemy/queue.c b/lib/alchemy/queue.c index 55e1eb1..357de7c 100644 --- a/lib/alchemy/queue.c +++ b/lib/alchemy/queue.c @@ -162,6 +162,11 @@ fnref_register(libalchemy, queue_finalize); * claimed and released to this pool. The buffer pool memory cannot * be extended. See note. * + * @param qlimit This parameter allows to limit the maximum number of + * messages which can be queued at any point in time, sending to a + * full queue begets an error. The special value Q_UNLIMITED can be + * passed to disable the limit check. + * * @param mode The queue creation mode. The following flags can be * OR'ed into this bitmask, each of them affecting the new queue: * @@ -1082,6 +1087,9 @@ out: * @param q The descriptor address of the queue to get the status * of. * + * @param info A pointer to the @ref RT_QUEUE_INFO "return + * buffer" to copy the information to. + * * @return Zero is returned and status information is written to the * structure pointed at by @a info upon success. Otherwise: * diff --git a/lib/alchemy/sem.c b/lib/alchemy/sem.c index 11e23b8..06e22f0 100644 --- a/lib/alchemy/sem.c +++ b/lib/alchemy/sem.c @@ -397,7 +397,7 @@ out: * incremented by one, unless the semaphore is used in "pulse" mode * (see rt_sem_create()). * - * @param The descriptor address of the semaphore to signal. + * @param sem The descriptor address of the semaphore to signal. * * @return Zero is returned upon success. Otherwise: * @@ -432,7 +432,7 @@ out: * All tasks currently waiting on the semaphore are immediately * unblocked. The semaphore count is set to zero. * - * @param The descriptor address of the semaphore to broadcast. + * @param sem The descriptor address of the semaphore to broadcast. * * @return Zero is returned upon success. Otherwise: * @@ -470,6 +470,9 @@ out: * @param sem The descriptor address of the semaphore to get the * status of. * + * @param info A pointer to the @ref RT_SEM_INFO "return + * buffer" to copy the information to. + * * @return Zero is returned and status information is written to the * structure pointed at by @a info upon success. Otherwise: * _______________________________________________ Xenomai-git mailing list Xenomai-git@xenomai.org http://www.xenomai.org/mailman/listinfo/xenomai-git