summaryrefslogtreecommitdiffstats
path: root/cpukit/sapi (follow)
Commit message (Collapse)AuthorAgeFilesLines
* score: PR2152: Use allocator mutex for objectsSebastian Huber2014-03-312-5/+9
| | | | | Use allocator mutex for objects allocate/free. This prevents that the thread dispatch latency depends on the workspace/heap fragmentation.
* privateenv: Use POSIX keys instead of task variables.Christian Mauderer2014-03-271-11/+18
|
* score: PR2174: Add workaroundSebastian Huber2014-03-251-0/+6
| | | | | Add _Scheduler_FIXME_thread_priority_queues_are_broken to prevent thread priority queues in case an EDF scheduler is used.
* sapi: Add profiling report for testsSebastian Huber2014-03-251-0/+11
|
* Change all references of rtems.com to rtems.org.Chris Johns2014-03-2155-55/+55
|
* posix: Use interal mutex for once implementationSebastian Huber2014-03-193-14/+5
| | | | | | Enable pthread_once() for all configurations. The pthread_once() function is one means to initialize POSIX keys. Another use case is the C++ support.
* sapi: Add <rtems/test.h>Sebastian Huber2014-03-175-0/+205
| | | | | | Provide support functions to print the begin/end of test message. Provide a test fatal extension to print out profiling reports in the future.
* score: Add SMP lock profiling supportSebastian Huber2014-03-142-1/+63
|
* score: Add per-CPU profilingSebastian Huber2014-03-141-0/+61
| | | | | | | Add per-CPU profiling stats API. Implement the thread dispatch disable level profiling. The interrupt profiling must be implemented in CPU port specific parts (mostly assembler code). Add a support function _Profiling_Outer_most_interrupt_entry_and_exit() for this purpose.
* sapi: Add SMP lock profiling app. level dataSebastian Huber2014-03-142-1/+176
|
* sapi: Add per-CPU profiling application level dataSebastian Huber2014-03-142-0/+190
|
* sapi: Add profiling application level supportSebastian Huber2014-03-145-0/+277
|
* sapi: TyposSebastian Huber2014-03-131-3/+3
|
* score: Add local context to SMP lock APISebastian Huber2014-03-111-28/+28
| | | | | | | | | | | Add a local context structure to the SMP lock API for acquire and release pairs. This context can be used to store the ISR level and profiling information. It may be later used to enable more sophisticated lock algorithms, e.g. MCS locks. There is only one lock that cannot be used with a local context. This is the per-CPU lock since here we would have to transfer the local context through a context switch which is very complicated.
* sapi: Use one SMP lock for all chainsSebastian Huber2014-03-112-124/+78
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This partially reverts commit 1215fd4d9426a59d568560e9a485628560363133. In order to support profiling of SMP locks and provide a future compatible SMP locks API it is necessary to add an SMP lock destroy function. Since the commit above adds an SMP lock to each chain control we would have to add a rtems_chain_destroy() function as well. This complicates the chain usage dramatically. Thus revert the patch above. A global SMP lock for all chains is used to implement the protected chain operations. Advantages: * The SAPI chain API is now identical on SMP and non-SMP configurations. * The size of the chain control is reduced and is then equal to the Score chains. * The protected chain operations work correctly on SMP. Disadvantage: * Applications using many different chains and the protected operations may notice lock contention. The chain control size drop is a huge benefit (SAPI chain controls are 66% larger than the Score chain controls). The only disadvantage is not really a problem since these applications can use specific interrupt locks and unprotected chain operations to avoid this issue.
* POSIX keys now enabled in all configurations.Joel Sherrill2014-03-074-63/+89
| | | | | | | Formerly POSIX keys were only enabled when POSIX threads were enabled. Because they are a truly safe alternative to per-task variables in an SMP system, they are being enabled in all configurations.
* sapi: Moved smp initialization and added cpuset initilization.Jennifer Averett2014-03-071-2/+5
| | | | | | | SMP must be initialized in order to know the current set of cores available. Without this, you cannot initialize the default cpu_set_t associated with Classic API tasks and POSIX threads.
* score: SMP initialization and shutdown changesSebastian Huber2014-03-061-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Rename _SMP_Request_other_cores_to_perform_first_context_switch() into _SMP_Request_start_multitasking() since this requests now a multitasking start on all configured and available processors. The name corresponds _Thread_Start_multitasking() and _SMP_Start_multitasking_on_secondary_processor() actions issued in response to this request. Move in source file to right place. Rename PER_CPU_STATE_READY_TO_BEGIN_MULTITASKING into PER_CPU_STATE_READY_TO_START_MULTITASKING. Rename PER_CPU_STATE_BEGIN_MULTITASKING into PER_CPU_STATE_REQUEST_START_MULTITASKING. Rename _SMP_Request_other_cores_to_shutdown() into _SMP_Request_shutdown(). Add a per-CPU state lock to protect all changes. This was necessary to offer a controlled shutdown of the system (atomic read/writes alone are not sufficient for this kind of synchronization). Add documentation for Per_CPU_State. Delete debug output. New tests smptests/smpfatal01 and smptests/smpfatal02.
* score: Rename _Internal_error_Occurred()Sebastian Huber2014-02-215-6/+6
| | | | Rename _Internal_error_Occurred() into _Terminate().
* score: Add and use <rtems/score/smpimpl.h>Sebastian Huber2014-02-191-10/+2
| | | | | Collect SMP implementation specific parts in the <rtems/score/smpimpl.h> header file.
* score: Add RTEMS_FATAL_SOURCE_SMPSebastian Huber2014-02-191-1/+2
| | | | | | Use rtems_fatal() instead of _CPU_Fatal_halt() to shutdown processors in SMP configurations since this allows intervention of BSP or application specific fatal extensions.
* score: Add RTEMS_FATAL_SOURCE_BSPSebastian Huber2014-02-191-2/+1
| | | | | | Merge RTEMS_FATAL_SOURCE_BSP_GENERIC and RTEMS_FATAL_SOURCE_BSP_SPECIFIC into new fatal source RTEMS_FATAL_SOURCE_BSP. This makes it easier to figure out the code position given a fatal source and code.
* score: Delete INTERNAL_ERROR_SHUTDOWN_WHEN_NOT_UPSebastian Huber2014-02-192-17/+2
| | | | | This error case is no longer required since rtems_shutdown_executive() can be called anytime, anywhere
* score: Move _SMP_Request_other_cores_to_shutdown()Sebastian Huber2014-02-191-8/+0
| | | | | | Move _SMP_Request_other_cores_to_shutdown() invocation from rtems_shutdown_executive() to _Internal_error_Occurred() to allow a proper shutdown on SMP configurations even in the error case.
* score: Delete _Thread_BSP_contextSebastian Huber2014-02-192-38/+22
| | | | | | | | | | | | Do not return to BSP context in the exit() shutdown path. This makes it possible to re-use the initialization stack. It can be used for the interrupt stack for example. On targets with a small RAM this is a considerable benefit. This change eliminates also some special cases and simplifies the code. Delete _Thread_Set_global_exit_status(), _Thread_Get_global_exit_status() and _Thread_Stop_multitasking().
* score: Add SYSTEM_STATE_TERMINATEDSebastian Huber2014-02-191-1/+0
| | | | | | Merge systems states SYSTEM_STATE_SHUTDOWN and SYSTEM_STATE_FAILED into new system state SYSTEM_STATE_TERMINATED. This reflects that all system termination paths end up in _Internal_error_Occurred().
* score: Add CPU counter supportSebastian Huber2014-02-146-0/+269
| | | | | | | | | Add a CPU counter interface to allow access to a free-running counter. It is useful to measure short time intervals. This can be used for example to enable profiling of critical low-level functions. Add two busy wait functions rtems_counter_delay_ticks() and rtems_counter_delay_nanoseconds() implemented via the CPU counter.
* score: Change debug helper functionsSebastian Huber2014-02-124-28/+32
| | | | | | | | Rename rtems_internal_error_description() to rtems_internal_error_text(). Rename rtems_fatal_source_description() to rtems_fatal_source_text(). Rename rtems_status_code_description() to rtems_status_text(). Remove previous implementation of rtems_status_text().
* score/rbtree: Remove "unprotected" from APISebastian Huber2013-11-212-26/+42
|
* score/rbtree: Delete protected operationsSebastian Huber2013-11-211-112/+0
| | | | | The user of the red-black tree container must now ensure that at most one thread at once can access an instance.
* JFFS2: Add RTEMS supportSebastian Huber2013-09-191-1/+18
|
* sapi: SMP support for chainsSebastian Huber2013-08-303-31/+273
| | | | | | | | Add ISR lock to chain control for proper SMP protection. Replace rtems_chain_extract() with rtems_chain_explicit_extract() and rtems_chain_insert() with rtems_chain_explicit_insert() on SMP configurations. Use rtems_chain_explicit_extract() and rtems_chain_explicit_insert() to provide SMP support.
* score: Add and use CHAIN_INITIALIZER_ONE_NODE().Sebastian Huber2013-08-271-0/+16
| | | | | | Add and use CHAIN_NODE_INITIALIZER_ONE_NODE_CHAIN(), RTEMS_CHAIN_INITIALIZER_ONE_NODE() and RTEMS_CHAIN_NODE_INITIALIZER_ONE_NODE_CHAIN().
* posix: Update to the pthread_once changes.Chris Johns2013-08-232-64/+61
| | | | | | Implement the reeview changes. Add a POSIX Fatal error domain. Fix confdefs.h to correctly handle the internal POSIX mutexes.
* smp: Add Deterministic Priority SMP SchedulerSebastian Huber2013-08-201-1/+23
|
* smp: Replace Scheduler_simple_smp_ControlSebastian Huber2013-08-201-1/+1
| | | | | Replace Scheduler_simple_smp_Control with Scheduler_SMP_Control. Rename _Scheduler_simple_smp_Instance() to _Scheduler_SMP_Instance().
* score: _Priority_bit_map_Handler_initialization()Sebastian Huber2013-08-201-2/+0
| | | | | | | Delete _Priority_bit_map_Handler_initialization() and rely on BSS initialization. Move definition of _Priority_Major_bit_map and _Priority_Bit_map to separate file. Move definition of __log2table also to this file.
* posix: Change pthread_once to be SMP safe.Chris Johns2013-08-142-0/+9
| | | | | | | | | | Change pthread_once from using disabled pre-emption to using a pthread mutex making it SMP safe. GCC using a posix threading model uses pthread_once. The pthread mutex requires at least 1 mutex is configured so confdefs.h has been updated to account for the internal mutex.
* PR766: Delete __RTEMS_INSIDE__Sebastian Huber2013-08-081-3/+0
|
* posix: Create key implementation headerSebastian Huber2013-08-061-1/+1
| | | | | | Move implementation specific parts of key.h and key.inl into new header file keyimpl.h. The key.h contains now only the application visible API.
* Unlimited objects support for POSIX keysZhongwei Yao2013-08-061-5/+29
| | | | | | | This patch enables unlimited model in POSIX key manger and have a decent runtime on POSIX key searching, adding and deleting operations. Memory overhead is lower than current implementation when the size of key and key value becomes big.
* smp: Generalize _Thread_Start_multitasking()Sebastian Huber2013-08-051-2/+4
| | | | | | | | | | Add context parameter to _Thread_Start_multitasking() and use this function in rtems_smp_secondary_cpu_initialize(). This avoids duplication of code. Fix missing floating point context initialization in rtems_smp_secondary_cpu_initialize(). Now performed via _Thread_Start_multitasking().
* score: Delete SYSTEM_STATE_BEGIN_MULTITASKINGSebastian Huber2013-08-051-2/+0
| | | | | Nothing happened between the SYSTEM_STATE_BEGIN_MULTITASKING to SYSTEM_STATE_UP transition.
* score: Rename tod.h to todimpl.hSebastian Huber2013-08-011-1/+1
|
* smp: Provide cache optimized Per_CPU_ControlSebastian Huber2013-07-311-2/+1
| | | | Delete _Per_CPU_Information_p.
* score: Create object implementation headerSebastian Huber2013-07-266-5/+1
| | | | | | Move implementation specific parts of object.h and object.inl into new header file objectimpl.h. The object.h contains now only the application visible API.
* Include missing <rtems/score/threaddispatch.h>Sebastian Huber2013-07-262-4/+3
|
* score: Create mpci implementation headerSebastian Huber2013-07-261-3/+0
| | | | | Move implementation specific parts of mpci.h into new header file mpciimpl.h. The mpci.h contains now only the application visible API.
* rtems: Create signal implementation headerSebastian Huber2013-07-261-1/+1
| | | | | | Move implementation specific parts of signal.h into new header file signalimpl.h. The signal.h contains now only the application visible API.
* score: Create thread implementation headerSebastian Huber2013-07-262-3/+2
| | | | | | | | Move implementation specific parts of thread.h and thread.inl into new header file threadimpl.h. The thread.h contains now only the application visible API. Remove superfluous header file includes from various files.