summaryrefslogtreecommitdiffstats
path: root/cpukit/include/rtems/score (follow)
Commit message (Collapse)AuthorAgeFilesLines
* score: Add PER_CPU_DATA_NEED_INITIALIZATION()Sebastian Huber2021-06-101-0/+14
| | | | | | | | | Make the initialization of the per-CPU data optional. Change license to BSD-2-Clause according to file history and re-licensing agreement. Update #3053.
* score: Fix initialization of thread queue contextSebastian Huber2021-06-101-3/+9
| | | | | | | Set Thread_queue_Context::timeout_absolute in _Thread_queue_Context_set_timeout_argument() to avoid using it uninitialized. The bug was introduced by a89ecaa1a94d49ddae7753d6b83923e9d2a00486.
* score: Remove unused _Per_CPU_Initialize() declSebastian Huber2021-06-081-7/+0
|
* libcsupport: Added futimens() and utimensat()Ryan Long2021-05-281-7/+37
| | | | | | | | | | Created futimens.c and utimensat.c to add support for the POSIX methods futimens() and utimensat(). utime() and utimes() are considered obsolote by POSIX, but RTEMS will continue to support them. Closes #4396
* score: Add RTEMS_UNREACHABLE() to a groupSebastian Huber2021-05-281-0/+2
|
* score: Simplify calling _Thread_Exit()Sebastian Huber2021-05-261-7/+6
| | | | | Move common code into _Thread_Exit(). This enables a tail call optimization in most cases.
* score: Simplify thread queue timeout handlingSebastian Huber2021-05-183-13/+48
| | | | | | | Add Thread_queue_Context::timeout_absolute to specify an absolute or relative timeout. This avoid having to get the current time twice for timeouts relative to the current time. It moves also functionality to common code.
* score: Add and use _Per_CPU_Is_ISR_in_progress()Sebastian Huber2021-05-173-12/+21
| | | | | Add _Per_CPU_Is_ISR_in_progress() as an optimized version of _ISR_Is_in_progress().
* score: Improve parameters in _Thread_Change_life()Sebastian Huber2021-05-171-10/+12
|
* rtems: Fix task restart within interrupt contextSebastian Huber2021-05-141-14/+1
| | | | | | | | | | | rtems_task_restart() may be called from within interrupt context. So checking only that the thread to restart is equal to the executing thread is insufficient to determine a self restart. We have to also check that no ISR is in progress. Merge _Thread_Restart_other() and _Thread_Restart_self() into one _Thread_Restart() since they share a lot of common code. Close #4412.
* score: Return status in _Thread_Restart_other()Sebastian Huber2021-05-141-6/+9
| | | | This simplifies rtems_task_restart().
* score: Rename _Stack_Free_nothing()Sebastian Huber2021-05-113-8/+8
| | | | | | | Rename _Stack_Free_nothing() in _Objects_Free_nothing() to make it reusable for the message queue buffers. Update #4007.
* score: Make _Once_Lock() and _Once_Unlock() staticSebastian Huber2021-05-041-16/+0
| | | | These two functions are no longer used outside of _Once().
* score: Add _Thread_Dispatch_direct_no_return()Sebastian Huber2021-05-021-0/+11
| | | | | | | | | | The __builtin_unreachable() cannot be used with current GCC versions to tell the compiler that a function does not return to the caller, see: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=99151 Add a no return variant of _Thread_Dispatch_direct() to avoid generation of dead code.
* basedefs: Add RTEMS_NOINITSebastian Huber2021-04-301-16/+26
| | | | Update #3866.
* Use alias for rtems_task_self() and pthread_self()Sebastian Huber2021-04-301-0/+7
| | | | This may reduce the code size a bit.
* Return status code for _Thread_Start()Sebastian Huber2021-04-271-4/+3
| | | | | This avoids having conditional statements to get the API-specific status code.
* Return status code for _Scheduler_Set_affinity()Sebastian Huber2021-04-274-19/+35
| | | | | This avoids having conditional statements to get the API-specific status code.
* rtems: Change rtems_task_get_affinity() statusSebastian Huber2021-04-272-1/+3
| | | | | | | | | In case the processor set is not large enough to contain the processor affinity set of the task return RTEMS_INVALID_SIZE instead of RTEMS_INVALID_NUMBER. This is more in line with other directives since the issue is related to the size of an object. Close #4393.
* Return status code for _Scheduler_Get_affinity()Sebastian Huber2021-04-271-3/+4
| | | | | This avoids having conditional statements to get the API-specific status code.
* clock:_TOD_To_seconds(): Fix year 2514 overflowFrank Kühndel2021-04-211-0/+16
| | | | | | | | | | | | | | | | | | | | | | | This patch fixes issue #4338 by changing _TOD_Validate() to only accept years till 2105. This requires another patch to change the documentation of rtems_clock_set() and other affected API functions (indicating the end date is 2105 not 2514). I tried to support till year 2514 but it turned out that this needs changing the Timer Manager too. That in turn would mean to change _TOD_Seconds_since_epoch( void ) from 32 to 64 bit. Sebastian pointed out that a naive extension leads to trouble with 32 bit processors. He deemed a safe re-implementation too costly performance wise considering that year 2106 is far away and current binaries using RTEMS Classic API are unlikely to be in use by 2106. The constant TOD_SECONDS_AT_2100_03_01_00_00 in cpukit/rtems/src/clocktodtoseconds.c happens to be wrong by 1 hour. When setting the date 2100-Feb-28 23:59:59 and then reading the date again you will find yourself in 2100-Feb-27. Update #4338
* score: Remove unused _Thread_queue_Dequeue()Sebastian Huber2021-04-201-51/+0
| | | | | | | | | | | | Last use was removed by: commit 54550e048d3a49435912797d2024f80671e93267 Author: Sebastian Huber <sebastian.huber@embedded-brains.de> Date: Fri May 13 08:16:30 2016 +0200 posix: Rework pthread_join() Rework pthread_join() to use _Thread_Join().
* score: Replace Objects_Name_or_id_lookup_errorsSebastian Huber2021-04-073-41/+23
| | | | | Replace Objects_Name_or_id_lookup_errors with new Status_Control codes. Get rid of the _Status_Object_name_errors_to_status lookup table.
* score: Fix internal error status numberSebastian Huber2021-04-071-2/+2
| | | | | | The value of STATUS_CLASSIC_INTERNAL_ERROR must be equal to RTEMS_INTERNAL_ERROR. Add static assertions to ensure that the status codes match.
* score: Fix task stack initializationSebastian Huber2021-03-271-8/+6
| | | | | | | | | Do not adjust the stack area begin address since this may confuse the stack allocator and result in failed stack frees. Account for the alignment overhead in the stack space size estimate. Check that the stack size is in the expected interval.
* rtems: Allow initially locked MrsP semaphoresSebastian Huber2021-03-161-6/+22
| | | | | | Rejecting initially locked MrsP semaphores was due to a limitiation of the early limitiation of the MrsP protocol. This limitation no longer exists.
* score: Add Thread_Configuration::cpu_time_budgetSebastian Huber2021-03-161-0/+5
| | | | | Move the CPU time budget to the thread configuration. This simplifies _Thread_Initialize().
* basedefs: Clarify RTEMS_STRING(), RTEMS_XSTRING()Frank Kühndel2021-03-091-2/+4
|
* score: Ensure stack alignment requirementSebastian Huber2021-03-053-13/+30
| | | | | | | | Make sure that a user-provided stack size is the minimum size allocated for the stack. Make sure we meet the stack alignment requirement also for CPU ports with CPU_STACK_ALIGNMENT > CPU_HEAP_ALIGNMENT.
* score: Fix _Stack_Extend_size()Sebastian Huber2021-03-011-7/+21
| | | | | Check for an integer overflow. Add a validation test for task create errors.
* score: Fix thread initializationSebastian Huber2021-02-261-3/+19
| | | | | | | | Close the thread object if a thread create extension fails. Also call the delete extension to avoid resource leaks in early extensions if a late extension fails. Close #4270.
* score: Add Hash HandlerSebastian Huber2021-02-261-0/+168
| | | | Update #4267.
* score: Add _IO_Base64url()Sebastian Huber2021-02-251-7/+44
| | | | Update #4267.
* score: Remove _CORE_barrier_Do_flush()Sebastian Huber2021-02-241-17/+6
| | | | Call _Thread_queue_Flush_critical() directly.
* score: Simplify core barrierSebastian Huber2021-02-242-80/+32
| | | | | | Use the number of threads which must arrive at the barrier to trip the automatic release also to indicate if the barrier is a manual release barrier.
* score: Remove _Objects_Open()Sebastian Huber2021-02-242-41/+23
| | | | | Use the type safe _Objects_Open_u32() instead. Return the object identifier to enforce a common usage pattern.
* score: Add _Thread_Append_post_switch_action()Sebastian Huber2021-02-201-4/+34
| | | | Update #4244.
* score: Change thread action lockingSebastian Huber2021-02-201-8/+11
| | | | | | | | Require that the corresponding lock is acquired before the action handler returns. This helps to avoid recursion in the signal processing. Update #4244.
* basedefs: Add RTEMS_ALIGNOF()Sebastian Huber2021-02-191-1/+20
|
* Add macros to assert status and use itRyan Long2021-02-121-0/+30
| | | | | | | These macros are to be used to check the status from calls that are flagged by Coverity as 'Unchecked return value'. Fix file assert.h
* basedefs: Add stringification of argument listsSebastian Huber2021-02-091-8/+8
| | | | | | Change RTEMS_STRING() and RTEMS_XSTRING() to accept a variable number of arguments which is stringified. This can be used for example to create register lists for inline assembler statements.
* score: Add barrier thread queue operationsSebastian Huber2021-02-061-1/+8
| | | | | | | This fixes a missing decrement of the number of waiting threads during a barrier wait timeout. Close #4230.
* score: Make FIFO thread queue ops publicSebastian Huber2021-02-061-0/+134
| | | | Update #4230.
* score: Constify Thread_queue_First_operationSebastian Huber2021-02-061-6/+7
| | | | Update #4230.
* score: _Objects_Build_name() signed/unsigned charSebastian Huber2021-02-031-4/+4
| | | | | | | Change _Objects_Build_name() so that the result is independent of the signedness of char. Close #4228.
* score: Define _Assert() for static analysis runsSebastian Huber2021-02-012-2/+13
| | | | | | | | | The goal is to reduce false positive NULL_RETURNS, PW.NORETURN_FUNCTION_DOES_RETURN, PW.SET_BUT_NOT_USED, UNUSED_VALUE, etc. issues produced by Coverity. Define RTEMS_STATIC_ANALYSIS if a static analysis run by Coverity is performed.
* score: Clarify thread life state documentationSebastian Huber2021-02-011-2/+2
|
* score: Document Thread_Life_stateSebastian Huber2021-02-011-3/+40
|
* score: Remove unused _SMP_Assert()Sebastian Huber2021-02-011-9/+0
|
* score: Fix implicit type conversionSebastian Huber2021-02-011-1/+1
| | | | This fix relates to a Coverity issue (PW.MIXED_ENUM_TYPE).