diff options
Diffstat (limited to '')
42 files changed, 811 insertions, 2316 deletions
diff --git a/cpukit/score/include/rtems/score/address.h b/cpukit/score/include/rtems/score/address.h index be056f220a..ec5ec6b03e 100644 --- a/cpukit/score/include/rtems/score/address.h +++ b/cpukit/score/include/rtems/score/address.h @@ -21,83 +21,9 @@ extern "C" { #endif -/* - * _Addresses_Add_offset - * - * DESCRIPTION: - * - * This function is used to add an offset to a base address. - * It returns the resulting address. This address is typically - * converted to an access type before being used further. - */ - -STATIC INLINE void *_Addresses_Add_offset ( - void *base, - unsigned32 offset -); - -/* - * _Addresses_Subtract_offset - * - * DESCRIPTION: - * - * This function is used to subtract an offset from a base - * address. It returns the resulting address. This address is - * typically converted to an access type before being used further. - */ - -STATIC INLINE void *_Addresses_Subtract_offset( - void *base, - unsigned32 offset -); - -/* - * _Addresses_Subtract - * - * DESCRIPTION: - * - * This function is used to subtract two addresses. It returns the - * resulting offset. - */ - -STATIC INLINE unsigned32 _Addresses_Subtract ( - void *left, - void *right -); - -/* - * _Addresses_Is_aligned - * - * DESCRIPTION: - * - * This function returns TRUE if the given address is correctly - * aligned for this processor and FALSE otherwise. Proper alignment - * is based on correctness and efficiency. - */ - -STATIC INLINE boolean _Addresses_Is_aligned ( - void *address -); - -/* - * _Addresses_Is_in_range - * - * DESCRIPTION: - * - * This function returns TRUE if the given address is within the - * memory range specified and FALSE otherwise. base is the address - * of the first byte in the memory range and limit is the address - * of the last byte in the memory range. The base address is - * assumed to be lower than the limit address. - */ - -STATIC INLINE boolean _Addresses_Is_in_range ( - void *address, - void *base, - void *limit -); - +#ifndef __RTEMS_APPLICATION__ #include <rtems/score/address.inl> +#endif #ifdef __cplusplus } diff --git a/cpukit/score/include/rtems/score/chain.h b/cpukit/score/include/rtems/score/chain.h index 1d6c8f1db4..6eed361e88 100644 --- a/cpukit/score/include/rtems/score/chain.h +++ b/cpukit/score/include/rtems/score/chain.h @@ -84,49 +84,6 @@ void _Chain_Initialize( ); /* - * _Chain_Initialize_empty - * - * DESCRIPTION: - * - * This routine initializes the specified chain to contain zero nodes. - * - */ - -STATIC INLINE void _Chain_Initialize_empty( - Chain_Control *the_chain -); - -/* - * _Chain_Are_nodes_equal - * - * DESCRIPTION: - * - * This function returns TRUE if LEFT and RIGHT are equal, - * and FALSE otherwise. - * - */ - -STATIC INLINE boolean _Chain_Are_nodes_equal( - Chain_Node *left, - Chain_Node *right -); - -/* - * _Chain_Extract_unprotected - * - * DESCRIPTION: - * - * This routine extracts the_node from the chain on which it resides. - * It does NOT disable interrupts to insure the atomicity of the - * extract operation. - * - */ - -STATIC INLINE void _Chain_Extract_unprotected( - Chain_Node *the_node -); - -/* * _Chain_Extract * * DESCRIPTION: @@ -142,22 +99,6 @@ void _Chain_Extract( ); /* - * _Chain_Get_unprotected - * - * DESCRIPTION: - * - * This function removes the first node from the_chain and returns - * a pointer to that node. If the_chain is empty, then NULL is returned. - * It does NOT disable interrupts to insure the atomicity of the - * get operation. - * - */ - -STATIC INLINE Chain_Node *_Chain_Get_unprotected( - Chain_Control *the_chain -); - -/* * _Chain_Get * * DESCRIPTION: @@ -174,37 +115,6 @@ Chain_Node *_Chain_Get( ); /* - * _Chain_Get_first_unprotected - * - * DESCRIPTION: - * - * This function removes the first node from the_chain and returns - * a pointer to that node. It does NOT disable interrupts to insure - * the atomicity of the get operation. - * - */ - -STATIC INLINE Chain_Node *_Chain_Get_first_unprotected( - Chain_Control *the_chain -); - -/* - * _Chain_Insert_unprotected - * - * DESCRIPTION: - * - * This routine inserts the_node on a chain immediately following - * after_node. It does NOT disable interrupts to insure the atomicity - * of the extract operation. - * - */ - -STATIC INLINE void _Chain_Insert_unprotected( - Chain_Node *after_node, - Chain_Node *the_node -); - -/* * _Chain_Insert * * DESCRIPTION: @@ -221,22 +131,6 @@ void _Chain_Insert( ); /* - * _Chain_Append_unprotected - * - * DESCRIPTION: - * - * This routine appends the_node onto the end of the_chain. - * It does NOT disable interrupts to insure the atomicity of the - * append operation. - * - */ - -STATIC INLINE void _Chain_Append_unprotected( - Chain_Control *the_chain, - Chain_Node *the_node -); - -/* * _Chain_Append * * DESCRIPTION: @@ -252,177 +146,9 @@ void _Chain_Append( Chain_Node *the_node ); -/* - * _Chain_Prepend_unprotected - * - * DESCRIPTION: - * - * This routine prepends the_node onto the front of the_chain. - * It does NOT disable interrupts to insure the atomicity of the - * prepend operation. - * - */ - -STATIC INLINE void _Chain_Prepend_unprotected( - Chain_Control *the_chain, - Chain_Node *the_node -); - -/* - * _Chain_Prepend - * - * DESCRIPTION: - * - * This routine prepends the_node onto the front of the_chain. - * It disables interrupts to insure the atomicity of the - * prepend operation. - * - */ - -STATIC INLINE void _Chain_Prepend( - Chain_Control *the_chain, - Chain_Node *the_node -); - -/* - * _Chain_Head - * - * DESCRIPTION: - * - * This function returns a pointer to the first node on the chain. - * - */ - -STATIC INLINE Chain_Node *_Chain_Head( - Chain_Control *the_chain -); - -/* - * _Chain_Tail - * - * DESCRIPTION: - * - * This function returns a pointer to the last node on the chain. - * - */ - -STATIC INLINE Chain_Node *_Chain_Tail( - Chain_Control *the_chain -); - -/* - * _Chain_Is_head - * - * DESCRIPTION: - * - * This function returns TRUE if the_node is the head of the_chain and - * FALSE otherwise. - * - */ - -STATIC INLINE boolean _Chain_Is_head( - Chain_Control *the_chain, - Chain_Node *the_node -); - -/* - * _Chain_Is_tail - * - * DESCRIPTION: - * - * This function returns TRUE if the_node is the tail of the_chain and - * FALSE otherwise. - * - */ - -STATIC INLINE boolean _Chain_Is_tail( - Chain_Control *the_chain, - Chain_Node *the_node -); - -/* - * _Chain_Is_first - * - * DESCRIPTION: - * - * This function returns TRUE if the_node is the first node on a chain and - * FALSE otherwise. - * - */ - -STATIC INLINE boolean _Chain_Is_first( - Chain_Node *the_node -); - -/* - * _Chain_Is_last - * - * DESCRIPTION: - * - * This function returns TRUE if the_node is the last node on a chain and - * FALSE otherwise. - * - */ - -STATIC INLINE boolean _Chain_Is_last( - Chain_Node *the_node -); - -/* - * _Chain_Is_empty - * - * DESCRIPTION: - * - * This function returns TRUE if there a no nodes on the_chain and - * FALSE otherwise. - * - */ - -STATIC INLINE boolean _Chain_Is_empty( - Chain_Control *the_chain -); - -/* - * _Chain_Has_only_one_node - * - * DESCRIPTION: - * - * This function returns TRUE if there is only one node on the_chain and - * FALSE otherwise. - * - */ - -STATIC INLINE boolean _Chain_Has_only_one_node( - Chain_Control *the_chain -); - -/* - * _Chain_Is_null - * - * DESCRIPTION: - * - * This function returns TRUE if the_chain is NULL and FALSE otherwise. - * - */ - -STATIC INLINE boolean _Chain_Is_null( - Chain_Control *the_chain -); - -/* - * _Chain_Is_null_node - * - * DESCRIPTION: - * - * This function returns TRUE if the_node is NULL and FALSE otherwise. - * - */ - -STATIC INLINE boolean _Chain_Is_null_node( - Chain_Node *the_node -); - +#ifndef __RTEMS_APPLICATION__ #include <rtems/score/chain.inl> +#endif #ifdef __cplusplus } diff --git a/cpukit/score/include/rtems/score/coremsg.h b/cpukit/score/include/rtems/score/coremsg.h index 737004aeb8..b51e07ef61 100644 --- a/cpukit/score/include/rtems/score/coremsg.h +++ b/cpukit/score/include/rtems/score/coremsg.h @@ -196,41 +196,6 @@ unsigned32 _CORE_message_queue_Flush_support( ); /* - * _CORE_message_queue_send - * - * DESCRIPTION: - * - * This routine sends a message to the end of the specified message queue. - * - */ - -STATIC INLINE CORE_message_queue_Status _CORE_message_queue_Send( - CORE_message_queue_Control *the_message_queue, - void *buffer, - unsigned32 size, - Objects_Id id, - CORE_message_queue_API_mp_support_callout api_message_queue_mp_support -); - -/* - * - * _CORE_message_queue_Urgent - * - * DESCRIPTION: - * - * This routine sends a message to the front of the specified message queue. - * - */ - -STATIC INLINE CORE_message_queue_Status _CORE_message_queue_Urgent( - CORE_message_queue_Control *the_message_queue, - void *buffer, - unsigned32 size, - Objects_Id id, - CORE_message_queue_API_mp_support_callout api_message_queue_mp_support -); - -/* * * _CORE_message_queue_Broadcast * @@ -296,144 +261,9 @@ void _CORE_message_queue_Seize( Watchdog_Interval timeout ); -/* - * _CORE_message_queue_Allocate_message_buffer - * - * DESCRIPTION: - * - * This function allocates a message buffer from the inactive - * message buffer chain. - */ - -STATIC INLINE CORE_message_queue_Buffer_control * - _CORE_message_queue_Allocate_message_buffer ( - CORE_message_queue_Control *the_message_queue -); - -/* - * _CORE_message_queue_Free_message_buffer - * - * DESCRIPTION: - * - * This routine frees a message buffer to the inactive - * message buffer chain. - */ - -STATIC INLINE void _CORE_message_queue_Free_message_buffer ( - CORE_message_queue_Control *the_message_queue, - CORE_message_queue_Buffer_control *the_message -); - -/* - * _CORE_message_queue_Copy_buffer - * - * DESCRIPTION: - * - * This routine copies the contents of the source message buffer - * to the destination message buffer. - */ - -STATIC INLINE void _CORE_message_queue_Copy_buffer ( - void *source, - void *destination, - unsigned32 size -); - -/* - * _CORE_message_queue_Get_pending_message - * - * DESCRIPTION: - * - * This function removes the first message from the_message_queue - * and returns a pointer to it. - */ - -STATIC INLINE - CORE_message_queue_Buffer_control *_CORE_message_queue_Get_pending_message ( - CORE_message_queue_Control *the_message_queue -); - -/* - * _CORE_message_queue_Is_priority - * - * DESCRIPTION: - * - * This function returns TRUE if the priority attribute is - * enabled in the attribute_set and FALSE otherwise. - */ - -STATIC INLINE boolean _CORE_message_queue_Is_priority( - CORE_message_queue_Attributes *the_attribute -); - -/* - * _CORE_message_queue_Append - * - * DESCRIPTION: - * - * This routine places the_message at the rear of the outstanding - * messages on the_message_queue. - */ - -STATIC INLINE void _CORE_message_queue_Append ( - CORE_message_queue_Control *the_message_queue, - CORE_message_queue_Buffer_control *the_message -); - -/* - * _CORE_message_queue_Prepend - * - * DESCRIPTION: - * - * This routine places the_message at the rear of the outstanding - * messages on the_message_queue. - */ - -STATIC INLINE void _CORE_message_queue_Prepend ( - CORE_message_queue_Control *the_message_queue, - CORE_message_queue_Buffer_control *the_message -); - -/* - * _CORE_message_queue_Is_null - * - * DESCRIPTION: - * - * This function returns TRUE if the_message_queue is TRUE and FALSE otherwise. - */ - -STATIC INLINE boolean _CORE_message_queue_Is_null ( - CORE_message_queue_Control *the_message_queue -); - -/* - * _CORE_message_queue_Is_notify_enabled - * - * DESCRIPTION: - * - * This function returns TRUE if notification is enabled on this message - * queue and FALSE otherwise. - */ - -STATIC INLINE boolean _CORE_message_queue_Is_notify_enabled ( - CORE_message_queue_Control *the_message_queue -); - -/* - * _CORE_message_queue_Set_notify - * - * DESCRIPTION: - * - * This routine initializes the notification information for the_message_queue. - */ - -STATIC INLINE void _CORE_message_queue_Set_notify ( - CORE_message_queue_Control *the_message_queue, - CORE_message_queue_Notify_Handler the_handler, - void *the_argument -); - +#ifndef __RTEMS_APPLICATION__ #include <rtems/score/coremsg.inl> +#endif #ifdef __cplusplus } diff --git a/cpukit/score/include/rtems/score/coremutex.h b/cpukit/score/include/rtems/score/coremutex.h index 2e8d16a0c1..73b7e34417 100644 --- a/cpukit/score/include/rtems/score/coremutex.h +++ b/cpukit/score/include/rtems/score/coremutex.h @@ -158,85 +158,9 @@ void _CORE_mutex_Flush( unsigned32 status ); -/* - * _CORE_mutex_Is_locked - * - * DESCRIPTION: - * - * This routine returns TRUE if the mutex specified is locked and FALSE - * otherwise. - */ - -STATIC INLINE boolean _CORE_mutex_Is_locked( - CORE_mutex_Control *the_mutex -); - -/* - * _CORE_mutex_Is_fifo - * - * DESCRIPTION: - * - * This routine returns TRUE if the mutex's wait discipline is FIFO and FALSE - * otherwise. - */ - -STATIC INLINE boolean _CORE_mutex_Is_fifo( - CORE_mutex_Attributes *the_attribute -); - -/* - * _CORE_mutex_Is_priority - * - * DESCRIPTION: - * - * This routine returns TRUE if the mutex's wait discipline is PRIORITY and - * FALSE otherwise. - */ - -STATIC INLINE boolean _CORE_mutex_Is_priority( - CORE_mutex_Attributes *the_attribute -); - -/* - * _CORE_mutex_Is_inherit_priority - * - * DESCRIPTION: - * - * This routine returns TRUE if the mutex's wait discipline is - * INHERIT_PRIORITY and FALSE otherwise. - */ - -STATIC INLINE boolean _CORE_mutex_Is_inherit_priority( - CORE_mutex_Attributes *the_attribute -); - -/* - * _CORE_mutex_Is_priority_ceiling - * - * DESCRIPTION: - * - * This routine returns TRUE if the mutex's wait discipline is - * PRIORITY_CEILING and FALSE otherwise. - */ - -STATIC INLINE boolean _CORE_mutex_Is_priority_ceiling( - CORE_mutex_Attributes *the_attribute -); - -/* - * _CORE_mutex_Is_nesting_allowed - * - * DESCRIPTION: - * - * This routine returns TRUE if the mutex allows a task to obtain a - * semaphore more than once and nest. - */ - -STATIC INLINE boolean _CORE_mutex_Is_nesting_allowed( - CORE_mutex_Attributes *the_attribute -); - +#ifndef __RTEMS_APPLICATION__ #include <rtems/score/coremutex.inl> +#endif #ifdef __cplusplus } diff --git a/cpukit/score/include/rtems/score/coresem.h b/cpukit/score/include/rtems/score/coresem.h index cf40da4783..88f712be5d 100644 --- a/cpukit/score/include/rtems/score/coresem.h +++ b/cpukit/score/include/rtems/score/coresem.h @@ -143,32 +143,9 @@ void _CORE_semaphore_Flush( unsigned32 status ); -/* - * _CORE_semaphore_Get_count - * - * DESCRIPTION: - * - * This routine returns the current count associated with the semaphore. - */ - -STATIC INLINE unsigned32 _CORE_semaphore_Get_count( - CORE_semaphore_Control *the_semaphore -); - -/* - * _CORE_semaphore_Is_priority - * - * DESCRIPTION: - * - * This function returns TRUE if the priority attribute is - * enabled in the attribute_set and FALSE otherwise. - */ - -STATIC INLINE boolean _CORE_semaphore_Is_priority( - CORE_semaphore_Attributes *the_attribute -); - +#ifndef __RTEMS_APPLICATION__ #include <rtems/score/coresem.inl> +#endif #ifdef __cplusplus } diff --git a/cpukit/score/include/rtems/score/heap.h b/cpukit/score/include/rtems/score/heap.h index dd50a0de8a..c1a0650d0a 100644 --- a/cpukit/score/include/rtems/score/heap.h +++ b/cpukit/score/include/rtems/score/heap.h @@ -214,189 +214,9 @@ void _Heap_Walk( boolean do_dump ); -/* - * _Heap_Head - * - * DESCRIPTION: - * - * This function returns the head of the specified heap. - */ - -STATIC INLINE Heap_Block *_Heap_Head ( - Heap_Control *the_heap -); - -/* - * _Heap_Tail - * - * DESCRIPTION: - * - * This function returns the tail of the specified heap. - */ - -STATIC INLINE Heap_Block *_Heap_Tail ( - Heap_Control *the_heap -); - -/* - * _Heap_Previous_block - * - * DESCRIPTION: - * - * This function returns the address of the block which physically - * precedes the_block in memory. - */ - -STATIC INLINE Heap_Block *_Heap_Previous_block ( - Heap_Block *the_block -); - -/* - * _Heap_Next_block - * - * DESCRIPTION: - * - * This function returns the address of the block which physically - * follows the_block in memory. - */ - -STATIC INLINE Heap_Block *_Heap_Next_block ( - Heap_Block *the_block -); - -/* - * _Heap_Block_at - * - * DESCRIPTION: - * - * This function calculates and returns a block's location (address) - * in the heap based upad a base address and an offset. - */ - -STATIC INLINE Heap_Block *_Heap_Block_at( - void *base, - unsigned32 offset -); - -/*PAGE - * - * _Heap_User_block_at - * - */ - -STATIC INLINE Heap_Block *_Heap_User_block_at( - void *base -); - -/* - * _Heap_Is_previous_block_free - * - * DESCRIPTION: - * - * This function returns TRUE if the previous block of the_block - * is free, and FALSE otherwise. - */ - -STATIC INLINE boolean _Heap_Is_previous_block_free ( - Heap_Block *the_block -); - -/* - * _Heap_Is_block_free - * - * DESCRIPTION: - * - * This function returns TRUE if the block is free, and FALSE otherwise. - */ - -STATIC INLINE boolean _Heap_Is_block_free ( - Heap_Block *the_block -); - -/* - * _Heap_Is_block_used - * - * DESCRIPTION: - * - * This function returns TRUE if the block is currently allocated, - * and FALSE otherwise. - */ - -STATIC INLINE boolean _Heap_Is_block_used ( - Heap_Block *the_block -); - -/* - * _Heap_Block_size - * - * DESCRIPTION: - * - * This function returns the size of the_block in bytes. - */ - -STATIC INLINE unsigned32 _Heap_Block_size ( - Heap_Block *the_block -); - -/* - * _Heap_Start_of_user_area - * - * DESCRIPTION: - * - * This function returns the starting address of the portion of the block - * which the user may access. - */ - -STATIC INLINE void *_Heap_Start_of_user_area ( - Heap_Block *the_block -); - -/* - * _Heap_Is_block_in - * - * DESCRIPTION: - * - * This function returns TRUE if the_block is within the memory area - * managed by the_heap, and FALSE otherwise. - */ - -STATIC INLINE boolean _Heap_Is_block_in ( - Heap_Control *the_heap, - Heap_Block *the_block -); - - -/* - * _Heap_Is_page_size_valid - * - * DESCRIPTION: - * - * This function validates a specified heap page size. If the page size - * is 0 or if lies outside a page size alignment boundary it is invalid - * and FALSE is returned. Otherwise, the page size is valid and TRUE is - * returned. - */ - -STATIC INLINE boolean _Heap_Is_page_size_valid( - unsigned32 page_size -); - -/* - * _Heap_Build_flag - * - * DESCRIPTION: - * - * This function returns the block flag composed of size and in_use_flag. - * The flag returned is suitable for use as a back or front flag in a - * heap block. - */ - -STATIC INLINE unsigned32 _Heap_Build_flag ( - unsigned32 size, - unsigned32 in_use_flag -); - +#ifndef __RTEMS_APPLICATION__ #include <rtems/score/heap.inl> +#endif #ifdef __cplusplus } diff --git a/cpukit/score/include/rtems/score/isr.h b/cpukit/score/include/rtems/score/isr.h index bb80823cfb..e42d7b888e 100644 --- a/cpukit/score/include/rtems/score/isr.h +++ b/cpukit/score/include/rtems/score/isr.h @@ -141,19 +141,6 @@ void _ISR_Handler_initialization ( void ); _CPU_ISR_Flash( _level ) /* - * _ISR_Is_in_progress - * - * DESCRIPTION: - * - * This function returns TRUE if the processor is currently servicing - * and interrupt and FALSE otherwise. A return value of TRUE indicates - * that the caller is an interrupt service routine, NOT a thread. The - * directives available to an interrupt service routine are restricted. - */ - -STATIC INLINE boolean _ISR_Is_in_progress( void ); - -/* * _ISR_Install_vector * * DESCRIPTION: @@ -191,32 +178,6 @@ STATIC INLINE boolean _ISR_Is_in_progress( void ); _CPU_ISR_Set_level( _new_level ) /* - * _ISR_Is_vector_number_valid - * - * DESCRIPTION: - * - * This function returns TRUE if the vector is a valid vector number - * for this processor and FALSE otherwise. - */ - -STATIC INLINE boolean _ISR_Is_vector_number_valid ( - ISR_Vector_number vector -); - -/* - * _ISR_Is_valid_user_handler - * - * DESCRIPTION: - * - * This function returns TRUE if handler is the entry point of a valid - * use interrupt service routine and FALSE otherwise. - */ - -STATIC INLINE boolean _ISR_Is_valid_user_handler ( - void *handler -); - -/* * _ISR_Handler * * DESCRIPTION: @@ -253,7 +214,9 @@ void _ISR_Handler( void ); void _ISR_Dispatch( void ); +#ifndef __RTEMS_APPLICATION__ #include <rtems/score/isr.inl> +#endif #ifdef __cplusplus } diff --git a/cpukit/score/include/rtems/score/mppkt.h b/cpukit/score/include/rtems/score/mppkt.h index 37469d93b8..0c651bc4e8 100644 --- a/cpukit/score/include/rtems/score/mppkt.h +++ b/cpukit/score/include/rtems/score/mppkt.h @@ -88,33 +88,9 @@ typedef struct { #define MP_PACKET_MINIMUN_HETERO_CONVERSION ( sizeof( MP_packet_Prefix ) / 4 ) -/* - * _Mp_packet_Is_valid_packet_class - * - * DESCRIPTION: - * - * This function returns TRUE if the the_packet_class is valid, - * and FALSE otherwise. - */ - -STATIC INLINE boolean _Mp_packet_Is_valid_packet_class ( - MP_packet_Classes the_packet_class -); - -/* - * _Mp_packet_Is_null - * - * DESCRIPTION: - * - * This function returns TRUE if the the_packet_class is null, - * and FALSE otherwise. - */ - -STATIC INLINE boolean _Mp_packet_Is_null ( - MP_packet_Prefix *the_packet -); - +#ifndef __RTEMS_APPLICATION__ #include <rtems/score/mppkt.inl> +#endif #ifdef __cplusplus } diff --git a/cpukit/score/include/rtems/score/object.h b/cpukit/score/include/rtems/score/object.h index 2c93a44379..d70009c3c9 100644 --- a/cpukit/score/include/rtems/score/object.h +++ b/cpukit/score/include/rtems/score/object.h @@ -383,176 +383,9 @@ Objects_Information *_Objects_Get_information( ); /* - * _Objects_Build_id - * - * DESCRIPTION: - * - * This function builds an object's id from the processor node and index - * values specified. - * - */ - -STATIC INLINE Objects_Id _Objects_Build_id( - Objects_Classes the_class, - unsigned32 node, - unsigned32 index -); - -/* - * _Objects_Get_class - * - * DESCRIPTION: - * - * This function returns the class portion of the ID. - * - */ - -STATIC INLINE Objects_Classes _Objects_Get_class( - Objects_Id id -); - -/* - * _Objects_Get_node - * - * DESCRIPTION: - * - * This function returns the node portion of the ID. - * - */ - -STATIC INLINE unsigned32 _Objects_Get_node( - Objects_Id id -); - -/* - * _Objects_Get_index - * - * DESCRIPTION: - * - * This function returns the index portion of the ID. - * - */ - -STATIC INLINE unsigned32 _Objects_Get_index( - Objects_Id id -); - -/* - * _Objects_Is_class_valid - * - * DESCRIPTION: - * - * This function returns TRUE if the class is valid. - * - */ - -STATIC INLINE boolean _Objects_Is_class_valid( - Objects_Classes the_class -); - -/* - * _Objects_Is_local_node - * - * DESCRIPTION: - * - * This function returns TRUE if the node is of the local object, and - * FALSE otherwise. - * - */ - -STATIC INLINE boolean _Objects_Is_local_node( - unsigned32 node -); - -/* - * _Objects_Is_local_id - * - * DESCRIPTION: - * - * This function returns TRUE if the id is of a local object, and - * FALSE otherwise. - * - */ - -STATIC INLINE boolean _Objects_Is_local_id( - Objects_Id id -); - -/* - * _Objects_Are_ids_equal - * - * DESCRIPTION: - * - * This function returns TRUE if left and right are equal, - * and FALSE otherwise. - * - */ - -STATIC INLINE boolean _Objects_Are_ids_equal( - Objects_Id left, - Objects_Id right -); - -/* - * _Objects_Allocate - * - * DESCRIPTION: - * - * This function allocates a object control block from - * the inactive chain of free object control blocks. - * - */ - -STATIC INLINE Objects_Control *_Objects_Allocate( - Objects_Information *information -); - -/* - * _Objects_Free - * - * DESCRIPTION: - * - * This function frees a object control block to the - * inactive chain of free object control blocks. - * - */ - -STATIC INLINE void _Objects_Free( - Objects_Information *information, - Objects_Control *the_object -); - -/* - * _Objects_Open - * - * DESCRIPTION: - * - * This function places the_object control pointer and object name - * in the Local Pointer and Local Name Tables, respectively. - * + * Pieces of object.inl are promoted out to the user */ -STATIC INLINE void _Objects_Open( - Objects_Information *information, - Objects_Control *the_object, - Objects_Name name -); - -/* - * _Objects_Close - * - * DESCRIPTION: - * - * This function removes the_object control pointer and object name - * in the Local Pointer and Local Name Tables. - * - */ - -STATIC INLINE void _Objects_Close( - Objects_Information *information, - Objects_Control *the_object -); - #include <rtems/score/object.inl> #include <rtems/score/objectmp.h> diff --git a/cpukit/score/include/rtems/score/objectmp.h b/cpukit/score/include/rtems/score/objectmp.h index dbd468e169..96496656df 100644 --- a/cpukit/score/include/rtems/score/objectmp.h +++ b/cpukit/score/include/rtems/score/objectmp.h @@ -47,42 +47,6 @@ void _Objects_MP_Handler_initialization ( unsigned32 maximum_global_objects ); -/* - * _Objects_MP_Allocate_global_object - * - * DESCRIPTION: - * - * This function allocates a Global Object control block. - */ - -STATIC INLINE Objects_MP_Control *_Objects_MP_Allocate_global_object ( - void -); - -/* - * _Objects_MP_Free_global_object - * - * DESCRIPTION: - * - * This routine deallocates a Global Object control block. - */ - -STATIC INLINE void _Objects_MP_Free_global_object ( - Objects_MP_Control *the_object -); - -/* - * _Objects_MP_Is_null_global_object - * - * DESCRIPTION: - * - * This function returns whether the global object is NULL or not. - */ - -STATIC INLINE boolean _Objects_MP_Is_null_global_object ( - Objects_MP_Control *the_object -); - /*PAGE * * _Objects_MP_Open @@ -176,7 +140,9 @@ void _Objects_MP_Is_remote ( EXTERN unsigned32 _Objects_MP_Maximum_global_objects; EXTERN Chain_Control _Objects_MP_Inactive_global_objects; +#ifndef __RTEMS_APPLICATION__ #include <rtems/score/objectmp.inl> +#endif #ifdef __cplusplus } diff --git a/cpukit/score/include/rtems/score/priority.h b/cpukit/score/include/rtems/score/priority.h index a4a96045d5..b7de14f0f9 100644 --- a/cpukit/score/include/rtems/score/priority.h +++ b/cpukit/score/include/rtems/score/priority.h @@ -67,164 +67,26 @@ EXTERN Priority_Bit_map_control _Priority_Bit_map[16] CPU_STRUCTURE_ALIGNMENT; */ /* - * _Priority_Handler_initialization + * Priority Bitfield Manipulation Routines * - * DESCRIPTION: + * NOTE: * - * This routine performs the initialization necessary for this handler. - */ - -STATIC INLINE void _Priority_Handler_initialization( void ); - -/* - * _Priority_Is_valid - * - * DESCRIPTION: - * - * This function returns TRUE if the_priority if valid for a - * user task, and FALSE otherwise. - */ - -STATIC INLINE boolean _Priority_Is_valid ( - Priority_Control the_priority -); - -/* - * _Priority_Major - * - * DESCRIPTION: - * - * This function returns the major portion of the_priority. - */ - -STATIC INLINE unsigned32 _Priority_Major ( - Priority_Control the_priority -); - -/* - * _Priority_Minor - * - * DESCRIPTION: - * - * This function returns the minor portion of the_priority. - */ - -STATIC INLINE unsigned32 _Priority_Minor ( - Priority_Control the_priority -); - -/* - * _Priority_Mask - * - * DESCRIPTION: - * - * This function returns the mask associated with the major or minor - * number passed to it. + * These may simply be pass throughs to CPU dependent routines. */ -#if ( CPU_USE_GENERIC_BITFIELD_CODE == TRUE ) - -STATIC INLINE unsigned32 _Priority_Mask ( - unsigned32 bit_number -); - -#else +#if ( CPU_USE_GENERIC_BITFIELD_CODE == FALSE ) #define _Priority_Mask( _bit_number ) \ _CPU_Priority_Mask( _bit_number ) -#endif - -/* - * _Priority_Bits_index - * - * DESCRIPTION: - * - * This function translates the bit numbers returned by the bit scan - * of a priority bit field into something suitable for use as - * a major or minor component of a priority. - */ - -#if ( CPU_USE_GENERIC_BITFIELD_CODE == TRUE ) - -STATIC INLINE unsigned32 _Priority_Bits_index ( - unsigned32 bit_number -); - -#else - #define _Priority_Bits_index( _priority ) \ _CPU_Priority_bits_index( _priority ) #endif -/* - * _Priority_Add_to_bit_map - * - * DESCRIPTION: - * - * This routine uses the_priority_map to update the priority - * bit maps to indicate that a thread has been readied. - */ - -STATIC INLINE void _Priority_Add_to_bit_map ( - Priority_Information *the_priority_map -); - -/* - * _Priority_Remove_from_bit_map - * - * DESCRIPTION: - * - * This routine uses the_priority_map to update the priority - * bit maps to indicate that a thread has been removed from the - * ready state. - */ - -STATIC INLINE void _Priority_Remove_from_bit_map ( - Priority_Information *the_priority_map -); - -/* - * _Priority_Get_highest - * - * DESCRIPTION: - * - * This function returns the priority of the highest priority - * ready thread. - */ - -STATIC INLINE Priority_Control _Priority_Get_highest( void ); - -/* - * _Priority_Initialize_information - * - * DESCRIPTION: - * - * This routine initializes the_priority_map so that it - * contains the information necessary to manage a thread - * at new_priority. - */ - -STATIC INLINE void _Priority_Initialize_information( - Priority_Information *the_priority_map, - Priority_Control new_priority -); - -/* - * _Priority_Is_group_empty - * - * DESCRIPTION: - * - * This function returns TRUE if the priority GROUP is empty, and - * FALSE otherwise. - */ - -STATIC INLINE boolean _Priority_Is_group_empty ( - Priority_Control the_priority -); - +#ifndef __RTEMS_APPLICATION__ #include <rtems/score/priority.inl> +#endif #ifdef __cplusplus } diff --git a/cpukit/score/include/rtems/score/stack.h b/cpukit/score/include/rtems/score/stack.h index a054dae3df..bf72782b42 100644 --- a/cpukit/score/include/rtems/score/stack.h +++ b/cpukit/score/include/rtems/score/stack.h @@ -38,54 +38,9 @@ typedef struct { void *area; /* low memory addr of stack */ } Stack_Control; -/* - * _Stack_Initialize - * - * DESCRIPTION: - * - * This routine initializes the_stack record to indicate that - * size bytes of memory starting at starting_address have been - * reserved for a stack. - */ - -STATIC INLINE void _Stack_Initialize ( - Stack_Control *the_stack, - void *starting_address, - unsigned32 size -); - -/* - * _Stack_Is_enough - * - * DESCRIPTION: - * - * This function returns TRUE if size bytes is enough memory for - * a valid stack area on this processor, and FALSE otherwise. - */ - -STATIC INLINE boolean _Stack_Is_enough ( - unsigned32 size -); - -/* - * _Stack_Adjust_size - * - * DESCRIPTION: - * - * This function increases the stack size to insure that the thread - * has the desired amount of stack space after the initial stack - * pointer is determined based on alignment restrictions. - * - * NOTE: - * - * The amount of adjustment for alignment is CPU dependent. - */ - -STATIC INLINE unsigned32 _Stack_Adjust_size ( - unsigned32 size -); - +#ifndef __RTEMS_APPLICATION__ #include <rtems/score/stack.inl> +#endif #ifdef __cplusplus } diff --git a/cpukit/score/include/rtems/score/states.h b/cpukit/score/include/rtems/score/states.h index a120cadae3..1f8fd49fae 100644 --- a/cpukit/score/include/rtems/score/states.h +++ b/cpukit/score/include/rtems/score/states.h @@ -66,285 +66,9 @@ typedef unsigned32 States_Control; STATES_WAITING_FOR_EVENT | \ STATES_WAITING_ON_THREAD_QUEUE ) -/* - * _States_Set - * - * DESCRIPTION: - * - * This function sets the given states_to_set into the current_state - * passed in. The result is returned to the user in current_state. - */ - -STATIC INLINE States_Control _States_Set ( - States_Control states_to_set, - States_Control current_state -); - -/* - * _States_Clear - * - * DESCRIPTION: - * - * This function clears the given states_to_clear into the current_state - * passed in. The result is returned to the user in current_state. - */ - -STATIC INLINE States_Control _States_Clear ( - States_Control states_to_clear, - States_Control current_state -); - -/* - * _States_Is_ready - * - * DESCRIPTION: - * - * This function returns TRUE if the_states indicates that the - * state is READY, and FALSE otherwise. - */ - -STATIC INLINE boolean _States_Is_ready ( - States_Control the_states -); - -/* - * _States_Is_only_dormant - * - * DESCRIPTION: - * - * This function returns TRUE if the DORMANT state is the ONLY state - * set in the_states, and FALSE otherwise. - */ - -STATIC INLINE boolean _States_Is_only_dormant ( - States_Control the_states -); - -/* - * _States_Is_dormant - * - * DESCRIPTION: - * - * This function returns TRUE if the DORMANT state is set in - * the_states, and FALSE otherwise. - */ - -STATIC INLINE boolean _States_Is_dormant ( - States_Control the_states -); - -/* - * _States_Is_suspended - * - * DESCRIPTION: - * - * This function returns TRUE if the SUSPENDED state is set in - * the_states, and FALSE otherwise. - */ - -STATIC INLINE boolean _States_Is_suspended ( - States_Control the_states -); - -/* - * _States_Is_Transient - * - * DESCRIPTION: - * - * This function returns TRUE if the TRANSIENT state is set in - * the_states, and FALSE otherwise. - */ - -STATIC INLINE boolean _States_Is_transient ( - States_Control the_states -); - -/* - * _States_Is_delaying - * - * DESCRIPTION: - * - * This function returns TRUE if the DELAYING state is set in - * the_states, and FALSE otherwise. - */ - -STATIC INLINE boolean _States_Is_delaying ( - States_Control the_states -); - -/* - * _States_Is_waiting_for_buffer - * - * DESCRIPTION: - * - * This function returns TRUE if the WAITING_FOR_BUFFER state is set in - * the_states, and FALSE otherwise. - */ - -STATIC INLINE boolean _States_Is_waiting_for_buffer ( - States_Control the_states -); - -/* - * _States_Is_waiting_for_segment - * - * DESCRIPTION: - * - * This function returns TRUE if the WAITING_FOR_SEGMENT state is set in - * the_states, and FALSE otherwise. - */ - -STATIC INLINE boolean _States_Is_waiting_for_segment ( - States_Control the_states -); - -/* - * _States_Is_waiting_for_message - * - * DESCRIPTION: - * - * This function returns TRUE if the WAITING_FOR_MESSAGE state is set in - * the_states, and FALSE otherwise. - */ - -STATIC INLINE boolean _States_Is_waiting_for_message ( - States_Control the_states -); - -/* - * _States_Is_waiting_for_event - * - * DESCRIPTION: - * - * This function returns TRUE if the WAITING_FOR_EVENT state is set in - * the_states, and FALSE otherwise. - */ - -STATIC INLINE boolean _States_Is_waiting_for_event ( - States_Control the_states -); - -/* - * _States_Is_waiting_for_mutex - * - * DESCRIPTION: - * - * This function returns TRUE if the WAITING_FOR_MUTEX state - * is set in the_states, and FALSE otherwise. - */ - -STATIC INLINE boolean _States_Is_waiting_for_mutex ( - States_Control the_states -); - -/* - * _States_Is_waiting_for_semaphore - * - * DESCRIPTION: - * - * This function returns TRUE if the WAITING_FOR_SEMAPHORE state - * is set in the_states, and FALSE otherwise. - */ - -STATIC INLINE boolean _States_Is_waiting_for_semaphore ( - States_Control the_states -); - -/* - * _States_Is_waiting_for_time - * - * DESCRIPTION: - * - * This function returns TRUE if the WAITING_FOR_TIME state is set in - * the_states, and FALSE otherwise. - */ - -STATIC INLINE boolean _States_Is_waiting_for_time ( - States_Control the_states -); - -/* - * _States_Is_waiting_for_rpc_reply - * - * DESCRIPTION: - * - * This function returns TRUE if the WAITING_FOR_TIME state is set in - * the_states, and FALSE otherwise. - */ - -STATIC INLINE boolean _States_Is_waiting_for_rpc_reply ( - States_Control the_states -); - -/* - * _States_Is_waiting_for_period - * - * DESCRIPTION: - * - * This function returns TRUE if the WAITING_FOR_PERIOD state is set in - * the_states, and FALSE otherwise. - */ - -STATIC INLINE boolean _States_Is_waiting_for_period ( - States_Control the_states -); - -/* - * _States_Is_locally_blocked - * - * DESCRIPTION: - * - * This function returns TRUE if one of the states which indicates - * that a task is blocked waiting for a local resource is set in - * the_states, and FALSE otherwise. - */ - -STATIC INLINE boolean _States_Is_locally_blocked ( - States_Control the_states -); - -/* - * _States_Is_waiting_on_thread_queue - * - * DESCRIPTION: - * - * This function returns TRUE if one of the states which indicates - * that a task is blocked waiting for a local resource is set in - * the_states, and FALSE otherwise. - */ - -STATIC INLINE boolean _States_Is_waiting_on_thread_queue ( - States_Control the_states -); - -/* - * _States_Is_blocked - * - * DESCRIPTION: - * - * This function returns TRUE if one of the states which indicates - * that a task is blocked is set in the_states, and FALSE otherwise. - */ - -STATIC INLINE boolean _States_Is_blocked ( - States_Control the_states -); - -/* - * _States_Are_set - * - * DESCRIPTION: - * - * This function returns TRUE if any of the states in the mask - * are set in the_states, and FALSE otherwise. - */ - -STATIC INLINE boolean _States_Are_set ( - States_Control the_states, - States_Control mask -); - +#ifndef __RTEMS_APPLICATION__ #include <rtems/score/states.inl> +#endif #ifdef __cplusplus } diff --git a/cpukit/score/include/rtems/score/sysstate.h b/cpukit/score/include/rtems/score/sysstate.h index c5d8562001..d7e43b2356 100644 --- a/cpukit/score/include/rtems/score/sysstate.h +++ b/cpukit/score/include/rtems/score/sysstate.h @@ -53,105 +53,9 @@ EXTERN boolean _System_state_Is_multiprocessing; EXTERN System_state_Codes _System_state_Current; /* - * _System_state_Handler_initialization - * - * DESCRIPTION: - * - * This routine initializes the system state handler. - */ - -STATIC INLINE void _System_state_Handler_initialization ( - boolean is_multiprocessing -); - -/* - * _System_state_Set - * - * DESCRIPTION: - * - * This routine sets the current system state to that specified by - * the called. + * Make it possible for the application to get the system state information. */ -STATIC INLINE void _System_state_Set ( - System_state_Codes state -); - -/* - * _System_state_Get - * - * DESCRIPTION: - * - * This function returns the current system state. - */ - -STATIC INLINE System_state_Codes _System_state_Get ( void ); - -/* - * _System_state_Is_before_initialization - * - * DESCRIPTION: - * - * This function returns TRUE if the state is equal to the - * "before initialization" state, and FALSE otherwise. - */ - -STATIC INLINE boolean _System_state_Is_before_initialization ( - System_state_Codes state -); - -/* - * _System_state_Is_before_multitasking - * - * DESCRIPTION: - * - * This function returns TRUE if the state is equal to the - * "before multitasking" state, and FALSE otherwise. - */ - -STATIC INLINE boolean _System_state_Is_before_multitasking ( - System_state_Codes state -); - -/* - * _System_state_Is_begin_multitasking - * - * DESCRIPTION: - * - * This function returns TRUE if the state is equal to the - * "begin multitasking" state, and FALSE otherwise. - */ - -STATIC INLINE boolean _System_state_Is_begin_multitasking ( - System_state_Codes state -); - -/* - * _System_state_Is_up - * - * DESCRIPTION: - * - * This function returns TRUE if the state is equal to the - * "up" state, and FALSE otherwise. - */ - -STATIC INLINE boolean _System_state_Is_up ( - System_state_Codes state -); - -/* - * _System_state_Is_failed - * - * DESCRIPTION: - * - * This function returns TRUE if the state is equal to the - * "failed" state, and FALSE otherwise. - */ - -STATIC INLINE boolean _System_state_Is_failed ( - System_state_Codes state -); - #include <rtems/score/sysstate.inl> #ifdef __cplusplus diff --git a/cpukit/score/include/rtems/score/thread.h b/cpukit/score/include/rtems/score/thread.h index d904df439b..8abf7c3584 100644 --- a/cpukit/score/include/rtems/score/thread.h +++ b/cpukit/score/include/rtems/score/thread.h @@ -284,28 +284,6 @@ void _Thread_Create_idle( void ); void _Thread_Start_multitasking( void ); /* - * _Thread_Stop_multitasking - * - * DESCRIPTION: - * - * This routine halts multitasking and returns control to - * the "thread" (i.e. the BSP) which initially invoked the - * routine which initialized the system. - */ - -STATIC INLINE void _Thread_Stop_multitasking( void ); - -/* - * _Thread_Dispatch_initialization - * - * DESCRIPTION: - * - * This routine initializes the thread dispatching subsystem. - */ - -STATIC INLINE void _Thread_Dispatch_initialization( void ); - -/* * _Thread_Dispatch * * DESCRIPTION: @@ -487,43 +465,6 @@ void _Thread_Tickle_timeslice( void ); void _Thread_Yield_processor( void ); /* - * _Thread_Is_executing - * - * DESCRIPTION: - * - * This function returns TRUE if the_thread is the currently executing - * thread, and FALSE otherwise. - */ - -STATIC INLINE boolean _Thread_Is_executing ( - Thread_Control *the_thread -); - -/* - * _Thread_Is_heir - * - * DESCRIPTION: - * - * This function returns TRUE if the_thread is the heir - * thread, and FALSE otherwise. - */ - -STATIC INLINE boolean _Thread_Is_executing ( - Thread_Control *the_thread -); - -/* - * _Thread_Is_executing_also_the_heir - * - * DESCRIPTION: - * - * This function returns TRUE if the currently executing thread - * is also the heir thread, and FALSE otherwise. - */ - -STATIC INLINE boolean _Thread_Is_executing_also_the_heir( void ); - -/* * _Thread_Load_environment * * DESCRIPTION: @@ -604,215 +545,6 @@ void _Thread_Set_priority( boolean _Thread_Evaluate_mode( void ); /* - * _Thread_Resume - * - * DESCRIPTION: - * - * This routine clears the SUSPENDED state for the_thread. It performs - * any necessary scheduling operations including the selection of - * a new heir thread. - */ - -STATIC INLINE void _Thread_Resume ( - Thread_Control *the_thread -); - -/* - * _Thread_Unblock - * - * DESCRIPTION: - * - * This routine clears any blocking state for the_thread. It performs - * any necessary scheduling operations including the selection of - * a new heir thread. - */ - -STATIC INLINE void _Thread_Unblock ( - Thread_Control *the_thread -); - -/* - * _Thread_Restart_self - * - * DESCRIPTION: - * - * This routine resets the current context of the calling thread - * to that of its initial state. - */ - -STATIC INLINE void _Thread_Restart_self( void ); - -/* - * _Thread_Calculate_heir - * - * DESCRIPTION: - * - * This function returns a pointer to the highest priority - * ready thread. - */ - -STATIC INLINE void _Thread_Calculate_heir( void ); - -/* - * _Thread_Is_allocated_fp - * - * DESCRIPTION: - * - * This function returns TRUE if the floating point context of - * the_thread is currently loaded in the floating point unit, and - * FALSE otherwise. - */ - -STATIC INLINE boolean _Thread_Is_allocated_fp ( - Thread_Control *the_thread -); - -/* - * _Thread_Deallocate_fp - * - * DESCRIPTION: - * - * This routine is invoked when the currently loaded floating - * point context is now longer associated with an active thread. - */ - -STATIC INLINE void _Thread_Deallocate_fp( void ); - -/* - * _Thread_Disable_dispatch - * - * DESCRIPTION: - * - * This routine prevents dispatching. - */ - -STATIC INLINE void _Thread_Disable_dispatch( void ); - -/* - * _Thread_Enable_dispatch - * - * DESCRIPTION: - * - * This routine allows dispatching to occur again. If this is - * the outer most dispatching critical section, then a dispatching - * operation will be performed and, if necessary, control of the - * processor will be transferred to the heir thread. - */ - -#if ( CPU_INLINE_ENABLE_DISPATCH == TRUE ) - -STATIC INLINE void _Thread_Enable_dispatch(); - -#endif - -#if ( CPU_INLINE_ENABLE_DISPATCH == FALSE ) - -void _Thread_Enable_dispatch( void ); - -#endif - -/* - * _Thread_Unnest_dispatch - * - * DESCRIPTION: - * - * This routine allows dispatching to occur again. However, - * no dispatching operation is performed even if this is the outer - * most dispatching critical section. - */ - -STATIC INLINE void _Thread_Unnest_dispatch( void ); - -/* - * _Thread_Is_dispatching_enabled - * - * DESCRIPTION: - * - * This function returns TRUE if dispatching is disabled, and FALSE - * otherwise. - */ - -STATIC INLINE boolean _Thread_Is_dispatching_enabled( void ); - -/* - * _Thread_Is_context_switch_necessary - * - * DESCRIPTION: - * - * This function returns TRUE if dispatching is disabled, and FALSE - * otherwise. - */ - -STATIC INLINE boolean _Thread_Is_context_switch_necessary( void ); - -/* - * _Thread_Is_null - * - * DESCRIPTION: - * - * This function returns TRUE if the_thread is NULL and FALSE otherwise. - */ - -STATIC INLINE boolean _Thread_Is_null ( - Thread_Control *the_thread -); - -/* - * _Thread_Get - * - * DESCRIPTION: - * - * This function maps thread IDs to thread control - * blocks. If ID corresponds to a local thread, then it - * returns the_thread control pointer which maps to ID - * and location is set to OBJECTS_LOCAL. If the thread ID is - * global and resides on a remote node, then location is set - * to OBJECTS_REMOTE, and the_thread is undefined. - * Otherwise, location is set to OBJECTS_ERROR and - * the_thread is undefined. - */ - -STATIC INLINE Thread_Control *_Thread_Get ( - Objects_Id id, - Objects_Locations *location -); - -/* - * _Thread_Is_proxy_blocking - * - * DESCRIPTION: - * - * This function returns TRUE if the status code is equal to the - * status which indicates that a proxy is blocking, and FALSE otherwise. - */ - -STATIC INLINE boolean _Thread_Is_proxy_blocking ( - unsigned32 code -); - -/* - * _Thread_Internal_allocate - * - * DESCRIPTION: - * - * This routine allocates an internal thread. - */ - -STATIC INLINE Thread_Control *_Thread_Internal_allocate( void ); - -/* - * _Thread_Internal_free - * - * DESCRIPTION: - * - * This routine frees an internal thread. - */ - -STATIC INLINE void _Thread_Internal_free ( - Thread_Control *the_task -); - -/* * _Thread_Idle_body * * DESCRIPTION: @@ -826,7 +558,9 @@ Thread _Thread_Idle_body( ); #endif +#ifndef __RTEMS_APPLICATION__ #include <rtems/score/thread.inl> +#endif #include <rtems/score/threadmp.h> #ifdef __cplusplus diff --git a/cpukit/score/include/rtems/score/threadmp.h b/cpukit/score/include/rtems/score/threadmp.h index 4afc965381..0466a04065 100644 --- a/cpukit/score/include/rtems/score/threadmp.h +++ b/cpukit/score/include/rtems/score/threadmp.h @@ -26,8 +26,7 @@ extern "C" { * * DESCRIPTION: * - * This package is the specification for the Thread Handler's - * multiprocessing specific support routines. + * This routine initializes the multiprocessing portion of the Thread Handler. */ void _Thread_MP_Handler_initialization ( @@ -35,19 +34,6 @@ void _Thread_MP_Handler_initialization ( ); /* - * _Thread_MP_Is_receive - * - * DESCRIPTION: - * - * This function returns true if the thread in question is the - * multiprocessing receive thread. - */ - -STATIC INLINE boolean _Thread_MP_Is_receive ( - Thread_Control *the_thread -); - -/* * _Thread_MP_Allocate_proxy * * DESCRIPTION: @@ -64,19 +50,6 @@ Thread_Control *_Thread_MP_Allocate_proxy ( ); /* - * _Thread_MP_Free_proxy - * - * DESCRIPTION: - * - * This routine frees a proxy control block to the - * inactive chain of free proxy control blocks. - */ - -STATIC INLINE void _Thread_MP_Free_proxy ( - Thread_Control *the_thread -); - -/* * _Thread_MP_Find_proxy * * DESCRIPTION: @@ -104,7 +77,9 @@ EXTERN Thread_Control *_Thread_MP_Receive; EXTERN Chain_Control _Thread_MP_Active_proxies; EXTERN Chain_Control _Thread_MP_Inactive_proxies; +#ifndef __RTEMS_APPLICATION__ #include <rtems/score/threadmp.inl> +#endif #ifdef __cplusplus } diff --git a/cpukit/score/include/rtems/score/tod.h b/cpukit/score/include/rtems/score/tod.h index 89ff118c33..b0fb686014 100644 --- a/cpukit/score/include/rtems/score/tod.h +++ b/cpukit/score/include/rtems/score/tod.h @@ -205,50 +205,6 @@ Watchdog_Interval _TOD_To_seconds( ); /* - * _TOD_Is_set - * - * DESCRIPTION: - * - * This function returns TRUE if the application has set the current - * time of day, and FALSE otherwise. - */ - -STATIC INLINE boolean _TOD_Is_set( void ); - -/* - * _TOD_Tickle_ticks - * - * DESCRIPTION: - * - * This routine increments the ticks field of the current time of - * day at each clock tick. - */ - -STATIC INLINE void _TOD_Tickle_ticks( void ); - -/* - * _TOD_Deactivate - * - * DESCRIPTION: - * - * This routine deactivates updating of the current time of day. - */ - -STATIC INLINE void _TOD_Deactivate( void ); - -/* - * _TOD_Activate - * - * DESCRIPTION: - * - * This routine deactivates updating of the current time of day. - */ - -STATIC INLINE void _TOD_Activate( - Watchdog_Interval ticks -); - -/* * _TOD_Tickle * * DESCRIPTION: @@ -292,7 +248,9 @@ void _TOD_Tickle( #define TOD_MILLISECONDS_TO_TICKS(_ms) \ (TOD_MILLISECONDS_TO_MICROSECONDS(_ms) / _TOD_Microseconds_per_tick) +#ifndef __RTEMS_APPLICATION__ #include <rtems/score/tod.inl> +#endif #ifdef __cplusplus } diff --git a/cpukit/score/include/rtems/score/tqdata.h b/cpukit/score/include/rtems/score/tqdata.h index a4a5551dfd..c9c9585f7f 100644 --- a/cpukit/score/include/rtems/score/tqdata.h +++ b/cpukit/score/include/rtems/score/tqdata.h @@ -48,11 +48,23 @@ typedef enum { } Thread_queue_States; /* - * The following record defines the control block used - * to manage each thread. + * The following constants are used to manage the priority queues. + * + * There are four chains used to maintain a priority -- each chain + * manages a distinct set of task priorities. The number of chains + * is determined by TASK_QUEUE_DATA_NUMBER_OF_PRIORITY_HEADERS. + * The following set must be consistent. + * + * The set below configures 4 headers -- each contains 64 priorities. + * Header x manages priority range (x*64) through ((x*64)+63). If + * the priority is more than half way through the priority range it + * is in, then the search is performed from the rear of the chain. + * This halves the search time to find the insertion point. */ -#define TASK_QUEUE_DATA_NUMBER_OF_PRIORITY_HEADERS 4 /* # of pri groups */ +#define TASK_QUEUE_DATA_NUMBER_OF_PRIORITY_HEADERS 4 +#define TASK_QUEUE_DATA_PRIORITIES_PER_HEADER 64 +#define TASK_QUEUE_DATA_REVERSE_SEARCH_MASK 0x20 typedef struct { union { @@ -67,47 +79,9 @@ typedef struct { unsigned32 count; } Thread_queue_Control; -/* - * _Thread_queue_Header_number - * - * DESCRIPTION: - * - * This function returns the index of the priority chain on which - * a thread of the_priority should be placed. - */ - -STATIC INLINE unsigned32 _Thread_queue_Header_number ( - Priority_Control the_priority -); - -/* - * _Thread_queue_Is_reverse_search - * - * DESCRIPTION: - * - * This function returns TRUE if the_priority indicates that the - * enqueue search should start at the front of this priority - * group chain, and FALSE if the search should start at the rear. - */ - -STATIC INLINE boolean _Thread_queue_Is_reverse_search ( - Priority_Control the_priority -); - -/* - * _Thread_queue_Enter_critical_section - * - * DESCRIPTION: - * - * This routine is invoked to indicate that the specified thread queue is - * entering a critical section. - */ - -STATIC INLINE void _Thread_queue_Enter_critical_section ( - Thread_queue_Control *the_thread_queue -); - +#ifndef __RTEMS_APPLICATION__ #include <rtems/score/tqdata.inl> +#endif #ifdef __cplusplus } diff --git a/cpukit/score/include/rtems/score/userext.h b/cpukit/score/include/rtems/score/userext.h index 58fa087780..1a6ac3437e 100644 --- a/cpukit/score/include/rtems/score/userext.h +++ b/cpukit/score/include/rtems/score/userext.h @@ -108,56 +108,6 @@ EXTERN User_extensions_Control _User_extensions_Initial; EXTERN Chain_Control _User_extensions_List; - -/* - * _User_extensions_Handler_initialization - * - * DESCRIPTION: - * - * This routine performs the initialization necessary for this handler. - */ - -STATIC INLINE void _User_extensions_Handler_initialization ( - User_extensions_Table *initial_extensions -); - -/* - * _User_extensions_Add_set - * - * DESCRIPTION: - * - * This routine is used to add a user extension set to the active list. - */ - -STATIC INLINE void _User_extensions_Add_set ( - User_extensions_Control *the_extension, - User_extensions_Table *extension_table -); - -/* - * _User_extensions_Add_API_set - * - * DESCRIPTION: - * - * This routine is used to add an API extension set to the active list. - */ - -STATIC INLINE void _User_extensions_Add_API_set ( - User_extensions_Control *the_extension -); - -/* - * _User_extensions_Remove_set - * - * DESCRIPTION: - * - * This routine is used to remove a user extension set from the active list. - */ - -STATIC INLINE void _User_extensions_Remove_set ( - User_extensions_Control *the_extension -); - /* * _User_extensions_Thread_create * @@ -211,20 +161,6 @@ void _User_extensions_Thread_restart ( ); /* - * _User_extensions_Thread_switch - * - * DESCRIPTION: - * - * This routine is used to invoke the user extension which - * is invoked when a context switch occurs. - */ - -STATIC INLINE void _User_extensions_Thread_switch ( - Thread_Control *executing, - Thread_Control *heir -); - -/* * _User_extensions_Thread_begin * * DESCRIPTION: @@ -265,7 +201,9 @@ void _User_extensions_Fatal ( unsigned32 the_error ); +#ifndef __RTEMS_APPLICATION__ #include <rtems/score/userext.inl> +#endif #ifdef __cplusplus } diff --git a/cpukit/score/include/rtems/score/watchdog.h b/cpukit/score/include/rtems/score/watchdog.h index 5ac7eee641..9b13407c8e 100644 --- a/cpukit/score/include/rtems/score/watchdog.h +++ b/cpukit/score/include/rtems/score/watchdog.h @@ -116,24 +116,6 @@ EXTERN Chain_Control _Watchdog_Seconds_chain; void _Watchdog_Handler_initialization( void ); /* - * - * _Watchdog_Initialize - * - * DESCRIPTION: - * - * This routine initializes the specified watchdog. The watchdog is - * made inactive, the watchdog id and handler routine are set to the - * specified values. - */ - -STATIC INLINE void _Watchdog_Initialize( - Watchdog_Control *the_watchdog, - Watchdog_Service_routine_entry routine, - Objects_Id id, - void *user_data -); - -/* * _Watchdog_Remove * * DESCRIPTION: @@ -147,208 +129,6 @@ Watchdog_States _Watchdog_Remove ( ); /* - * - * _Watchdog_Is_active - * - * DESCRIPTION: - * - * This routine returns TRUE if the watchdog timer is in the ACTIVE - * state, and FALSE otherwise. - */ - -STATIC INLINE boolean _Watchdog_Is_active( - Watchdog_Control *the_watchdog -); - -/* - * - * _Watchdog_Activate - * - * DESCRIPTION: - * - * This routine activates THE_WATCHDOG timer which is already - * on a watchdog chain. - */ - -STATIC INLINE void _Watchdog_Activate( - Watchdog_Control *the_watchdog -); - -/* - * - * _Watchdog_Deactivate - * - * DESCRIPTION: - * - * This routine deactivates THE_WATCHDOG timer which will remain - * on a watchdog chain. - */ - -STATIC INLINE void _Watchdog_Deactivate( - Watchdog_Control *the_watchdog -); - -/* - * - * _Watchdog_Tickle_ticks - * - * DESCRIPTION: - * - * This routine is invoked at each clock tick to update the ticks - * watchdog chain. - */ - -STATIC INLINE void _Watchdog_Tickle_ticks( void ); - -/* - * - * _Watchdog_Tickle_seconds - * - * DESCRIPTION: - * - * This routine is invoked at each clock tick to update the seconds - * watchdog chain. - */ - -STATIC INLINE void _Watchdog_Tickle_seconds( void ); - -/* - * - * _Watchdog_Insert_ticks - * - * DESCRIPTION: - * - * This routine inserts THE_WATCHDOG into the ticks watchdog chain - * for a time of UNITS ticks. The INSERT_MODE indicates whether - * THE_WATCHDOG is to be activated automatically or later, explicitly - * by the caller. - */ - -STATIC INLINE void _Watchdog_Insert_ticks( - Watchdog_Control *the_watchdog, - Watchdog_Interval units -); - -/* - * - * _Watchdog_Insert_seconds - * - * DESCRIPTION: - * - * This routine inserts THE_WATCHDOG into the seconds watchdog chain - * for a time of UNITS seconds. The INSERT_MODE indicates whether - * THE_WATCHDOG is to be activated automatically or later, explicitly - * by the caller. - */ - -STATIC INLINE void _Watchdog_Insert_seconds( - Watchdog_Control *the_watchdog, - Watchdog_Interval units -); - -/* - * - * _Watchdog_Adjust_seconds - * - * DESCRIPTION: - * - * This routine adjusts the seconds watchdog chain in the forward - * or backward DIRECTION for UNITS seconds. This is invoked when the - * current time of day is changed. - */ - -STATIC INLINE void _Watchdog_Adjust_seconds( - Watchdog_Adjust_directions direction, - Watchdog_Interval units -); - -/* - * - * _Watchdog_Adjust_ticks - * - * DESCRIPTION: - * - * This routine adjusts the ticks watchdog chain in the forward - * or backward DIRECTION for UNITS ticks. - */ - -STATIC INLINE void _Watchdog_Adjust_ticks( - Watchdog_Adjust_directions direction, - Watchdog_Interval units -); - -/* - * - * _Watchdog_Reset - * - * DESCRIPTION: - * - * This routine resets THE_WATCHDOG timer to its state at INSERT - * time. This routine is valid only on interval watchdog timers - * and is used to make an interval watchdog timer fire "every" so - * many ticks. - */ - -STATIC INLINE void _Watchdog_Reset( - Watchdog_Control *the_watchdog -); - -/* - * - * _Watchdog_Next - * - * DESCRIPTION: - * - * This routine returns a pointer to the watchdog timer following - * THE_WATCHDOG on the watchdog chain. - */ - -STATIC INLINE Watchdog_Control *_Watchdog_Next( - Watchdog_Control *the_watchdog -); - -/* - * - * _Watchdog_Previous - * - * DESCRIPTION: - * - * This routine returns a pointer to the watchdog timer preceding - * THE_WATCHDOG on the watchdog chain. - */ - -STATIC INLINE Watchdog_Control *_Watchdog_Previous( - Watchdog_Control *the_watchdog -); - -/* - * - * _Watchdog_First - * - * DESCRIPTION: - * - * This routine returns a pointer to the first watchdog timer - * on the watchdog chain HEADER. - */ - -STATIC INLINE Watchdog_Control *_Watchdog_First( - Chain_Control *header -); - -/* - * - * _Watchdog_Last - * - * DESCRIPTION: - * - * This routine returns a pointer to the last watchdog timer - * on the watchdog chain HEADER. - */ -STATIC INLINE Watchdog_Control *_Watchdog_Last( - Chain_Control *header -); - -/* * _Watchdog_Adjust * * DESCRIPTION: @@ -393,7 +173,9 @@ void _Watchdog_Tickle ( Chain_Control *header ); +#ifndef __RTEMS_APPLICATION__ #include <rtems/score/watchdog.inl> +#endif #ifdef __cplusplus } diff --git a/cpukit/score/inline/rtems/score/address.inl b/cpukit/score/inline/rtems/score/address.inl index c1bb098577..343123c981 100644 --- a/cpukit/score/inline/rtems/score/address.inl +++ b/cpukit/score/inline/rtems/score/address.inl @@ -21,6 +21,11 @@ * * _Addresses_Add_offset * + * DESCRIPTION: + * + * This function is used to add an offset to a base address. + * It returns the resulting address. This address is typically + * converted to an access type before being used further. */ STATIC INLINE void *_Addresses_Add_offset ( @@ -35,6 +40,11 @@ STATIC INLINE void *_Addresses_Add_offset ( * * _Addresses_Subtract_offset * + * DESCRIPTION: + * + * This function is used to subtract an offset from a base + * address. It returns the resulting address. This address is + * typically converted to an access type before being used further. */ STATIC INLINE void *_Addresses_Subtract_offset ( @@ -49,6 +59,11 @@ STATIC INLINE void *_Addresses_Subtract_offset ( * * _Addresses_Subtract * + * DESCRIPTION: + * + * This function is used to subtract two addresses. It returns the + * resulting offset. + * * NOTE: The cast of an address to an unsigned32 makes this code * dependent on an addresses being thirty two bits. */ @@ -65,6 +80,11 @@ STATIC INLINE unsigned32 _Addresses_Subtract ( * * _Addresses_Is_aligned * + * DESCRIPTION: + * + * This function returns TRUE if the given address is correctly + * aligned for this processor and FALSE otherwise. Proper alignment + * is based on correctness and efficiency. */ STATIC INLINE boolean _Addresses_Is_aligned ( @@ -78,6 +98,13 @@ STATIC INLINE boolean _Addresses_Is_aligned ( * * _Addresses_Is_in_range * + * DESCRIPTION: + * + * This function returns TRUE if the given address is within the + * memory range specified and FALSE otherwise. base is the address + * of the first byte in the memory range and limit is the address + * of the last byte in the memory range. The base address is + * assumed to be lower than the limit address. */ STATIC INLINE boolean _Addresses_Is_in_range ( diff --git a/cpukit/score/inline/rtems/score/chain.inl b/cpukit/score/inline/rtems/score/chain.inl index 63706544e4..7fd3fef934 100644 --- a/cpukit/score/inline/rtems/score/chain.inl +++ b/cpukit/score/inline/rtems/score/chain.inl @@ -24,6 +24,11 @@ /*PAGE * * _Chain_Are_nodes_equal + * + * DESCRIPTION: + * + * This function returns TRUE if LEFT and RIGHT are equal, + * and FALSE otherwise. */ STATIC INLINE boolean _Chain_Are_nodes_equal( @@ -37,6 +42,10 @@ STATIC INLINE boolean _Chain_Are_nodes_equal( /*PAGE * * _Chain_Is_null + * + * DESCRIPTION: + * + * This function returns TRUE if the_chain is NULL and FALSE otherwise. */ STATIC INLINE boolean _Chain_Is_null( @@ -49,6 +58,10 @@ STATIC INLINE boolean _Chain_Is_null( /*PAGE * * _Chain_Is_null_node + * + * DESCRIPTION: + * + * This function returns TRUE if the_node is NULL and FALSE otherwise. */ STATIC INLINE boolean _Chain_Is_null_node( @@ -61,6 +74,10 @@ STATIC INLINE boolean _Chain_Is_null_node( /*PAGE * * _Chain_Head + * + * DESCRIPTION: + * + * This function returns a pointer to the first node on the chain. */ STATIC INLINE Chain_Node *_Chain_Head( @@ -73,6 +90,10 @@ STATIC INLINE Chain_Node *_Chain_Head( /*PAGE * * _Chain_Tail + * + * DESCRIPTION: + * + * This function returns a pointer to the last node on the chain. */ STATIC INLINE Chain_Node *_Chain_Tail( @@ -85,6 +106,11 @@ STATIC INLINE Chain_Node *_Chain_Tail( /*PAGE * * _Chain_Is_empty + * + * DESCRIPTION: + * + * This function returns TRUE if there a no nodes on the_chain and + * FALSE otherwise. */ STATIC INLINE boolean _Chain_Is_empty( @@ -97,6 +123,11 @@ STATIC INLINE boolean _Chain_Is_empty( /*PAGE * * _Chain_Is_first + * + * DESCRIPTION: + * + * This function returns TRUE if the_node is the first node on a chain and + * FALSE otherwise. */ STATIC INLINE boolean _Chain_Is_first( @@ -109,6 +140,11 @@ STATIC INLINE boolean _Chain_Is_first( /*PAGE * * _Chain_Is_last + * + * DESCRIPTION: + * + * This function returns TRUE if the_node is the last node on a chain and + * FALSE otherwise. */ STATIC INLINE boolean _Chain_Is_last( @@ -121,6 +157,11 @@ STATIC INLINE boolean _Chain_Is_last( /*PAGE * * _Chain_Has_only_one_node + * + * DESCRIPTION: + * + * This function returns TRUE if there is only one node on the_chain and + * FALSE otherwise. */ STATIC INLINE boolean _Chain_Has_only_one_node( @@ -133,6 +174,11 @@ STATIC INLINE boolean _Chain_Has_only_one_node( /*PAGE * * _Chain_Is_head + * + * DESCRIPTION: + * + * This function returns TRUE if the_node is the head of the_chain and + * FALSE otherwise. */ STATIC INLINE boolean _Chain_Is_head( @@ -146,6 +192,11 @@ STATIC INLINE boolean _Chain_Is_head( /*PAGE * * _Chain_Is_tail + * + * DESCRIPTION: + * + * This function returns TRUE if the_node is the tail of the_chain and + * FALSE otherwise. */ STATIC INLINE boolean _Chain_Is_tail( @@ -159,6 +210,10 @@ STATIC INLINE boolean _Chain_Is_tail( /*PAGE * * Chain_Initialize_empty + * + * DESCRIPTION: + * + * This routine initializes the specified chain to contain zero nodes. */ STATIC INLINE void _Chain_Initialize_empty( @@ -173,6 +228,12 @@ STATIC INLINE void _Chain_Initialize_empty( /*PAGE * * _Chain_Extract_unprotected + * + * DESCRIPTION: + * + * This routine extracts the_node from the chain on which it resides. + * It does NOT disable interrupts to insure the atomicity of the + * extract operation. */ STATIC INLINE void _Chain_Extract_unprotected( @@ -191,6 +252,12 @@ STATIC INLINE void _Chain_Extract_unprotected( /*PAGE * * _Chain_Get_first_unprotected + * + * DESCRIPTION: + * + * This function removes the first node from the_chain and returns + * a pointer to that node. It does NOT disable interrupts to insure + * the atomicity of the get operation. */ STATIC INLINE Chain_Node *_Chain_Get_first_unprotected( @@ -211,6 +278,13 @@ STATIC INLINE Chain_Node *_Chain_Get_first_unprotected( /*PAGE * * Chain_Get_unprotected + * + * DESCRIPTION: + * + * This function removes the first node from the_chain and returns + * a pointer to that node. If the_chain is empty, then NULL is returned. + * It does NOT disable interrupts to insure the atomicity of the + * get operation. */ STATIC INLINE Chain_Node *_Chain_Get_unprotected( @@ -226,6 +300,12 @@ STATIC INLINE Chain_Node *_Chain_Get_unprotected( /*PAGE * * _Chain_Insert_unprotected + * + * DESCRIPTION: + * + * This routine inserts the_node on a chain immediately following + * after_node. It does NOT disable interrupts to insure the atomicity + * of the extract operation. */ STATIC INLINE void _Chain_Insert_unprotected( @@ -245,6 +325,12 @@ STATIC INLINE void _Chain_Insert_unprotected( /*PAGE * * _Chain_Append_unprotected + * + * DESCRIPTION: + * + * This routine appends the_node onto the end of the_chain. + * It does NOT disable interrupts to insure the atomicity of the + * append operation. */ STATIC INLINE void _Chain_Append_unprotected( @@ -264,6 +350,12 @@ STATIC INLINE void _Chain_Append_unprotected( /*PAGE * * _Chain_Prepend_unprotected + * + * DESCRIPTION: + * + * This routine prepends the_node onto the front of the_chain. + * It does NOT disable interrupts to insure the atomicity of the + * prepend operation. */ STATIC INLINE void _Chain_Prepend_unprotected( @@ -278,6 +370,12 @@ STATIC INLINE void _Chain_Prepend_unprotected( /*PAGE * * _Chain_Prepend + * + * DESCRIPTION: + * + * This routine prepends the_node onto the front of the_chain. + * It disables interrupts to insure the atomicity of the + * prepend operation. */ STATIC INLINE void _Chain_Prepend( diff --git a/cpukit/score/inline/rtems/score/coremsg.inl b/cpukit/score/inline/rtems/score/coremsg.inl index 5a1b5d4a10..84e7250aa7 100644 --- a/cpukit/score/inline/rtems/score/coremsg.inl +++ b/cpukit/score/inline/rtems/score/coremsg.inl @@ -23,6 +23,9 @@ * * _CORE_message_queue_Send * + * DESCRIPTION: + * + * This routine sends a message to the end of the specified message queue. */ STATIC INLINE CORE_message_queue_Status _CORE_message_queue_Send( @@ -47,6 +50,9 @@ STATIC INLINE CORE_message_queue_Status _CORE_message_queue_Send( * * _CORE_message_queue_Urgent * + * DESCRIPTION: + * + * This routine sends a message to the front of the specified message queue. */ STATIC INLINE CORE_message_queue_Status _CORE_message_queue_Urgent( @@ -71,6 +77,10 @@ STATIC INLINE CORE_message_queue_Status _CORE_message_queue_Urgent( * * _CORE_message_queue_Copy_buffer * + * DESCRIPTION: + * + * This routine copies the contents of the source message buffer + * to the destination message buffer. */ STATIC INLINE void _CORE_message_queue_Copy_buffer ( @@ -86,6 +96,10 @@ STATIC INLINE void _CORE_message_queue_Copy_buffer ( * * _CORE_message_queue_Allocate_message_buffer * + * DESCRIPTION: + * + * This function allocates a message buffer from the inactive + * message buffer chain. */ STATIC INLINE CORE_message_queue_Buffer_control * @@ -101,6 +115,10 @@ _CORE_message_queue_Allocate_message_buffer ( * * _CORE_message_queue_Free_message_buffer * + * DESCRIPTION: + * + * This routine frees a message buffer to the inactive + * message buffer chain. */ STATIC INLINE void _CORE_message_queue_Free_message_buffer ( @@ -115,6 +133,10 @@ STATIC INLINE void _CORE_message_queue_Free_message_buffer ( * * _CORE_message_queue_Get_pending_message * + * DESCRIPTION: + * + * This function removes the first message from the_message_queue + * and returns a pointer to it. */ STATIC INLINE @@ -130,6 +152,10 @@ STATIC INLINE * * _CORE_message_queue_Is_priority * + * DESCRIPTION: + * + * This function returns TRUE if the priority attribute is + * enabled in the attribute_set and FALSE otherwise. */ STATIC INLINE boolean _CORE_message_queue_Is_priority( @@ -143,6 +169,10 @@ STATIC INLINE boolean _CORE_message_queue_Is_priority( * * _CORE_message_queue_Append * + * DESCRIPTION: + * + * This routine places the_message at the rear of the outstanding + * messages on the_message_queue. */ STATIC INLINE void _CORE_message_queue_Append ( @@ -157,6 +187,10 @@ STATIC INLINE void _CORE_message_queue_Append ( * * _CORE_message_queue_Prepend * + * DESCRIPTION: + * + * This routine places the_message at the front of the outstanding + * messages on the_message_queue. */ STATIC INLINE void _CORE_message_queue_Prepend ( @@ -174,6 +208,9 @@ STATIC INLINE void _CORE_message_queue_Prepend ( * * _CORE_message_queue_Is_null * + * DESCRIPTION: + * + * This function returns TRUE if the_message_queue is TRUE and FALSE otherwise. */ STATIC INLINE boolean _CORE_message_queue_Is_null ( @@ -187,6 +224,10 @@ STATIC INLINE boolean _CORE_message_queue_Is_null ( * * _CORE_message_queue_Is_notify_enabled * + * DESCRIPTION: + * + * This function returns TRUE if notification is enabled on this message + * queue and FALSE otherwise. */ STATIC INLINE boolean _CORE_message_queue_Is_notify_enabled ( @@ -200,6 +241,9 @@ STATIC INLINE boolean _CORE_message_queue_Is_notify_enabled ( * * _CORE_message_queue_Set_notify * + * DESCRIPTION: + * + * This routine initializes the notification information for the_message_queue. */ STATIC INLINE void _CORE_message_queue_Set_notify ( diff --git a/cpukit/score/inline/rtems/score/coremutex.inl b/cpukit/score/inline/rtems/score/coremutex.inl index 8681795085..537d6f7e5f 100644 --- a/cpukit/score/inline/rtems/score/coremutex.inl +++ b/cpukit/score/inline/rtems/score/coremutex.inl @@ -21,6 +21,10 @@ * * _CORE_mutex_Is_locked * + * DESCRIPTION: + * + * This routine returns TRUE if the mutex specified is locked and FALSE + * otherwise. */ STATIC INLINE boolean _CORE_mutex_Is_locked( @@ -34,6 +38,10 @@ STATIC INLINE boolean _CORE_mutex_Is_locked( * * _CORE_mutex_Is_fifo * + * DESCRIPTION: + * + * This routine returns TRUE if the mutex's wait discipline is FIFO and FALSE + * otherwise. */ STATIC INLINE boolean _CORE_mutex_Is_fifo( @@ -47,6 +55,10 @@ STATIC INLINE boolean _CORE_mutex_Is_fifo( * * _CORE_mutex_Is_priority * + * DESCRIPTION: + * + * This routine returns TRUE if the mutex's wait discipline is PRIORITY and + * FALSE otherwise. */ STATIC INLINE boolean _CORE_mutex_Is_priority( @@ -60,6 +72,10 @@ STATIC INLINE boolean _CORE_mutex_Is_priority( * * _CORE_mutex_Is_inherit_priority * + * DESCRIPTION: + * + * This routine returns TRUE if the mutex's wait discipline is + * INHERIT_PRIORITY and FALSE otherwise. */ STATIC INLINE boolean _CORE_mutex_Is_inherit_priority( @@ -73,6 +89,10 @@ STATIC INLINE boolean _CORE_mutex_Is_inherit_priority( * * _CORE_mutex_Is_priority_ceiling * + * DESCRIPTION: + * + * This routine returns TRUE if the mutex's wait discipline is + * PRIORITY_CEILING and FALSE otherwise. */ STATIC INLINE boolean _CORE_mutex_Is_priority_ceiling( diff --git a/cpukit/score/inline/rtems/score/coresem.inl b/cpukit/score/inline/rtems/score/coresem.inl index 53f7d68595..6f82318d10 100644 --- a/cpukit/score/inline/rtems/score/coresem.inl +++ b/cpukit/score/inline/rtems/score/coresem.inl @@ -21,6 +21,10 @@ * * _CORE_semaphore_Is_priority * + * DESCRIPTION: + * + * This function returns TRUE if the priority attribute is + * enabled in the attribute_set and FALSE otherwise. */ STATIC INLINE boolean _CORE_semaphore_Is_priority( @@ -34,6 +38,9 @@ STATIC INLINE boolean _CORE_semaphore_Is_priority( * * _CORE_semaphore_Get_count * + * DESCRIPTION: + * + * This routine returns the current count associated with the semaphore. */ STATIC INLINE unsigned32 _CORE_semaphore_Get_count( diff --git a/cpukit/score/inline/rtems/score/heap.inl b/cpukit/score/inline/rtems/score/heap.inl index 0d1b1231a7..6b4b1af74e 100644 --- a/cpukit/score/inline/rtems/score/heap.inl +++ b/cpukit/score/inline/rtems/score/heap.inl @@ -23,6 +23,9 @@ * * _Heap_Head * + * DESCRIPTION: + * + * This function returns the head of the specified heap. */ STATIC INLINE Heap_Block *_Heap_Head ( @@ -36,6 +39,9 @@ STATIC INLINE Heap_Block *_Heap_Head ( * * _Heap_Tail * + * DESCRIPTION: + * + * This function returns the tail of the specified heap. */ STATIC INLINE Heap_Block *_Heap_Tail ( @@ -49,6 +55,10 @@ STATIC INLINE Heap_Block *_Heap_Tail ( * * _Heap_Previous_block * + * DESCRIPTION: + * + * This function returns the address of the block which physically + * precedes the_block in memory. */ STATIC INLINE Heap_Block *_Heap_Previous_block ( @@ -65,6 +75,11 @@ STATIC INLINE Heap_Block *_Heap_Previous_block ( * * _Heap_Next_block * + * DESCRIPTION: + * + * This function returns the address of the block which physically + * follows the_block in memory. + * * NOTE: Next_block assumes that the block is free. */ @@ -82,6 +97,10 @@ STATIC INLINE Heap_Block *_Heap_Next_block ( * * _Heap_Block_at * + * DESCRIPTION: + * + * This function calculates and returns a block's location (address) + * in the heap based upad a base address and an offset. */ STATIC INLINE Heap_Block *_Heap_Block_at( @@ -96,6 +115,9 @@ STATIC INLINE Heap_Block *_Heap_Block_at( * * _Heap_User_block_at * + * DESCRIPTION: + * + * XXX */ STATIC INLINE Heap_Block *_Heap_User_block_at( @@ -112,6 +134,10 @@ STATIC INLINE Heap_Block *_Heap_User_block_at( * * _Heap_Is_previous_block_free * + * DESCRIPTION: + * + * This function returns TRUE if the previous block of the_block + * is free, and FALSE otherwise. */ STATIC INLINE boolean _Heap_Is_previous_block_free ( @@ -125,6 +151,9 @@ STATIC INLINE boolean _Heap_Is_previous_block_free ( * * _Heap_Is_block_free * + * DESCRIPTION: + * + * This function returns TRUE if the block is free, and FALSE otherwise. */ STATIC INLINE boolean _Heap_Is_block_free ( @@ -138,6 +167,10 @@ STATIC INLINE boolean _Heap_Is_block_free ( * * _Heap_Is_block_used * + * DESCRIPTION: + * + * This function returns TRUE if the block is currently allocated, + * and FALSE otherwise. */ STATIC INLINE boolean _Heap_Is_block_used ( @@ -151,6 +184,9 @@ STATIC INLINE boolean _Heap_Is_block_used ( * * _Heap_Block_size * + * DESCRIPTION: + * + * This function returns the size of the_block in bytes. */ STATIC INLINE unsigned32 _Heap_Block_size ( @@ -164,6 +200,10 @@ STATIC INLINE unsigned32 _Heap_Block_size ( * * _Heap_Start_of_user_area * + * DESCRIPTION: + * + * This function returns the starting address of the portion of the block + * which the user may access. */ STATIC INLINE void *_Heap_Start_of_user_area ( @@ -177,6 +217,10 @@ STATIC INLINE void *_Heap_Start_of_user_area ( * * _Heap_Is_block_in * + * DESCRIPTION: + * + * This function returns TRUE if the_block is within the memory area + * managed by the_heap, and FALSE otherwise. */ STATIC INLINE boolean _Heap_Is_block_in ( @@ -191,6 +235,12 @@ STATIC INLINE boolean _Heap_Is_block_in ( * * _Heap_Is_page_size_valid * + * DESCRIPTION: + * + * This function validates a specified heap page size. If the page size + * is 0 or if lies outside a page size alignment boundary it is invalid + * and FALSE is returned. Otherwise, the page size is valid and TRUE is + * returned. */ STATIC INLINE boolean _Heap_Is_page_size_valid( @@ -205,6 +255,11 @@ STATIC INLINE boolean _Heap_Is_page_size_valid( * * _Heap_Build_flag * + * DESCRIPTION: + * + * This function returns the block flag composed of size and in_use_flag. + * The flag returned is suitable for use as a back or front flag in a + * heap block. */ STATIC INLINE unsigned32 _Heap_Build_flag ( diff --git a/cpukit/score/inline/rtems/score/isr.inl b/cpukit/score/inline/rtems/score/isr.inl index 2b4969a5db..2dd41315bc 100644 --- a/cpukit/score/inline/rtems/score/isr.inl +++ b/cpukit/score/inline/rtems/score/isr.inl @@ -21,6 +21,12 @@ * * _ISR_Is_in_progress * + * DESCRIPTION: + * + * This function returns TRUE if the processor is currently servicing + * and interrupt and FALSE otherwise. A return value of TRUE indicates + * that the caller is an interrupt service routine, NOT a thread. The + * directives available to an interrupt service routine are restricted. */ STATIC INLINE boolean _ISR_Is_in_progress( void ) @@ -32,6 +38,10 @@ STATIC INLINE boolean _ISR_Is_in_progress( void ) * * _ISR_Is_vector_number_valid * + * DESCRIPTION: + * + * This function returns TRUE if the vector is a valid vector number + * for this processor and FALSE otherwise. */ STATIC INLINE boolean _ISR_Is_vector_number_valid ( @@ -45,6 +55,11 @@ STATIC INLINE boolean _ISR_Is_vector_number_valid ( * * _ISR_Is_valid_user_handler * + * + * DESCRIPTION: + * + * This function returns TRUE if handler is the entry point of a valid + * use interrupt service routine and FALSE otherwise. */ STATIC INLINE boolean _ISR_Is_valid_user_handler ( diff --git a/cpukit/score/inline/rtems/score/mppkt.inl b/cpukit/score/inline/rtems/score/mppkt.inl index c23d756ec9..c8b6ecd117 100644 --- a/cpukit/score/inline/rtems/score/mppkt.inl +++ b/cpukit/score/inline/rtems/score/mppkt.inl @@ -21,6 +21,11 @@ * * _Mp_packet_Is_valid_packet_class * + * DESCRIPTION: + * + * This function returns TRUE if the the_packet_class is valid, + * and FALSE otherwise. + * * NOTE: Check for lower bounds (MP_PACKET_CLASSES_FIRST ) is unnecessary * because this enum starts at lower bound of zero. */ @@ -36,6 +41,10 @@ STATIC INLINE boolean _Mp_packet_Is_valid_packet_class ( * * _Mp_packet_Is_null * + * DESCRIPTION: + * + * This function returns TRUE if the the_packet_class is null, + * and FALSE otherwise. */ STATIC INLINE boolean _Mp_packet_Is_null ( diff --git a/cpukit/score/inline/rtems/score/object.inl b/cpukit/score/inline/rtems/score/object.inl index eb07a24890..249814bacf 100644 --- a/cpukit/score/inline/rtems/score/object.inl +++ b/cpukit/score/inline/rtems/score/object.inl @@ -21,6 +21,10 @@ * * _Objects_Build_id * + * DESCRIPTION: + * + * This function builds an object's id from the processor node and index + * values specified. */ STATIC INLINE Objects_Id _Objects_Build_id( @@ -37,6 +41,10 @@ STATIC INLINE Objects_Id _Objects_Build_id( /*PAGE * * _Objects_Get_class + * + * DESCRIPTION: + * + * This function returns the class portion of the ID. */ STATIC INLINE Objects_Classes _Objects_Get_class( @@ -52,6 +60,9 @@ STATIC INLINE Objects_Classes _Objects_Get_class( * * _Objects_Get_node * + * DESCRIPTION: + * + * This function returns the node portion of the ID. */ STATIC INLINE unsigned32 _Objects_Get_node( @@ -65,6 +76,9 @@ STATIC INLINE unsigned32 _Objects_Get_node( * * _Objects_Get_index * + * DESCRIPTION: + * + * This function returns the index portion of the ID. */ STATIC INLINE unsigned32 _Objects_Get_index( @@ -78,6 +92,9 @@ STATIC INLINE unsigned32 _Objects_Get_index( * * _Objects_Is_class_valid * + * DESCRIPTION: + * + * This function returns TRUE if the class is valid. */ STATIC INLINE boolean _Objects_Is_class_valid( @@ -91,6 +108,10 @@ STATIC INLINE boolean _Objects_Is_class_valid( * * _Objects_Is_local_node * + * DESCRIPTION: + * + * This function returns TRUE if the node is of the local object, and + * FALSE otherwise. */ STATIC INLINE boolean _Objects_Is_local_node( @@ -104,6 +125,10 @@ STATIC INLINE boolean _Objects_Is_local_node( * * _Objects_Is_local_id * + * DESCRIPTION: + * + * This function returns TRUE if the id is of a local object, and + * FALSE otherwise. */ STATIC INLINE boolean _Objects_Is_local_id( @@ -117,6 +142,10 @@ STATIC INLINE boolean _Objects_Is_local_id( * * _Objects_Are_ids_equal * + * DESCRIPTION: + * + * This function returns TRUE if left and right are equal, + * and FALSE otherwise. */ STATIC INLINE boolean _Objects_Are_ids_equal( @@ -131,6 +160,10 @@ STATIC INLINE boolean _Objects_Are_ids_equal( * * _Objects_Allocate * + * DESCRIPTION: + * + * This function allocates a object control block from + * the inactive chain of free object control blocks. */ STATIC INLINE Objects_Control *_Objects_Allocate( @@ -144,6 +177,10 @@ STATIC INLINE Objects_Control *_Objects_Allocate( * * _Objects_Free * + * DESCRIPTION: + * + * This function frees a object control block to the + * inactive chain of free object control blocks. */ STATIC INLINE void _Objects_Free( @@ -158,6 +195,10 @@ STATIC INLINE void _Objects_Free( * * _Objects_Open * + * DESCRIPTION: + * + * This function places the_object control pointer and object name + * in the Local Pointer and Local Name Tables, respectively. */ STATIC INLINE void _Objects_Open( @@ -181,6 +222,10 @@ STATIC INLINE void _Objects_Open( * * _Objects_Close * + * DESCRIPTION: + * + * This function removes the_object control pointer and object name + * in the Local Pointer and Local Name Tables. */ STATIC INLINE void _Objects_Close( diff --git a/cpukit/score/inline/rtems/score/objectmp.inl b/cpukit/score/inline/rtems/score/objectmp.inl index e09a3df528..dda2799643 100644 --- a/cpukit/score/inline/rtems/score/objectmp.inl +++ b/cpukit/score/inline/rtems/score/objectmp.inl @@ -21,6 +21,9 @@ * * _Objects_MP_Allocate_global_object * + * DESCRIPTION: + * + * This function allocates a Global Object control block. */ STATIC INLINE Objects_MP_Control *_Objects_MP_Allocate_global_object ( @@ -32,8 +35,12 @@ STATIC INLINE Objects_MP_Control *_Objects_MP_Allocate_global_object ( } /*PAGE + * * _Objects_MP_Free_global_object * + * DESCRIPTION: + * + * This routine deallocates a Global Object control block. */ STATIC INLINE void _Objects_MP_Free_global_object ( @@ -47,8 +54,12 @@ STATIC INLINE void _Objects_MP_Free_global_object ( } /*PAGE + * * _Objects_MP_Is_null_global_object * + * DESCRIPTION: + * + * This function returns whether the global object is NULL or not. */ STATIC INLINE boolean _Objects_MP_Is_null_global_object ( diff --git a/cpukit/score/inline/rtems/score/priority.inl b/cpukit/score/inline/rtems/score/priority.inl index 413e3b6724..d65056057b 100644 --- a/cpukit/score/inline/rtems/score/priority.inl +++ b/cpukit/score/inline/rtems/score/priority.inl @@ -23,6 +23,9 @@ * * _Priority_Handler_initialization * + * DESCRIPTION: + * + * This routine performs the initialization necessary for this handler. */ STATIC INLINE void _Priority_Handler_initialization( void ) @@ -38,6 +41,10 @@ STATIC INLINE void _Priority_Handler_initialization( void ) * * _Priority_Is_valid * + * DESCRIPTION: + * + * This function returns TRUE if the_priority if valid for a + * user task, and FALSE otherwise. */ STATIC INLINE boolean _Priority_Is_valid ( @@ -56,6 +63,9 @@ STATIC INLINE boolean _Priority_Is_valid ( * * _Priority_Major * + * DESCRIPTION: + * + * This function returns the major portion of the_priority. */ STATIC INLINE unsigned32 _Priority_Major ( @@ -69,6 +79,9 @@ STATIC INLINE unsigned32 _Priority_Major ( * * _Priority_Minor * + * DESCRIPTION: + * + * This function returns the minor portion of the_priority. */ STATIC INLINE unsigned32 _Priority_Minor ( @@ -84,6 +97,10 @@ STATIC INLINE unsigned32 _Priority_Minor ( * * _Priority_Mask * + * DESCRIPTION: + * + * This function returns the mask associated with the major or minor + * number passed to it. */ STATIC INLINE unsigned32 _Priority_Mask ( @@ -98,6 +115,11 @@ STATIC INLINE unsigned32 _Priority_Mask ( * * _Priority_Bits_index * + * DESCRIPTION: + * + * This function translates the bit numbers returned by the bit scan + * of a priority bit field into something suitable for use as + * a major or minor component of a priority. */ STATIC INLINE unsigned32 _Priority_Bits_index ( @@ -113,6 +135,10 @@ STATIC INLINE unsigned32 _Priority_Bits_index ( * * _Priority_Add_to_bit_map * + * DESCRIPTION: + * + * This routine uses the_priority_map to update the priority + * bit maps to indicate that a thread has been readied. */ STATIC INLINE void _Priority_Add_to_bit_map ( @@ -127,6 +153,11 @@ STATIC INLINE void _Priority_Add_to_bit_map ( * * _Priority_Remove_from_bit_map * + * DESCRIPTION: + * + * This routine uses the_priority_map to update the priority + * bit maps to indicate that a thread has been removed from the + * ready state. */ STATIC INLINE void _Priority_Remove_from_bit_map ( @@ -142,6 +173,10 @@ STATIC INLINE void _Priority_Remove_from_bit_map ( * * _Priority_Get_highest * + * DESCRIPTION: + * + * This function returns the priority of the highest priority + * ready thread. */ STATIC INLINE Priority_Control _Priority_Get_highest( void ) @@ -160,6 +195,11 @@ STATIC INLINE Priority_Control _Priority_Get_highest( void ) * * _Priority_Initialize_information * + * DESCRIPTION: + * + * This routine initializes the_priority_map so that it + * contains the information necessary to manage a thread + * at new_priority. */ STATIC INLINE void _Priority_Initialize_information( @@ -190,6 +230,10 @@ STATIC INLINE void _Priority_Initialize_information( * * _Priority_Is_group_empty * + * DESCRIPTION: + * + * This function returns TRUE if the priority GROUP is empty, and + * FALSE otherwise. */ STATIC INLINE boolean _Priority_Is_group_empty ( diff --git a/cpukit/score/inline/rtems/score/stack.inl b/cpukit/score/inline/rtems/score/stack.inl index 7c6acf7cb3..d29874a7dd 100644 --- a/cpukit/score/inline/rtems/score/stack.inl +++ b/cpukit/score/inline/rtems/score/stack.inl @@ -21,6 +21,11 @@ * * _Stack_Initialize * + * DESCRIPTION: + * + * This routine initializes the_stack record to indicate that + * size bytes of memory starting at starting_address have been + * reserved for a stack. */ STATIC INLINE void _Stack_Initialize ( @@ -37,6 +42,10 @@ STATIC INLINE void _Stack_Initialize ( * * _Stack_Is_enough * + * DESCRIPTION: + * + * This function returns TRUE if size bytes is enough memory for + * a valid stack area on this processor, and FALSE otherwise. */ STATIC INLINE boolean _Stack_Is_enough ( @@ -50,6 +59,15 @@ STATIC INLINE boolean _Stack_Is_enough ( * * _Stack_Adjust_size * + * DESCRIPTION: + * + * This function increases the stack size to insure that the thread + * has the desired amount of stack space after the initial stack + * pointer is determined based on alignment restrictions. + * + * NOTE: + * + * The amount of adjustment for alignment is CPU dependent. */ STATIC INLINE unsigned32 _Stack_Adjust_size ( diff --git a/cpukit/score/inline/rtems/score/states.inl b/cpukit/score/inline/rtems/score/states.inl index 23ee8cacbc..fad8ce727c 100644 --- a/cpukit/score/inline/rtems/score/states.inl +++ b/cpukit/score/inline/rtems/score/states.inl @@ -21,6 +21,10 @@ * * _States_Set * + * DESCRIPTION: + * + * This function sets the given states_to_set into the current_state + * passed in. The result is returned to the user in current_state. */ STATIC INLINE States_Control _States_Set ( @@ -35,6 +39,10 @@ STATIC INLINE States_Control _States_Set ( * * _States_Clear * + * DESCRIPTION: + * + * This function clears the given states_to_clear into the current_state + * passed in. The result is returned to the user in current_state. */ STATIC INLINE States_Control _States_Clear ( @@ -49,6 +57,10 @@ STATIC INLINE States_Control _States_Clear ( * * _States_Is_ready * + * DESCRIPTION: + * + * This function returns TRUE if the_states indicates that the + * state is READY, and FALSE otherwise. */ STATIC INLINE boolean _States_Is_ready ( @@ -62,6 +74,10 @@ STATIC INLINE boolean _States_Is_ready ( * * _States_Is_only_dormant * + * DESCRIPTION: + * + * This function returns TRUE if the DORMANT state is the ONLY state + * set in the_states, and FALSE otherwise. */ STATIC INLINE boolean _States_Is_only_dormant ( @@ -75,6 +91,10 @@ STATIC INLINE boolean _States_Is_only_dormant ( * * _States_Is_dormant * + * DESCRIPTION: + * + * This function returns TRUE if the DORMANT state is set in + * the_states, and FALSE otherwise. */ STATIC INLINE boolean _States_Is_dormant ( @@ -88,6 +108,10 @@ STATIC INLINE boolean _States_Is_dormant ( * * _States_Is_suspended * + * DESCRIPTION: + * + * This function returns TRUE if the SUSPENDED state is set in + * the_states, and FALSE otherwise. */ STATIC INLINE boolean _States_Is_suspended ( @@ -101,6 +125,10 @@ STATIC INLINE boolean _States_Is_suspended ( * * _States_Is_Transient * + * DESCRIPTION: + * + * This function returns TRUE if the TRANSIENT state is set in + * the_states, and FALSE otherwise. */ STATIC INLINE boolean _States_Is_transient ( @@ -114,6 +142,10 @@ STATIC INLINE boolean _States_Is_transient ( * * _States_Is_delaying * + * DESCRIPTION: + * + * This function returns TRUE if the DELAYING state is set in + * the_states, and FALSE otherwise. */ STATIC INLINE boolean _States_Is_delaying ( @@ -127,6 +159,10 @@ STATIC INLINE boolean _States_Is_delaying ( * * _States_Is_waiting_for_buffer * + * DESCRIPTION: + * + * This function returns TRUE if the WAITING_FOR_BUFFER state is set in + * the_states, and FALSE otherwise. */ STATIC INLINE boolean _States_Is_waiting_for_buffer ( @@ -140,6 +176,10 @@ STATIC INLINE boolean _States_Is_waiting_for_buffer ( * * _States_Is_waiting_for_segment * + * DESCRIPTION: + * + * This function returns TRUE if the WAITING_FOR_SEGMENT state is set in + * the_states, and FALSE otherwise. */ STATIC INLINE boolean _States_Is_waiting_for_segment ( @@ -153,6 +193,10 @@ STATIC INLINE boolean _States_Is_waiting_for_segment ( * * _States_Is_waiting_for_message * + * DESCRIPTION: + * + * This function returns TRUE if the WAITING_FOR_MESSAGE state is set in + * the_states, and FALSE otherwise. */ STATIC INLINE boolean _States_Is_waiting_for_message ( @@ -166,6 +210,10 @@ STATIC INLINE boolean _States_Is_waiting_for_message ( * * _States_Is_waiting_for_event * + * DESCRIPTION: + * + * This function returns TRUE if the WAITING_FOR_EVENT state is set in + * the_states, and FALSE otherwise. */ STATIC INLINE boolean _States_Is_waiting_for_event ( @@ -179,6 +227,10 @@ STATIC INLINE boolean _States_Is_waiting_for_event ( * * _States_Is_waiting_for_mutex * + * DESCRIPTION: + * + * This function returns TRUE if the WAITING_FOR_MUTEX state + * is set in the_states, and FALSE otherwise. */ STATIC INLINE boolean _States_Is_waiting_for_mutex ( @@ -192,6 +244,10 @@ STATIC INLINE boolean _States_Is_waiting_for_mutex ( * * _States_Is_waiting_for_semaphore * + * DESCRIPTION: + * + * This function returns TRUE if the WAITING_FOR_SEMAPHORE state + * is set in the_states, and FALSE otherwise. */ STATIC INLINE boolean _States_Is_waiting_for_semaphore ( @@ -205,6 +261,10 @@ STATIC INLINE boolean _States_Is_waiting_for_semaphore ( * * _States_Is_waiting_for_time * + * DESCRIPTION: + * + * This function returns TRUE if the WAITING_FOR_TIME state is set in + * the_states, and FALSE otherwise. */ STATIC INLINE boolean _States_Is_waiting_for_time ( @@ -218,6 +278,10 @@ STATIC INLINE boolean _States_Is_waiting_for_time ( * * _States_Is_waiting_for_rpc_reply * + * DESCRIPTION: + * + * This function returns TRUE if the WAITING_FOR_TIME state is set in + * the_states, and FALSE otherwise. */ STATIC INLINE boolean _States_Is_waiting_for_rpc_reply ( @@ -231,6 +295,10 @@ STATIC INLINE boolean _States_Is_waiting_for_rpc_reply ( * * _States_Is_waiting_for_period * + * DESCRIPTION: + * + * This function returns TRUE if the WAITING_FOR_PERIOD state is set in + * the_states, and FALSE otherwise. */ STATIC INLINE boolean _States_Is_waiting_for_period ( @@ -244,6 +312,11 @@ STATIC INLINE boolean _States_Is_waiting_for_period ( * * _States_Is_locally_blocked * + * DESCRIPTION: + * + * This function returns TRUE if one of the states which indicates + * that a task is blocked waiting for a local resource is set in + * the_states, and FALSE otherwise. */ STATIC INLINE boolean _States_Is_locally_blocked ( @@ -257,6 +330,11 @@ STATIC INLINE boolean _States_Is_locally_blocked ( * * _States_Is_waiting_on_thread_queue * + * DESCRIPTION: + * + * This function returns TRUE if one of the states which indicates + * that a task is blocked waiting for a local resource is set in + * the_states, and FALSE otherwise. */ STATIC INLINE boolean _States_Is_waiting_on_thread_queue ( @@ -270,6 +348,10 @@ STATIC INLINE boolean _States_Is_waiting_on_thread_queue ( * * _States_Is_blocked * + * DESCRIPTION: + * + * This function returns TRUE if one of the states which indicates + * that a task is blocked is set in the_states, and FALSE otherwise. */ STATIC INLINE boolean _States_Is_blocked ( @@ -279,11 +361,15 @@ STATIC INLINE boolean _States_Is_blocked ( return (the_states & STATES_BLOCKED); } -/*PAGEPAGE +/*PAGE * * * _States_Are_set * + * DESCRIPTION: + * + * This function returns TRUE if any of the states in the mask + * are set in the_states, and FALSE otherwise. */ STATIC INLINE boolean _States_Are_set ( diff --git a/cpukit/score/inline/rtems/score/sysstate.inl b/cpukit/score/inline/rtems/score/sysstate.inl index 180e6abe54..08f8b9c513 100644 --- a/cpukit/score/inline/rtems/score/sysstate.inl +++ b/cpukit/score/inline/rtems/score/sysstate.inl @@ -20,6 +20,10 @@ /*PAGE * * _System_state_Handler_initialization + * + * DESCRIPTION: + * + * This routine initializes the system state handler. */ STATIC INLINE void _System_state_Handler_initialization ( @@ -33,6 +37,11 @@ STATIC INLINE void _System_state_Handler_initialization ( /*PAGE * * _System_state_Set + * + * DESCRIPTION: + * + * This routine sets the current system state to that specified by + * the called. */ STATIC INLINE void _System_state_Set ( @@ -45,6 +54,10 @@ STATIC INLINE void _System_state_Set ( /*PAGE * * _System_state_Get + * + * DESCRIPTION: + * + * This function returns the current system state. */ STATIC INLINE System_state_Codes _System_state_Get ( void ) @@ -55,6 +68,11 @@ STATIC INLINE System_state_Codes _System_state_Get ( void ) /*PAGE * * _System_state_Is_before_initialization + * + * DESCRIPTION: + * + * This function returns TRUE if the state is equal to the + * "before initialization" state, and FALSE otherwise. */ STATIC INLINE boolean _System_state_Is_before_initialization ( @@ -67,6 +85,11 @@ STATIC INLINE boolean _System_state_Is_before_initialization ( /*PAGE * * _System_state_Is_before_multitasking + * + * DESCRIPTION: + * + * This function returns TRUE if the state is equal to the + * "before multitasking" state, and FALSE otherwise. */ STATIC INLINE boolean _System_state_Is_before_multitasking ( @@ -79,6 +102,11 @@ STATIC INLINE boolean _System_state_Is_before_multitasking ( /*PAGE * * _System_state_Is_begin_multitasking + * + * DESCRIPTION: + * + * This function returns TRUE if the state is equal to the + * "begin multitasking" state, and FALSE otherwise. */ STATIC INLINE boolean _System_state_Is_begin_multitasking ( @@ -91,6 +119,11 @@ STATIC INLINE boolean _System_state_Is_begin_multitasking ( /*PAGE * * _System_state_Is_up + * + * DESCRIPTION: + * + * This function returns TRUE if the state is equal to the + * "up" state, and FALSE otherwise. */ STATIC INLINE boolean _System_state_Is_up ( @@ -103,6 +136,11 @@ STATIC INLINE boolean _System_state_Is_up ( /*PAGE * * _System_state_Is_failed + * + * DESCRIPTION: + * + * This function returns TRUE if the state is equal to the + * "failed" state, and FALSE otherwise. */ STATIC INLINE boolean _System_state_Is_failed ( diff --git a/cpukit/score/inline/rtems/score/thread.inl b/cpukit/score/inline/rtems/score/thread.inl index 265f51a8d0..53d5d41751 100644 --- a/cpukit/score/inline/rtems/score/thread.inl +++ b/cpukit/score/inline/rtems/score/thread.inl @@ -21,6 +21,11 @@ * * _Thread_Stop_multitasking * + * DESCRIPTION: + * + * This routine halts multitasking and returns control to + * the "thread" (i.e. the BSP) which initially invoked the + * routine which initialized the system. */ STATIC INLINE void _Thread_Stop_multitasking( void ) @@ -32,6 +37,10 @@ STATIC INLINE void _Thread_Stop_multitasking( void ) * * _Thread_Is_executing * + * DESCRIPTION: + * + * This function returns TRUE if the_thread is the currently executing + * thread, and FALSE otherwise. */ STATIC INLINE boolean _Thread_Is_executing ( @@ -45,6 +54,10 @@ STATIC INLINE boolean _Thread_Is_executing ( * * _Thread_Is_heir * + * DESCRIPTION: + * + * This function returns TRUE if the_thread is the heir + * thread, and FALSE otherwise. */ STATIC INLINE boolean _Thread_Is_heir ( @@ -58,6 +71,10 @@ STATIC INLINE boolean _Thread_Is_heir ( * * _Thread_Is_executing_also_the_heir * + * DESCRIPTION: + * + * This function returns TRUE if the currently executing thread + * is also the heir thread, and FALSE otherwise. */ STATIC INLINE boolean _Thread_Is_executing_also_the_heir( void ) @@ -69,6 +86,11 @@ STATIC INLINE boolean _Thread_Is_executing_also_the_heir( void ) * * _Thread_Resume * + * DESCRIPTION: + * + * This routine clears the SUSPENDED state for the_thread. It performs + * any necessary scheduling operations including the selection of + * a new heir thread. */ STATIC INLINE void _Thread_Resume ( @@ -82,6 +104,11 @@ STATIC INLINE void _Thread_Resume ( * * _Thread_Unblock * + * DESCRIPTION: + * + * This routine clears any blocking state for the_thread. It performs + * any necessary scheduling operations including the selection of + * a new heir thread. */ STATIC INLINE void _Thread_Unblock ( @@ -95,6 +122,10 @@ STATIC INLINE void _Thread_Unblock ( * * _Thread_Restart_self * + * DESCRIPTION: + * + * This routine resets the current context of the calling thread + * to that of its initial state. */ STATIC INLINE void _Thread_Restart_self( void ) @@ -109,6 +140,10 @@ STATIC INLINE void _Thread_Restart_self( void ) * * _Thread_Calculate_heir * + * DESCRIPTION: + * + * This function returns a pointer to the highest priority + * ready thread. */ STATIC INLINE void _Thread_Calculate_heir( void ) @@ -121,6 +156,11 @@ STATIC INLINE void _Thread_Calculate_heir( void ) * * _Thread_Is_allocated_fp * + * DESCRIPTION: + * + * This function returns TRUE if the floating point context of + * the_thread is currently loaded in the floating point unit, and + * FALSE otherwise. */ STATIC INLINE boolean _Thread_Is_allocated_fp ( @@ -134,6 +174,10 @@ STATIC INLINE boolean _Thread_Is_allocated_fp ( * * _Thread_Deallocate_fp * + * DESCRIPTION: + * + * This routine is invoked when the currently loaded floating + * point context is now longer associated with an active thread. */ STATIC INLINE void _Thread_Deallocate_fp( void ) @@ -145,6 +189,9 @@ STATIC INLINE void _Thread_Deallocate_fp( void ) * * _Thread_Disable_dispatch * + * DESCRIPTION: + * + * This routine prevents dispatching. */ STATIC INLINE void _Thread_Disable_dispatch( void ) @@ -156,6 +203,12 @@ STATIC INLINE void _Thread_Disable_dispatch( void ) * * _Thread_Enable_dispatch * + * DESCRIPTION: + * + * This routine allows dispatching to occur again. If this is + * the outer most dispatching critical section, then a dispatching + * operation will be performed and, if necessary, control of the + * processor will be transferred to the heir thread. */ #if ( CPU_INLINE_ENABLE_DISPATCH == TRUE ) @@ -174,6 +227,11 @@ void _Thread_Enable_dispatch( void ); * * _Thread_Unnest_dispatch * + * DESCRIPTION: + * + * This routine allows dispatching to occur again. However, + * no dispatching operation is performed even if this is the outer + * most dispatching critical section. */ STATIC INLINE void _Thread_Unnest_dispatch( void ) @@ -185,6 +243,10 @@ STATIC INLINE void _Thread_Unnest_dispatch( void ) * * _Thread_Is_dispatching_enabled * + * DESCRIPTION: + * + * This function returns TRUE if dispatching is disabled, and FALSE + * otherwise. */ STATIC INLINE boolean _Thread_Is_dispatching_enabled( void ) @@ -196,6 +258,10 @@ STATIC INLINE boolean _Thread_Is_dispatching_enabled( void ) * * _Thread_Is_context_switch_necessary * + * DESCRIPTION: + * + * This function returns TRUE if dispatching is disabled, and FALSE + * otherwise. */ STATIC INLINE boolean _Thread_Is_context_switch_necessary( void ) @@ -207,6 +273,9 @@ STATIC INLINE boolean _Thread_Is_context_switch_necessary( void ) * * _Thread_Dispatch_initialization * + * DESCRIPTION: + * + * This routine initializes the thread dispatching subsystem. */ STATIC INLINE void _Thread_Dispatch_initialization( void ) @@ -218,6 +287,9 @@ STATIC INLINE void _Thread_Dispatch_initialization( void ) * * _Thread_Is_null * + * DESCRIPTION: + * + * This function returns TRUE if the_thread is NULL and FALSE otherwise. */ STATIC INLINE boolean _Thread_Is_null ( @@ -231,6 +303,17 @@ STATIC INLINE boolean _Thread_Is_null ( * * _Thread_Get * + * DESCRIPTION: + * + * This function maps thread IDs to thread control + * blocks. If ID corresponds to a local thread, then it + * returns the_thread control pointer which maps to ID + * and location is set to OBJECTS_LOCAL. If the thread ID is + * global and resides on a remote node, then location is set + * to OBJECTS_REMOTE, and the_thread is undefined. + * Otherwise, location is set to OBJECTS_ERROR and + * the_thread is undefined. + * * NOTE: XXX... This routine may be able to be optimized. */ @@ -274,6 +357,10 @@ done: /* * _Thread_Is_proxy_blocking * + * DESCRIPTION: + * + * This function returns TRUE if the status code is equal to the + * status which indicates that a proxy is blocking, and FALSE otherwise. */ STATIC INLINE boolean _Thread_Is_proxy_blocking ( @@ -287,6 +374,9 @@ STATIC INLINE boolean _Thread_Is_proxy_blocking ( * * _Thread_Internal_allocate * + * DESCRIPTION: + * + * This routine allocates an internal thread. */ STATIC INLINE Thread_Control *_Thread_Internal_allocate( void ) @@ -298,6 +388,9 @@ STATIC INLINE Thread_Control *_Thread_Internal_allocate( void ) * * _Thread_Internal_free * + * DESCRIPTION: + * + * This routine frees an internal thread. */ STATIC INLINE void _Thread_Internal_free ( diff --git a/cpukit/score/inline/rtems/score/threadmp.inl b/cpukit/score/inline/rtems/score/threadmp.inl index f4beba59ed..f16f64e48a 100644 --- a/cpukit/score/inline/rtems/score/threadmp.inl +++ b/cpukit/score/inline/rtems/score/threadmp.inl @@ -21,6 +21,10 @@ * * _Thread_MP_Is_receive * + * DESCRIPTION: + * + * This function returns true if the thread in question is the + * multiprocessing receive thread. */ STATIC INLINE boolean _Thread_MP_Is_receive ( @@ -34,6 +38,10 @@ STATIC INLINE boolean _Thread_MP_Is_receive ( * * _Thread_MP_Free_proxy * + * DESCRIPTION: + * + * This routine frees a proxy control block to the + * inactive chain of free proxy control blocks. */ STATIC INLINE void _Thread_MP_Free_proxy ( diff --git a/cpukit/score/inline/rtems/score/tod.inl b/cpukit/score/inline/rtems/score/tod.inl index dce8aca426..5ed1e76d8f 100644 --- a/cpukit/score/inline/rtems/score/tod.inl +++ b/cpukit/score/inline/rtems/score/tod.inl @@ -21,6 +21,10 @@ * * _TOD_Is_set * + * DESCRIPTION: + * + * This function returns TRUE if the application has set the current + * time of day, and FALSE otherwise. */ STATIC INLINE boolean _TOD_Is_set( void ) @@ -32,6 +36,10 @@ STATIC INLINE boolean _TOD_Is_set( void ) * * _TOD_Tickle_ticks * + * DESCRIPTION: + * + * This routine increments the ticks field of the current time of + * day at each clock tick. */ STATIC INLINE void _TOD_Tickle_ticks( void ) @@ -44,6 +52,9 @@ STATIC INLINE void _TOD_Tickle_ticks( void ) * * _TOD_Deactivate * + * DESCRIPTION: + * + * This routine deactivates updating of the current time of day. */ STATIC INLINE void _TOD_Deactivate( void ) @@ -55,6 +66,9 @@ STATIC INLINE void _TOD_Deactivate( void ) * * _TOD_Activate * + * DESCRIPTION: + * + * This routine activates updating of the current time of day. */ STATIC INLINE void _TOD_Activate( diff --git a/cpukit/score/inline/rtems/score/tqdata.inl b/cpukit/score/inline/rtems/score/tqdata.inl index b16b3a1ca1..c7d8630062 100644 --- a/cpukit/score/inline/rtems/score/tqdata.inl +++ b/cpukit/score/inline/rtems/score/tqdata.inl @@ -21,32 +21,44 @@ * * _Thread_queue_Header_number * + * DESCRIPTION: + * + * This function returns the index of the priority chain on which + * a thread of the_priority should be placed. */ STATIC INLINE unsigned32 _Thread_queue_Header_number ( Priority_Control the_priority ) { - return ( the_priority >> 6 ); + return (the_priority / TASK_QUEUE_DATA_PRIORITIES_PER_HEADER); } /*PAGE * * _Thread_queue_Is_reverse_search * + * DESCRIPTION: + * + * This function returns TRUE if the_priority indicates that the + * enqueue search should start at the front of this priority + * group chain, and FALSE if the search should start at the rear. */ STATIC INLINE boolean _Thread_queue_Is_reverse_search ( Priority_Control the_priority ) { - return ( the_priority & 0x20 ); + return ( the_priority & TASK_QUEUE_DATA_REVERSE_SEARCH_MASK ); } /*PAGE * * _Thread_queue_Get_number_waiting * + * DESCRIPTION: + * + * This function returns the number of threads waiting on this thread queue. */ STATIC INLINE unsigned32 _Thread_queue_Get_number_waiting ( @@ -60,6 +72,10 @@ STATIC INLINE unsigned32 _Thread_queue_Get_number_waiting ( * * _Thread_queue_Enter_critical_section * + * DESCRIPTION: + * + * This routine is invoked to indicate that the specified thread queue is + * entering a critical section. */ STATIC INLINE void _Thread_queue_Enter_critical_section ( diff --git a/cpukit/score/inline/rtems/score/userext.inl b/cpukit/score/inline/rtems/score/userext.inl index 2b4483c553..a9a858b2e2 100644 --- a/cpukit/score/inline/rtems/score/userext.inl +++ b/cpukit/score/inline/rtems/score/userext.inl @@ -21,6 +21,9 @@ * * _User_extensions_Handler_initialization * + * DESCRIPTION: + * + * This routine performs the initialization necessary for this handler. */ STATIC INLINE void _User_extensions_Handler_initialization ( @@ -38,6 +41,10 @@ STATIC INLINE void _User_extensions_Handler_initialization ( /*PAGE * * _User_extensions_Add_set + * + * DESCRIPTION: + * + * This routine is used to add a user extension set to the active list. */ STATIC INLINE void _User_extensions_Add_set ( @@ -53,6 +60,9 @@ STATIC INLINE void _User_extensions_Add_set ( /*PAGE * * _User_extensions_Add_API_set + * DESCRIPTION: + * + * This routine is used to add an API extension set to the active list. */ STATIC INLINE void _User_extensions_Add_API_set ( @@ -65,6 +75,10 @@ STATIC INLINE void _User_extensions_Add_API_set ( /*PAGE * * _User_extensions_Remove_set + * + * DESCRIPTION: + * + * This routine is used to remove a user extension set from the active list. */ STATIC INLINE void _User_extensions_Remove_set ( @@ -78,6 +92,10 @@ STATIC INLINE void _User_extensions_Remove_set ( * * _User_extensions_Thread_switch * + * DESCRIPTION: + * + * This routine is used to invoke the user extension which + * is invoked when a context switch occurs. */ STATIC INLINE void _User_extensions_Thread_switch ( diff --git a/cpukit/score/inline/rtems/score/watchdog.inl b/cpukit/score/inline/rtems/score/watchdog.inl index ae3717e102..75fb662dfc 100644 --- a/cpukit/score/inline/rtems/score/watchdog.inl +++ b/cpukit/score/inline/rtems/score/watchdog.inl @@ -21,6 +21,11 @@ * * _Watchdog_Initialize * + * DESCRIPTION: + * + * This routine initializes the specified watchdog. The watchdog is + * made inactive, the watchdog id and handler routine are set to the + * specified values. */ STATIC INLINE void _Watchdog_Initialize( @@ -40,6 +45,10 @@ STATIC INLINE void _Watchdog_Initialize( * * _Watchdog_Is_active * + * DESCRIPTION: + * + * This routine returns TRUE if the watchdog timer is in the ACTIVE + * state, and FALSE otherwise. */ STATIC INLINE boolean _Watchdog_Is_active( @@ -55,6 +64,10 @@ STATIC INLINE boolean _Watchdog_Is_active( * * _Watchdog_Activate * + * DESCRIPTION: + * + * This routine activates THE_WATCHDOG timer which is already + * on a watchdog chain. */ STATIC INLINE void _Watchdog_Activate( @@ -70,6 +83,10 @@ STATIC INLINE void _Watchdog_Activate( * * _Watchdog_Deactivate * + * DESCRIPTION: + * + * This routine deactivates THE_WATCHDOG timer which will remain + * on a watchdog chain. */ STATIC INLINE void _Watchdog_Deactivate( @@ -85,6 +102,10 @@ STATIC INLINE void _Watchdog_Deactivate( * * _Watchdog_Tickle_ticks * + * DESCRIPTION: + * + * This routine is invoked at each clock tick to update the ticks + * watchdog chain. */ STATIC INLINE void _Watchdog_Tickle_ticks( void ) @@ -98,6 +119,10 @@ STATIC INLINE void _Watchdog_Tickle_ticks( void ) * * _Watchdog_Tickle_seconds * + * DESCRIPTION: + * + * This routine is invoked at each clock tick to update the seconds + * watchdog chain. */ STATIC INLINE void _Watchdog_Tickle_seconds( void ) @@ -111,6 +136,12 @@ STATIC INLINE void _Watchdog_Tickle_seconds( void ) * * _Watchdog_Insert_ticks * + * DESCRIPTION: + * + * This routine inserts THE_WATCHDOG into the ticks watchdog chain + * for a time of UNITS ticks. The INSERT_MODE indicates whether + * THE_WATCHDOG is to be activated automatically or later, explicitly + * by the caller. */ STATIC INLINE void _Watchdog_Insert_ticks( @@ -129,6 +160,12 @@ STATIC INLINE void _Watchdog_Insert_ticks( * * _Watchdog_Insert_seconds * + * DESCRIPTION: + * + * This routine inserts THE_WATCHDOG into the seconds watchdog chain + * for a time of UNITS seconds. The INSERT_MODE indicates whether + * THE_WATCHDOG is to be activated automatically or later, explicitly + * by the caller. */ STATIC INLINE void _Watchdog_Insert_seconds( @@ -147,6 +184,11 @@ STATIC INLINE void _Watchdog_Insert_seconds( * * _Watchdog_Adjust_seconds * + * DESCRIPTION: + * + * This routine adjusts the seconds watchdog chain in the forward + * or backward DIRECTION for UNITS seconds. This is invoked when the + * current time of day is changed. */ STATIC INLINE void _Watchdog_Adjust_seconds( @@ -163,6 +205,10 @@ STATIC INLINE void _Watchdog_Adjust_seconds( * * _Watchdog_Adjust_ticks * + * DESCRIPTION: + * + * This routine adjusts the ticks watchdog chain in the forward + * or backward DIRECTION for UNITS ticks. */ STATIC INLINE void _Watchdog_Adjust_ticks( @@ -179,6 +225,12 @@ STATIC INLINE void _Watchdog_Adjust_ticks( * * _Watchdog_Reset * + * DESCRIPTION: + * + * This routine resets THE_WATCHDOG timer to its state at INSERT + * time. This routine is valid only on interval watchdog timers + * and is used to make an interval watchdog timer fire "every" so + * many ticks. */ STATIC INLINE void _Watchdog_Reset( @@ -196,6 +248,10 @@ STATIC INLINE void _Watchdog_Reset( * * _Watchdog_Next * + * DESCRIPTION: + * + * This routine returns a pointer to the watchdog timer following + * THE_WATCHDOG on the watchdog chain. */ STATIC INLINE Watchdog_Control *_Watchdog_Next( @@ -211,6 +267,10 @@ STATIC INLINE Watchdog_Control *_Watchdog_Next( * * _Watchdog_Previous * + * DESCRIPTION: + * + * This routine returns a pointer to the watchdog timer preceding + * THE_WATCHDOG on the watchdog chain. */ STATIC INLINE Watchdog_Control *_Watchdog_Previous( @@ -226,6 +286,10 @@ STATIC INLINE Watchdog_Control *_Watchdog_Previous( * * _Watchdog_First * + * DESCRIPTION: + * + * This routine returns a pointer to the first watchdog timer + * on the watchdog chain HEADER. */ STATIC INLINE Watchdog_Control *_Watchdog_First( @@ -241,7 +305,12 @@ STATIC INLINE Watchdog_Control *_Watchdog_First( * * _Watchdog_Last * + * DESCRIPTION: + * + * This routine returns a pointer to the last watchdog timer + * on the watchdog chain HEADER. */ + STATIC INLINE Watchdog_Control *_Watchdog_Last( Chain_Control *header ) diff --git a/cpukit/score/inline/rtems/score/wkspace.inl b/cpukit/score/inline/rtems/score/wkspace.inl index 36ed61d565..a2dabfe962 100644 --- a/cpukit/score/inline/rtems/score/wkspace.inl +++ b/cpukit/score/inline/rtems/score/wkspace.inl @@ -21,6 +21,9 @@ * * _Workspace_Handler_initialization * + * DESCRIPTION: + * + * This routine performs the initialization necessary for this handler. */ STATIC INLINE void _Workspace_Handler_initialization( @@ -65,6 +68,11 @@ STATIC INLINE void _Workspace_Handler_initialization( * * _Workspace_Allocate * + * DESCRIPTION: + * + * This routine returns the address of a block of memory of size + * bytes. If a block of the appropriate size cannot be allocated + * from the workspace, then NULL is returned. */ STATIC INLINE void *_Workspace_Allocate( @@ -78,6 +86,11 @@ STATIC INLINE void *_Workspace_Allocate( * * _Workspace_Free * + * DESCRIPTION: + * + * This function frees the specified block of memory. If the block + * belongs to the Workspace and can be successfully freed, then + * TRUE is returned. Otherwise FALSE is returned. */ STATIC INLINE boolean _Workspace_Free( diff --git a/cpukit/score/macros/rtems/score/tqdata.inl b/cpukit/score/macros/rtems/score/tqdata.inl index df1508104c..5ffb79bcb1 100644 --- a/cpukit/score/macros/rtems/score/tqdata.inl +++ b/cpukit/score/macros/rtems/score/tqdata.inl @@ -24,7 +24,7 @@ */ #define _Thread_queue_Header_number( _the_priority ) \ - ( (_the_priority) >> 6 ) + ((_the_priority) / TASK_QUEUE_DATA_PRIORITIES_PER_HEADER) /*PAGE * @@ -33,7 +33,7 @@ */ #define _Thread_queue_Is_reverse_search( _the_priority ) \ - ( (_the_priority) & 0x20 ) + ( (_the_priority) & TASK_QUEUE_DATA_REVERSE_SEARCH_MASK ) /*PAGE * |