summaryrefslogtreecommitdiffstats
path: root/cpukit (follow)
Commit message (Collapse)AuthorAgeFilesLines
* posix: Simplify key implementationSebastian Huber2014-08-055-21/+44
|
* rbtree: Add and use RBTree_Compare_resultSebastian Huber2014-08-0513-49/+81
|
* Add and use RTEMS_CONTAINER_OF()Sebastian Huber2014-08-0520-71/+54
|
* rbtree: Rename find header in find controlSebastian Huber2014-07-292-14/+23
| | | | Simplify _RBTree_Find_control(). Avoid superfluous NULL pointer checks.
* rbtree: Simplify off-tree handlingSebastian Huber2014-07-292-21/+24
| | | | | | | Only use the parent pointer, since this pointer is never NULL for nodes which are part of a tree. Rename functions from *_off_rbtree() to *_off_tree().
* Delete unused *_Is_null() functionsSebastian Huber2014-07-2619-262/+0
|
* rbtree: Update maximum node in LIFO orderSebastian Huber2014-07-262-9/+11
| | | | | | The test sptests/sp35 showed a NULL pointer access due to an invalid maximum node field (e.g. a tree with one element and NULL as the maximum node).
* todimpl.h: Add missing DoxygenJoel Sherrill2014-07-231-0/+10
|
* coretod*.c: Fix Doxygen group and comment formattingJoel Sherrill2014-07-235-14/+14
|
* Add _TOD_Adjust to SCORE TOD Handler.Joel Sherrill2014-07-234-18/+79
| | | | | | | | This lays the proper structure for doing future work on time adjustment algorithms. Any TOD adjustments should be requested at the API level and performed at the SCORE level. Additionally updated a test.
* adjtime.c: Use timestamp math and simplifyJoel Sherrill2014-07-231-40/+28
|
* rbtree: Do not set node off-tree in extractSebastian Huber2014-07-222-5/+9
|
* rbtree: Remove superfluous NULL pointer checksSebastian Huber2014-07-224-36/+23
|
* rbtree: FormatSebastian Huber2014-07-226-117/+147
|
* Use Shared Method for Thread Unblock CleanupJoel Sherrill2014-07-154-60/+63
| | | | | | | | | | | When a thread is removed from a thread queue or is unblocked by receiving an event, the same actions are required. + timeout watchdog canceled, + thread must be unblocked, and + (MP only) proxy cleaned up This patch makes sure there is only one copy of this code.
* Thread Queue: Merge discipline subroutines into main methodsJoel Sherrill2014-07-1517-682/+246
| | | | | | | | | | | There was a lot of duplication between the discipline subroutines. With the transition to RBTrees for priority discipline, there were only a few lines of source code manipulating the data structure for FIFO and priority. Thus is made sense to fold these back into the main methods. As part of doing this all of the tests for discipline were changed to be in the same order.
* Thread Queue Priority Discipline Reimplemented with RBTreeJoel Sherrill2014-07-1510-325/+107
|
* rbtree: Reduce RBTree_Control sizeSebastian Huber2014-07-1515-173/+164
| | | | | | | | | | | | Remove compare function and is unique indicator from the control structure. Rename RBTree_Compare_function to RBTree_Compare. Rename rtems_rbtree_compare_function to rtems_rbtree_compare. Provide C++ compatible initializers. Add compare function and is unique indicator to _RBTree_Find(), _RBTree_Insert(), rtems_rbtree_find() and rtems_rbtree_insert(). Remove _RBTree_Is_unique() and rtems_rbtree_is_unique(). Remove compare function and is unique indicator from _RBTree_Initialize_empty() and rtems_rbtree_initialize_empty().
* rbtree: Delete unused functionsSebastian Huber2014-07-152-90/+0
|
* scheduleredfunblock.c: Correct spacingJoel Sherrill2014-07-141-1/+1
|
* semdelete.c: Correct spacingJoel Sherrill2014-07-141-1/+1
|
* capture: Fix capture engine to handle new extensions.Jennifer Averett2014-07-112-35/+76
|
* capture: Update comment block style in capture engine.Jennifer Averett2014-07-112-416/+378
| | | | Doxygen added and comment blocks standardized.
* score: Scheduler helping proto for affinity schedSebastian Huber2014-07-111-0/+12
| | | | | | | | | | | The priority affinity scheduler has the nice property that it can produce more than one scheduled to ready state change in one operation. Each scheduled to ready state change may lead to one thread in need for help. Since it is currently only possible to return at most one thread in need for help, we have a problem here. A solution might be to move the check for migrations into the ask for help mechanism.
* score: Fix scheduler helping implementationSebastian Huber2014-07-106-119/+39
| | | | | Do not extract the idle threads from the ready set so that there is always a thread available for comparison.
* score: Fix assertionsSebastian Huber2014-07-103-6/+8
|
* termios: Add rtems_termios_set_best_baud()Sebastian Huber2014-07-093-4/+64
|
* termios: Add rtems_termios_get_termios()Christian Mauderer2014-07-091-1/+14
|
* termios: PR1279: Use first open statusSebastian Huber2014-07-091-73/+82
|
* termios: PR1279: Use set attributes statusSebastian Huber2014-07-091-2/+4
|
* termios: PR2153: New low-level device APISebastian Huber2014-07-092-113/+630
| | | | | | | | | | | | | | | | | Add a new low-level device API to Termios that passes the TTY structure to the low-level device functions. This greatly simplifies the low-level device drivers since they are no longer forced to derive their private data from the minor number. It makes it possible to use the TTY low-level lock in the device driver low-level functions which is necessary for proper SMP support. For example to set the attributes it is often necessary to perform a read-modify-write operation on a control register used also by interrupt routines. A compatibility layer is provided to support device drivers using the old callback functions so it is not necessary to modify existing device drivers.
* score: _Scheduler_Thread_get_own_node()Sebastian Huber2014-07-091-1/+5
| | | | Provide this function also for uni-processor configurations.
* score: Implement scheduler helping protocolSebastian Huber2014-07-0927-127/+1321
| | | | | | | | | | | | | | | | | | | | | | | | | The following scheduler operations return a thread in need for help - unblock, - change priority, and - yield. A thread in need for help is a thread that encounters a scheduler state change from scheduled to ready or a thread that cannot be scheduled in an unblock operation. Such a thread can ask threads which depend on resources owned by this thread for help. Add a new ask for help scheduler operation. This operation is used by _Scheduler_Ask_for_help() to help threads in need for help returned by the operations mentioned above. This operation is also used by _Scheduler_Thread_change_resource_root() in case the root of a resource sub-tree changes. A use case is the ownership change of a resource. In case it is not possible to schedule a thread in need for help, then the corresponding scheduler node will be placed into the set of ready scheduler nodes of the scheduler instance. Once a state change from ready to scheduled happens for this scheduler node it may be used to schedule the thread in need for help.
* schedulerpriorityaffinitysmp.c: Add period at end of sentenceJoel Sherrill2014-07-081-1/+1
|
* score: Need for help indicator for scheduler opsSebastian Huber2014-07-0823-126/+258
| | | | | | | | | | | | | Return a thread in need for help for the following scheduler operations - unblock, - change priority, and - yield. A thread in need for help is a thread that encounters a scheduler state change from scheduled to ready or a thread that cannot be scheduled in an unblock operation. Such a thread can ask threads which depend on resources owned by this thread for help.
* score: Add _Scheduler_Help()Sebastian Huber2014-07-084-14/+159
| | | | Manage the help state of threads with respect to scheduling decisions.
* score: Rename *_Node_get() to *_Thread_get_node()Sebastian Huber2014-07-0824-44/+44
| | | | | | This emphasizes that the scheduler node of a thread is returned and this is not a function working with scheduler nodes like the other *_Node_*() functions.
* score: Simplify SMP processor allocationSebastian Huber2014-07-084-36/+62
| | | | Avoid copy and paste and set the scheduler node state in one place.
* score: Rename _Scheduler_SMP_Update_heir()Sebastian Huber2014-07-083-33/+35
| | | | | | Rename and move _Scheduler_SMP_Update_heir() to _Thread_Dispatch_update_heir() since this function is not scheduler specific.
* score: Fix warningSebastian Huber2014-07-071-1/+1
|
* score: Fix MrsP resource root changeSebastian Huber2014-07-041-1/+4
| | | | | Use the root of the owner for the new root, since the owner may depend on a resource as well.
* score: PR2183: Fix context switch on SMPSebastian Huber2014-07-046-28/+91
| | | | | | | | Fix context switch on SMP for ARM, PowerPC and SPARC. Atomically test and set the is executing indicator of the heir context to ensure that at most one processor uses the heir context. Break the busy wait loop also due to heir updates.
* arm: Use local label in _CPU_Context_restore()Sebastian Huber2014-07-011-2/+2
|
* score: Add PER_CPU_OFFSET_EXECUTINGSebastian Huber2014-07-012-17/+31
| | | | | Add PER_CPU_OFFSET_HEIR. Move Per_CPU_Control::executing and Per_CPU_Control::heir for easy offset calculation.
* termios: Make tty list staticSebastian Huber2014-06-302-4/+3
|
* rtems: Delete unused <rtems/rtems/atomic.h>Sebastian Huber2014-06-303-43/+0
|
* score: Workaround for GCC 4.9 for atomic opsSebastian Huber2014-06-302-784/+346
| | | | | | | | | The GCC 4.9 ships its own <stdatomic.h> which is not C++ compatible. The suggested solution was to include <atomic> in case C++ is used. This works at least with GCC 4.9. See also: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60932 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60940
* score: Fix _Thread_Start_multitasking() on SMPSebastian Huber2014-06-241-0/+13
| | | | | | | | | | The _CPU_Context_Restart_self() implementations usually assume that self context is executing. FIXME: We have a race condition in _Thread_Start_multitasking() in case another thread already performed scheduler operations and moved the heir thread to another processor. The time frame for this is likely too small to be practically relevant.
* score: Fix thread deletion on SMPSebastian Huber2014-06-231-5/+5
| | | | | | Close the thread object in _Thread_Make_zombie() so that all blocking operations that use _Thread_Get() in the corresponding release directive can find a terminating thread and can complete the operation.
* score: Decouple thread and scheduler nodes on SMPSebastian Huber2014-06-2310-279/+394
| | | | | | | Add a chain node to the scheduler node to decouple the thread and scheduler nodes. It is now possible to enqueue a thread in a thread wait queue and use its scheduler node at the same for other threads, e.g. a resouce owner.