From: John Hodge Date: Fri, 11 Jan 2013 02:42:48 +0000 (+0800) Subject: Kernel - Commenting changes only X-Git-Tag: rel0.15~599 X-Git-Url: https://git.ucc.asn.au/?a=commitdiff_plain;h=35dd0489ba760c7d803aed84fd6b1fc7f5793b5d;p=tpg%2Facess2.git Kernel - Commenting changes only --- diff --git a/KernelLand/Kernel/Doxyfile b/KernelLand/Kernel/Doxyfile index a474dd56..afd627a3 100644 --- a/KernelLand/Kernel/Doxyfile +++ b/KernelLand/Kernel/Doxyfile @@ -581,7 +581,7 @@ INPUT_ENCODING = UTF-8 # *.c *.cc *.cxx *.cpp *.c++ *.java *.ii *.ixx *.ipp *.i++ *.inl *.h *.hh *.hxx # *.hpp *.h++ *.idl *.odl *.cs *.php *.php3 *.inc *.m *.mm *.py *.f90 -FILE_PATTERNS = *.c *.h +FILE_PATTERNS = *.c *.h *.asm # The RECURSIVE tag can be used to turn specify whether or not subdirectories # should be searched for input files as well. Possible values are YES and NO. diff --git a/KernelLand/Kernel/include/rwlock.h b/KernelLand/Kernel/include/rwlock.h index e0d42078..8bd374e5 100644 --- a/KernelLand/Kernel/include/rwlock.h +++ b/KernelLand/Kernel/include/rwlock.h @@ -25,24 +25,27 @@ struct sRWLock }; /** - * \brief Acquire a heavy mutex - * \param Mutex Mutex to acquire + * \brief Acquire a read-write lock for reading + * \param Lock Lock to acquire * \return zero on success, -1 if terminated * - * This type of mutex checks if the mutex is avaliable, and acquires it - * if it is. Otherwise, the current thread is added to the mutex's wait - * queue and the thread suspends. When the holder of the mutex completes, - * the oldest thread (top thread) on the queue is given the lock and - * restarted. + * Waits until the lock is readable and the increments the reader count */ extern int RWLock_AcquireRead(tRWLock *Lock); +/** + * \brief Acquire a read-write lock for writing + * \param Lock Lock to acquire + * \return zero on success, -1 if terminated + * + * Waits until there are no writers, flags all readers to wait, then acquires the lock. + */ extern int RWLock_AcquireWrite(tRWLock *Lock); /** - * \brief Release a held mutex - * \param Mutex Mutex to release - * \note Releasing a non-held mutex has no effect + * \brief Release a held rw lock + * \param Lock Lock to release + * \note Releasing a non-held lock has no effect */ extern void RWLock_Release(tRWLock *Lock); diff --git a/KernelLand/Kernel/include/vfs.h b/KernelLand/Kernel/include/vfs.h index 59824e23..f8532ed9 100644 --- a/KernelLand/Kernel/include/vfs.h +++ b/KernelLand/Kernel/include/vfs.h @@ -322,7 +322,7 @@ struct sVFS_NodeType * \param Node Pointer to this node (directory) * \param NewName Name for the new link * \param Child Node to create a new link to - * \retur Zeron on success, non-zero on error (see errno.h) + * \return Zero on success, non-zero on error (see errno.h) */ int (*Link)(struct sVFS_Node *Node, const char *NewName, struct sVFS_Node *Child);