]> begriffs open source - freertos/log
freertos
23 months agoUpdate ARMv8-M config definitions in template file (#970)
Rahul Kar [Wed, 31 Jan 2024 06:55:56 +0000 (12:25 +0530)]
Update ARMv8-M config definitions in template file (#970)

* Update ARMV8-M config definitions in template file

---------

Co-authored-by: GitHub Action <action@github.com>
23 months agoCmake: Create a single static library including port
barnatahmed [Tue, 30 Jan 2024 19:44:27 +0000 (20:44 +0100)]
Cmake: Create a single static library including port

Modify portable/CMakeLists.txt to create only one static library containing both the common kernel code and kernel port.

Change the freertos_kernel_port target from a STATIC library to an OBJECT library and introduce a new freertos_kernel_port_headers  INTERFACE library target.

---------

Co-authored-by: ABARNAT <ahmed.barnat@actia-engineering.tn>
Co-authored-by: Soren Ptak <ptaksoren@gmail.com>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
23 months agoFix ThirdParty/GCC/ATmega formatting (#965)
Phillip Stevens [Tue, 30 Jan 2024 05:42:20 +0000 (16:42 +1100)]
Fix ThirdParty/GCC/ATmega formatting (#965)

Unnecessary white space was introduced in PR #768
which affected the formatting of assembly code. This PR
returns the correct formatting. No functional change.

23 months agoAdd a check for configENABLE_MVE to M23, M33 ports (#968)
Gaurav-Aggarwal-AWS [Tue, 30 Jan 2024 05:13:53 +0000 (10:43 +0530)]
Add a check for configENABLE_MVE to M23, M33 ports (#968)

Add a check for configENABLE_MVE to M23, M33 ports

configENABLE_MVE is only applicable to Cortex-M55 and Cortex-M85 ports.
It must not be defined to 1 for other ARMv8_m ports.

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
23 months agoRemove configTOTAL_MPU_REGIONS from M3 MPU port (#966)
Gaurav-Aggarwal-AWS [Mon, 29 Jan 2024 18:29:18 +0000 (23:59 +0530)]
Remove configTOTAL_MPU_REGIONS from M3 MPU port (#966)

The number of MPU regions is not configurable for Cortex-M3 port and
therefore, it is misleading to have configTOTAL_MPU_REGIONS in
portmacro.h.

It was added in PR #952.

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
23 months agoAdd missing Task Notification IFDEF (#967)
Soren Ptak [Mon, 29 Jan 2024 17:19:09 +0000 (12:19 -0500)]
Add missing Task Notification IFDEF (#967)

Wrap the task notification check in vTaskGetInfo() in in a  #if ( configUSE_TASK_NOTIFICATIONS == 1 )

23 months agoAdd code to allow building for x64 in MSVC (#924)
José Simões [Mon, 29 Jan 2024 06:35:10 +0000 (06:35 +0000)]
Add code to allow building for x64 in MSVC (#924)

* Add code to allow building for x64 in MSVC

- Add code for x64 arch.
- Add initial value for local otherwise it won't get proper value in x64.

* Moving init local to portGET_HIGHEST_PRIORITY

- From code review.

* More changes following review

* Another style fix from review

* Update formatting

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
---------

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
Co-authored-by: Nikhil Kamath <110539926+amazonKamath@users.noreply.github.com>
Co-authored-by: Soren Ptak <ptaksoren@gmail.com>
Co-authored-by: Gaurav Aggarwal <aggarg@amazon.com>
23 months agoGCC: MSP430F449: Fix pxPortInitialiseStack on EABI (#947)
Forty-Bot [Mon, 29 Jan 2024 05:37:43 +0000 (00:37 -0500)]
GCC: MSP430F449: Fix pxPortInitialiseStack on EABI (#947)

According to the MSP430 EABI [1] section 3.3,

Arguments are assigned, in declared order, to the first available
register single, pair, or quad from the following list into which it
fits (with the following special exceptions). For MSP430 and
MSP430X, the argument registers are: R12, R13, R14, R15

Therefore, pvParameters should be passed in R12, as it is the first
argument, not R15. Keep passing the parameter in R15 for the
MSP430 EABI, if anyone is still using it.

[1] https://www.ti.com/lit/an/slaa534a/slaa534a.pdf

23 months agoFix MacOS Posix port (#957)
Soren Ptak [Sun, 28 Jan 2024 13:11:03 +0000 (08:11 -0500)]
Fix MacOS Posix port (#957)

PR #914 caused Posix Port to fail to build on MacOS. This PR fixes
teh build failure.

This PR also adds a Matrix configuration to the GitHub kernel-demo
workflow to build the Posix Demos on MacOS.
---------

Co-authored-by: chinglee-iot <61685396+chinglee-iot@users.noreply.github.com>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
23 months agouse configSTACK_DEPTH_TYPE consequently (updated for 11.0.x) (#942)
Phillip Stevens [Sat, 27 Jan 2024 05:26:55 +0000 (16:26 +1100)]
use configSTACK_DEPTH_TYPE consequently (updated for 11.0.x) (#942)

* use configSTACK_DEPTH_TYPE consequently

* update default to uint32_t

* Update FreeRTOS.h

Revert for backwards compatibility

* Update portable.h

* configSTACK_DEPTH_TYPE - unify stack variable naming

* update lexicon.txt

* update typo lexicon.txt

* Update task.h

* Update timers.h

* fix merge typo

* fix stack type

* fix timer stack type

* fix timer stack more

* fix affinity set stack

* adjust ports to use configSTACK_DEPTH_TYPE

* fix vTaskListTasks

* set default stack depth type in portable.h

* fix History.txt

* update affinityset

* resolve reviewer comments

* fix prvTaskCheckFreeStackSpace for variable stack size type

* restore CoRoutine defines

* remove obsolete stack ttype casts

* fix (attempt) for format portable.h

* Formatting fixes

* prvTaskCheckFreeStackSpace make variable naming compliant

* Update portable/GCC/ARM_CM33/non_secure/port.c

Co-authored-by: Soren Ptak <ptaksoren@gmail.com>
* Update portable/GCC/ARM_CM23/non_secure/port.c

Co-authored-by: Soren Ptak <ptaksoren@gmail.com>
* Apply suggestions from code review

Update ulStackDepth to uxStackDepth

Co-authored-by: Soren Ptak <ptaksoren@gmail.com>
* Correct uxStackDepth in port.c

Also add uint32_t cast prvGetMPURegionSizeSetting.

* Update ARM CM3 MPU port.c

Revert casting of ( uint32_t ) pxBottomOfStack

* Code review suggestions

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
---------

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
Co-authored-by: Rahul Kar <118818625+kar-rahul-aws@users.noreply.github.com>
Co-authored-by: Soren Ptak <ptaksoren@gmail.com>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
Co-authored-by: Gaurav Aggarwal <aggarg@amazon.com>
23 months ago Sync up MicroblazeV9 port with Xilinx tree (#220)
Mubin Sayyed [Fri, 26 Jan 2024 03:21:44 +0000 (08:51 +0530)]
 Sync up MicroblazeV9 port with Xilinx tree (#220)

* MicroblazeV9: Add support for 64 bit microblaze
* MicroblazeV9: Add support for generation of run time task stats
* MicroblazeV9: Add default implementation for callback functions
---------
Signed-off-by: Mubin Usman Sayyed <mubin.usman.sayyed@xilinx.com>
23 months agoAdd check for if the scheduler is running to ARMv8M MPU ports (#960)
Soren Ptak [Wed, 24 Jan 2024 18:52:13 +0000 (13:52 -0500)]
Add check for if the scheduler is running to ARMv8M MPU ports (#960)

* Allow access to any buffer in xPortIsAuthorizedToAccessBuffer if xSchedulerRunning is set to pdFALSE

* Allow access to any buffer in xPortIsAuthorizedToAccessBuffer if xSchedulerRunning is set to pdFALSE in the copied ARMv8M Port Files

23 months agoUpdate for unpaired critical section in vTaskSuspend (#959)
chinglee-iot [Wed, 24 Jan 2024 11:48:31 +0000 (19:48 +0800)]
Update for unpaired critical section in vTaskSuspend (#959)

* Move the taskEXIT_CRITICAL out of the configNUMBER_OF_CORES macro block to improve readability.

23 months agoAdd check for if the scheduler is running to MPU ports (#954)
Soren Ptak [Tue, 23 Jan 2024 19:48:20 +0000 (14:48 -0500)]
Add check for if the scheduler is running to MPU ports (#954)

* In the ARM_CM3_MPU and ARM_CM4_MPU Port function xPortIsAuthorizedToAccessBuffer() grant access to the buffer if xSchedulerRunning is false.

23 months agoUpdate unpaired critical section in vTaskDelete for readability (#958)
chinglee-iot [Tue, 23 Jan 2024 09:02:15 +0000 (17:02 +0800)]
Update unpaired critical section in vTaskDelete for readability (#958)

* Modify unpaired critical section for readability
* Move prvDeleteTCB out of critical section for SMP

---------

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
Co-authored-by: Gaurav Aggarwal <aggarg@amazon.com>
23 months agoPosix port - set name for threads (#950)
Mikhail Paulyshka [Thu, 18 Jan 2024 19:35:16 +0000 (22:35 +0300)]
Posix port - set name for threads (#950)

Co-authored-by: jasonpcarroll <23126711+jasonpcarroll@users.noreply.github.com>
23 months agoMPU assert for ARM_CM3_MPU (#952)
IsaacDynamo [Thu, 18 Jan 2024 19:12:21 +0000 (20:12 +0100)]
MPU assert for ARM_CM3_MPU (#952)

* Add runtime check to see if the target even has a MPU

* Add missing extern symbols for __ARMCC_VERSION support

* Add default for configTOTAL_MPU_REGIONS and change a runtime assert to compile time error

* Simplify check and link to reference documentation

Co-authored-by: Soren Ptak <ptaksoren@gmail.com>
---------

Co-authored-by: Soren Ptak <ptaksoren@gmail.com>
Co-authored-by: jasonpcarroll <23126711+jasonpcarroll@users.noreply.github.com>
23 months agoMake configSUPPORT_STATIC_ALLOCATION==1 an error for MPU ports (#953)
IsaacDynamo [Thu, 18 Jan 2024 19:02:41 +0000 (20:02 +0100)]
Make configSUPPORT_STATIC_ALLOCATION==1 an error for MPU ports (#953)

* Error when configSUPPORT_STATIC_ALLOCATION is set for MPU ports

* Uncrustify: triggered by comment.

---------

Co-authored-by: GitHub Action <action@github.com>
Co-authored-by: Soren Ptak <ptaksoren@gmail.com>
23 months agoAdd mpu_wrappers_v2_asm.c to MPU ports (#951)
IsaacDynamo [Wed, 17 Jan 2024 20:22:32 +0000 (21:22 +0100)]
Add mpu_wrappers_v2_asm.c to MPU ports (#951)

Co-authored-by: Soren Ptak <ptaksoren@gmail.com>
23 months agoFix -Werror=unused-parameter in GCC posix prvTimerTickHandler() (#949)
Tony Josi [Sat, 13 Jan 2024 16:13:05 +0000 (21:43 +0530)]
Fix -Werror=unused-parameter in GCC posix prvTimerTickHandler() (#949)

23 months agoPOSIX port - Switch from allowing the user to specify the stack memory itself, to...
Chris Morgan [Wed, 29 Nov 2023 13:15:50 +0000 (08:15 -0500)]
POSIX port - Switch from allowing the user to specify the stack memory itself, to allowing them to specify the stack size

Change from pthread_attr_setstack() to pthread_attr_setstacksize(), and automatically adjust the stack size
to be at least PTHREAD_STACK_MIN if it wasn't already, removing the size warning.

This permits the user to increase the pthread stack size beyond the PTHREAD_STACK_MIN default of 16384 if
desired, without producing a warning in the typical case where stacks are minimized for RAM limited targets.

Continue to store thread paramters on the provided stack, for consistency with the MCU targets.

Previously pthread_attr_setstack() was used to enable user defined stacks.

Note that:

1. The stack size can still be specified by the user.

2. pxPortInitialiseStack(), and pthread_addr_setstack() was failing on stacks of typical size, as
   these are smaller than PTHREAD_STACK_MIN (16384) bytes, and printing out a series of warnings.
   Improve usability by having the posix port automatically increase the stack size to be
   at least PTHREAD_STACK_MIN as posix platforms have enough memory for this not to be a concern.

3. Reuse of stack memory will also result in valgrind 'invalid write' errors to what is demonstrably
   valid memory. Root cause is that Valgrind is tracking a stack pointer as the stack is used.
   Reuse of a stack buffer results in the stack being used at its start, in an area that Valgrind thinks
   is far away from the start of the stack. There are ways to notify Valgrind of these changes
   however this would require linking against and calling Valgrind functions from the FreeRTOS application using
   the posix port, https://valgrind.org/docs/manual/manual-core-adv.html#manual-core-adv.clientreq.

   Also, apparently it isn't permitted by posix to reuse stack memory once its been used in a pthread via pthread_attr_setstack(),
   see https://stackoverflow.com/a/5422134

23 months agoRevert pthread_attr_setstacksize
Ching-Hsin Lee [Wed, 10 Jan 2024 12:30:46 +0000 (20:30 +0800)]
Revert pthread_attr_setstacksize

23 months agoRevert timer tick function
Ching-Hsin,Lee [Wed, 10 Jan 2024 05:48:35 +0000 (05:48 +0000)]
Revert timer tick function

23 months agoAdd back event signal
Ching-Hsin,Lee [Wed, 10 Jan 2024 05:45:02 +0000 (05:45 +0000)]
Add back event signal

23 months agoRemove redundent cancellation point
Ching-Hsin,Lee [Wed, 10 Jan 2024 05:39:27 +0000 (05:39 +0000)]
Remove redundent cancellation point

23 months agoformat and header file
Ching-Hsin,Lee [Wed, 10 Jan 2024 05:38:18 +0000 (05:38 +0000)]
format and header file

23 months agoAdd back heap setup code
Ching-Hsin,Lee [Wed, 10 Jan 2024 05:32:14 +0000 (05:32 +0000)]
Add back heap setup code

23 months agoUPdate format
Ching-Hsin,Lee [Wed, 10 Jan 2024 05:20:51 +0000 (05:20 +0000)]
UPdate format

23 months agoAdd back the pthread stack fit
Ching-Hsin Lee [Wed, 10 Jan 2024 05:18:55 +0000 (13:18 +0800)]
Add back the pthread stack fit

23 months agoFix potential race condition
Ching-Hsin,Lee [Wed, 10 Jan 2024 05:08:03 +0000 (05:08 +0000)]
Fix potential race condition

23 months agoPOSIX port - Cancel and join all FreeRTOS managed pthreads upon shutdown
Chris Morgan [Tue, 28 Nov 2023 13:57:37 +0000 (08:57 -0500)]
POSIX port - Cancel and join all FreeRTOS managed pthreads upon shutdown

For a clean shutdown where memory is freed, it is necessary for all pthreads to be joined
at shutdown.

Previously there was explicit cancellation of the idle task and timer daemon task, however
there may be a number of other tasks in the system, both system created and user created,
and those tasks/threads were being left at shutdown.

This change calls pthread_cancel()/pthread_join() on all FreeRTOS managed pthreads upon
shutdown.

23 months agoPOSIX - Switch from posix timers to a timer thread to fix signal handling with non...
Chris Morgan [Tue, 28 Nov 2023 12:40:11 +0000 (07:40 -0500)]
POSIX - Switch from posix timers to a timer thread to fix signal handling with non-FreeRTOS pthreads

Improve upon the elegant approach of using signals to cause task/pthreads
suspension and scheduler execution by using directed signals.

This fixes:
- Deadlocks in non-FreeRTOS pthreads
- Multiple FreeRTOS tasks(pthreads) incorrectly running at the same time

By directing the signals using pthread_kill() the signal handler in the presently running
FreeRTOS task/pthread will be called, ensuring that the scheduler runs both in the context
of a FreeRTOS task/pthread and from the presently executing FreeRTOS task/pthread.

Details
==============

The POSIX port uses signals to preempt FreeRTOS tasks (implemented as pthreads), a very neat and elegant
approach to forcing tasks/pthreads to suspend and run the scheduler.

Signal handlers are process global.

Posix timers generate signals when the timer expires, and the signal is sent to the currently
running pthread.

In systems where there are pthreads that are NOT a result of creating FreeRTOS tasks, such as the
entry point thread that calls main(), or user created pthreads, this poses a serious issue.

While the POSIX port only allows a single FreeRTOS pthread to run at once, by causing all suspended
threads to not be scheduled due to their waiting on a pthread condition variable,
this isn't the case with non-FreeRTOS pthreads.

Thus it is possible that a non-FreeRTOS pthread is running when the timer expires and the signal
is generated. This results in the signal handler running in the non-FreeRTOS thread.

The sequence of events results in these events from signal handler context:
- vPortSystemTickHandler() being called
- The scheduler running
- Selecting another FreeRTOS task to run and switching the active task
- The newly selected task released from suspension by pthread_cond_signal()
- The presently active thread calling event_wait()
- The pthread calling pthread_cond_wait(), suspending the thread and allowing the host OS scheduler
  to schedule another thread to run.

If this occurs from a non-FreeRTOS thread this results in:
- The active FreeRTOS pthread (Task A/Thread A) continuing to run (as the signal handler that calls
  event_wait() ran instead in a non-FreeRTOS pthread.
- The pthread where the signal handler did run (Thread B) will call event_wait() and pthread_cond_wait(),
  but on the condition variable of the previously active FreeRTOS task, oops. This causes the
  non-FreeRTOS pthread to block unexpectedly relative to what the developer might have expected.
- The newly selected FreeRTOS Task (Task C/Thread C) will resume and start running.

At this point Task A/Thread A is running concurrently with Task C/Thread C. While this may not
necessarily be an issue, it does not replicate the expected behavior of a single Task running at
once.

Note that Thread B will resume if/when Task A/ThreadA is switched to. However, this could be delayed
by an arbitrary amount of time, or could never occur.

Also note that if there are multiple non-FreeRTOS pthreads that Thread D, E, F...etc could suffer the
same fate as Thread B, if the scheduler were to suspend Task C/Thread C and resume Task E/Thread E.

Implementation
==============

Timer details
-------------
A standalone pthread for the signal generation thread was chosen, rather than using
a posix timer_settime() handler function because the latter creates a temporary
pthread for each handler callback. This makes debugging much more difficult due to
gdb detecting the creation and destruction of these temporary threads.

Signal delivery
--------------
While signal handlers are per-thread, it is possible for pthreads to selectively block
signals, rather than using thread directed signals. However, the approach of blocking
signals in non-FreeRTOS pthreads adds complexity to each of these non-FreeRTOS pthreads
including ensuring that these signals are blocked at thread creation, prior to the thread
starting up. Directed signals removes the requirement for non-FreeRTOS pthreads to be aware
of and take action to protect against these signals, reducing complexity.

23 months agoRevert #768 on the XCC/Xtensa portable files (#948)
Soren Ptak [Wed, 10 Jan 2024 14:58:45 +0000 (09:58 -0500)]
Revert #768 on the XCC/Xtensa portable files (#948)

23 months agoAssign idle task to each core before SMP scheduler start (#945)
chinglee-iot [Tue, 9 Jan 2024 06:03:47 +0000 (14:03 +0800)]
Assign idle task to each core before SMP scheduler start (#945)

Co-authored-by: Rahul Kar <118818625+kar-rahul-aws@users.noreply.github.com>
23 months agoAdd new common words to the cSpellWordList.txt (#946)
Soren Ptak [Mon, 8 Jan 2024 06:28:18 +0000 (01:28 -0500)]
Add new common words to the cSpellWordList.txt (#946)

23 months agoAdded ability to change task notification index for streambuffers (#939)
Gabriele Monaco [Thu, 4 Jan 2024 19:43:34 +0000 (22:43 +0300)]
Added ability to change task notification index for streambuffers (#939)

* Added possibility to change notification index for streambuffers

* Uncrustify: triggered by comment.

* Minor code review suggestions.

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
---------

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
Co-authored-by: GitHub Action <action@github.com>
Co-authored-by: Aniruddha Kanhere <60444055+AniruddhaKanhere@users.noreply.github.com>
Co-authored-by: Gaurav Aggarwal <aggarg@amazon.com>
23 months agoFix documentation for xQueueTakeMutexRecursive (#943)
Eric Jackson [Wed, 3 Jan 2024 19:49:02 +0000 (11:49 -0800)]
Fix documentation for xQueueTakeMutexRecursive (#943)

23 months agoFix portSET_INTERRUPT_MASK_FROM_ISR definition for atomic operation (#940)
chinglee-iot [Wed, 3 Jan 2024 07:47:05 +0000 (15:47 +0800)]
Fix portSET_INTERRUPT_MASK_FROM_ISR definition for atomic operation (#940)

* Introduce portHAS_NESTED_INTERRUPTS to identify if port has nested interrupt or not.
* Update atomic.h to use portHAS_NESTED_INTERRUPTS instead of portSET_INTERRUPT_MASK_FROM_ISR definition.

---------

Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
Co-authored-by: ActoryOu <jay2002824@gmail.com>
23 months agoRP2040: Fix removal of idle_task_static_memory.c (#935)
dps.lwk [Wed, 3 Jan 2024 05:36:04 +0000 (05:36 +0000)]
RP2040: Fix removal of idle_task_static_memory.c (#935)

Co-authored-by: Rahul Kar <118818625+kar-rahul-aws@users.noreply.github.com>
2 years agoFix build error for MSP430 and Cortex A with IAR (#937)
Jeff Tenney [Fri, 29 Dec 2023 19:48:56 +0000 (12:48 -0700)]
Fix build error for MSP430 and Cortex A with IAR (#937)

* fix whitespace in asm macros

* Revert formatting ARM_CA5_No_GIC and ARM_CA9

2 years agoExport MPU Section Attributes (#931)
Soren Ptak [Tue, 26 Dec 2023 10:36:50 +0000 (05:36 -0500)]
Export MPU Section Attributes (#931)

Export the PRIVILEGED_FUNCTION, PRIVILEGED_DATA, and FREERTOS_SYSTEM_CALL
attributes to make it easier for end users to add their own privileged functions and
system calls.

2 years agoRP2040: FreeRTOS-Kernel-Static use configKERNEL_PROVIDED_STATIC_MEMORY (#934)
dps.lwk [Tue, 26 Dec 2023 09:02:47 +0000 (09:02 +0000)]
RP2040: FreeRTOS-Kernel-Static use configKERNEL_PROVIDED_STATIC_MEMORY (#934)

Remove the idle_task_static_memory.c and use the new default implementations
to allows for FreeRTOS-Kernel-Static to be used with configNUMBER_OF_CORES > 1

2 years agoFix build with modern GCC (#933)
Forty-Bot [Fri, 22 Dec 2023 21:09:55 +0000 (16:09 -0500)]
Fix build with modern GCC (#933)

* GCC: MSP430F449: Add missing attributes

Apparently at some point in the past, GCC (or TI's GCC) used to define
these attributes. Define them ourselves so that we can compile the demo
application.

* GCC: MSP430F449: Make interrupts return void

If a return type of a function is not specified, it defaults to int. Set
the return type of interrupts to void to avoid warnings.

* GCC: MSP430F449: Define portPOINTER_SIZE_TYPE

portPOINTER_SIZE_TYPE defaults to uint32_t if undefined. Define it to
uint16_t, which is correct for this port.

2 years agoUpdate History.txt for V11.0.1 (#932)
Rahul Kar [Thu, 21 Dec 2023 06:13:30 +0000 (11:43 +0530)]
Update History.txt for V11.0.1 (#932)

* Update History for V11.0.1

2 years agoUpdate History.txt for v11.0.0 (#926)
chinglee-iot [Mon, 18 Dec 2023 09:16:22 +0000 (17:16 +0800)]
Update History.txt for v11.0.0 (#926)

* Update History.txt for v11.0.0

2 years agoRename sample configuration to template configuration (#927)
Rahul Kar [Mon, 18 Dec 2023 05:13:08 +0000 (10:43 +0530)]
Rename sample configuration to template configuration (#927)

* Rename sample configuration to template configuration

* Rename sample configuration to template configuration in cmake example file

2 years agoUpdate comments related to portYIELD_FROM_ISR() in queue.h #925
Soren Ptak [Fri, 15 Dec 2023 17:34:52 +0000 (12:34 -0500)]
Update comments related to portYIELD_FROM_ISR() in queue.h #925

2 years agoUpdate sample configuration file (#923)
Rahul Kar [Fri, 15 Dec 2023 04:31:18 +0000 (10:01 +0530)]
Update sample configuration file  (#923)

* Update sample configuration file in the examples folder

* Add SMP Configuration definitions

* Fix build issue in cmake example

* Add CoRoutine Configuration definitions

* Code review suggestions

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
* Fix formatting

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
---------

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
Co-authored-by: Gaurav Aggarwal <aggarg@amazon.com>
2 years agoRemove the sample smp configuration folder (#922)
chinglee-iot [Wed, 13 Dec 2023 08:11:29 +0000 (16:11 +0800)]
Remove the sample smp configuration folder (#922)

* Remove the sample smp configuration folder

2 years agoAdd portTASK_SWITCH_HOOK (#867)
Darian [Mon, 11 Dec 2023 07:12:53 +0000 (15:12 +0800)]
Add portTASK_SWITCH_HOOK (#867)

This commit adds a portTASK_SWITCH_HOOK() macro which allows ports to inject
behavior immediately after a context switch. For example, this macro could be
used by ports that need to set an end of stack watchpoint after a context
swtich.

Co-authored-by: Rahul Kar <118818625+kar-rahul-aws@users.noreply.github.com>
Co-authored-by: Soren Ptak <ptaksoren@gmail.com>
Co-authored-by: chinglee-iot <61685396+chinglee-iot@users.noreply.github.com>
Co-authored-by: Tony Josi <tonyjosi@amazon.com>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
2 years agoDetect more startup config errors on Cortex M (#832)
Jeff Tenney [Mon, 11 Dec 2023 04:57:47 +0000 (21:57 -0700)]
Detect more startup config errors on Cortex M (#832)

Verify that the application has correctly installed PendSV
and SVCall handlers. The application can choose to
disable these checks by setting configCHECK_HANDLER_INSTALLATION
to 0 in their FreeRTOSConfig.h.

2 years agoUpdate the memory alignment within the Cortex-A9 port asm code (#426)
RichardBarry [Sat, 9 Dec 2023 09:19:39 +0000 (01:19 -0800)]
Update the memory alignment within the Cortex-A9 port asm code (#426)

Update alignment in ARM_CA9 port.

2 years agoRemove lint suppression comment (#920)
chinglee-iot [Fri, 8 Dec 2023 06:49:42 +0000 (14:49 +0800)]
Remove lint suppression comment (#920)

Remove lint suppression comment

2 years agoAdd constanst suffix to prevent potential type conversion (#921)
chinglee-iot [Fri, 8 Dec 2023 06:06:55 +0000 (14:06 +0800)]
Add constanst suffix to prevent potential type conversion (#921)

Co-authored-by: Ubuntu <ubuntu@ip-172-31-34-245.ap-northeast-1.compute.internal>
2 years agoAdd coverity example (#870)
chinglee-iot [Thu, 7 Dec 2023 19:24:20 +0000 (03:24 +0800)]
Add coverity example (#870)

* Add coverity example

* Update for CI

* Fix for CI 2

* Update kernel_misra.config

* Rename coverity example to coverity

* Update FreeRTOSConfig.h for coverity project

* Update MISRA.md

* Move coverity config to coverity_misra.config

* Update coverity misra config

* Add README.md file

* Update FreeRTOSConfig.h for coverity

* Fix uncrustify and spell

* Update README.md for relative link path

Update README.md for relative link path

* Update README.md for relative link 2

* Update MISRA.md for relateive path

* Fix for format

* Update coverity_misra.config

* Update configuration folder

* Update README.md for link

* Code review suggestions

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
---------

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
Co-authored-by: Ubuntu <ubuntu@ip-172-31-34-245.ap-northeast-1.compute.internal>
Co-authored-by: Rahul Kar <118818625+kar-rahul-aws@users.noreply.github.com>
Co-authored-by: Soren Ptak <ptaksoren@gmail.com>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
Co-authored-by: Gaurav Aggarwal <aggarg@amazon.com>
2 years agoRevert Portable/BCC formatting (#828)
Soren Ptak [Thu, 7 Dec 2023 16:51:11 +0000 (11:51 -0500)]
Revert Portable/BCC formatting (#828)

Revert Portable/BCC formatting

2 years agoRevert Portable/oWatcom formatting (#829)
Soren Ptak [Thu, 7 Dec 2023 16:40:50 +0000 (11:40 -0500)]
Revert Portable/oWatcom formatting (#829)

Revert the formatting on oWatcom ports

2 years agoRevert Portable/Paradigm formatting (#830)
Soren Ptak [Thu, 7 Dec 2023 16:32:49 +0000 (11:32 -0500)]
Revert Portable/Paradigm formatting (#830)

Revert the formatting on Paradigm ports

2 years agoRevert Portable/CodeWarrior formatting (#831)
Soren Ptak [Thu, 7 Dec 2023 16:16:33 +0000 (11:16 -0500)]
Revert Portable/CodeWarrior formatting (#831)

Revert the formatting on CodeWarrior ports

2 years agoUpdate partner and community supported port submodule pointer (#919)
chinglee-iot [Thu, 7 Dec 2023 11:43:02 +0000 (19:43 +0800)]
Update partner and community supported port submodule pointer (#919)

2 years agoSuppress MISRA C:2012 rule 21.6 for snprintf (#877)
chinglee-iot [Thu, 7 Dec 2023 10:51:14 +0000 (18:51 +0800)]
Suppress MISRA C:2012 rule 21.6 for snprintf (#877)

Suppress MISRA C:2012 rule 21.6 for snprintf

2 years agoFix MISRA C 2012 Rule 11.1 deviations (#856)
chinglee-iot [Thu, 7 Dec 2023 10:15:19 +0000 (18:15 +0800)]
Fix MISRA C 2012 Rule 11.1 deviations (#856)

* Update callback function prototype to align with definition
* Suppress unused function pointer parameter

---------

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
Co-authored-by: Ubuntu <ubuntu@ip-172-31-34-245.ap-northeast-1.compute.internal>
Co-authored-by: GitHub Action <action@github.com>
Co-authored-by: Rahul Kar <118818625+kar-rahul-aws@users.noreply.github.com>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
Co-authored-by: Gaurav Aggarwal <aggarg@amazon.com>
2 years agoAdd description about overrun warning in queue.c (#869)
chinglee-iot [Thu, 7 Dec 2023 09:52:21 +0000 (17:52 +0800)]
Add description about overrun warning in queue.c (#869)

* Add description about overrun warning in queue.c

* Remove the unreachable configASSERT

* Code review suggestions

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
* Fix formatting

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
---------

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
Co-authored-by: Ubuntu <ubuntu@ip-172-31-34-245.ap-northeast-1.compute.internal>
Co-authored-by: Soren Ptak <ptaksoren@gmail.com>
Co-authored-by: Rahul Kar <118818625+kar-rahul-aws@users.noreply.github.com>
Co-authored-by: Gaurav Aggarwal <aggarg@amazon.com>
2 years agoDeclare variable without initializer (#841)
Rahul Kar [Thu, 7 Dec 2023 09:26:44 +0000 (14:56 +0530)]
Declare variable without initializer (#841)

Co-authored-by: Soren Ptak <ptaksoren@gmail.com>
Co-authored-by: chinglee-iot <61685396+chinglee-iot@users.noreply.github.com>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
2 years agoFix MISRA C 2012 rule 8.6 errors (#862)
chinglee-iot [Thu, 7 Dec 2023 08:53:02 +0000 (16:53 +0800)]
Fix MISRA C 2012 rule 8.6 errors (#862)

* Fix MISRA C 2012 rule 8.6 errors

* Add suppression for hook function

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
---------

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
Co-authored-by: Ubuntu <ubuntu@ip-172-31-34-245.ap-northeast-1.compute.internal>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
Co-authored-by: Gaurav Aggarwal <aggarg@amazon.com>
2 years agoFix MISRA_C_2012 rule 13.2 violation (#855)
Rahul Kar [Thu, 7 Dec 2023 06:45:09 +0000 (12:15 +0530)]
Fix MISRA_C_2012 rule 13.2 violation (#855)

* Assign volatile variables to local non-volatile variables before read

* Fix stack macro overflow check volatile access

* Explicit the read order of volatile variable

* Fix issue : ISO C90 forbids mixed declarations and code

---------

Co-authored-by: Ubuntu <ubuntu@ip-172-31-34-245.ap-northeast-1.compute.internal>
Co-authored-by: chinglee-iot <61685396+chinglee-iot@users.noreply.github.com>
Co-authored-by: Monika Singh <moninom@amazon.com>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
2 years agoFix MISRA_C_2012 rule 8.4 violation (#844)
Rahul Kar [Thu, 7 Dec 2023 05:57:50 +0000 (11:27 +0530)]
Fix MISRA_C_2012 rule 8.4 violation (#844)

Fix MISRA_C_2012 rule 8.4 violation

2 years agoAdd parameter name for function type (#845)
Rahul Kar [Wed, 6 Dec 2023 16:23:52 +0000 (21:53 +0530)]
Add parameter name for function type (#845)

Co-authored-by: chinglee-iot <61685396+chinglee-iot@users.noreply.github.com>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
2 years agoFix MISRA_C_2012 rule 7.2 violation (#842)
Rahul Kar [Wed, 6 Dec 2023 16:07:52 +0000 (21:37 +0530)]
Fix MISRA_C_2012 rule 7.2 violation (#842)

* Add a u or U suffix for unsigned numerical literals

* Fix formatting

* Replace u with U for naming convention

---------

Co-authored-by: Soren Ptak <ptaksoren@gmail.com>
Co-authored-by: chinglee-iot <61685396+chinglee-iot@users.noreply.github.com>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
2 years agoFix MISRA_C_2012 rule 17.7 violation (#848)
Rahul Kar [Wed, 6 Dec 2023 11:03:18 +0000 (16:33 +0530)]
Fix MISRA_C_2012 rule 17.7 violation (#848)

* Assign return value of xPortStartScheduler API to a variable

* Add void datatype

---------

Co-authored-by: chinglee-iot <61685396+chinglee-iot@users.noreply.github.com>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
2 years agoFix MISRA_C_2012 rule 20.7 violation (#843)
Rahul Kar [Wed, 6 Dec 2023 08:27:10 +0000 (13:57 +0530)]
Fix MISRA_C_2012 rule 20.7 violation (#843)

* Wrap macro parameter expansion by parentheses
* Update parentheses in SMP macro definition

---------

Co-authored-by: Soren Ptak <ptaksoren@gmail.com>
Co-authored-by: Monika Singh <moninom@amazon.com>
Co-authored-by: chinglee-iot <61685396+chinglee-iot@users.noreply.github.com>
2 years agoSuppress MISRA C:2012 rule 11.5 deviations (#878)
chinglee-iot [Wed, 6 Dec 2023 01:51:52 +0000 (09:51 +0800)]
Suppress MISRA C:2012 rule 11.5 deviations (#878)

* Suppress MISRA C:2012 rule 11.5 deviations by comment also remove this rule in global config

---------

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
Co-authored-by: Ubuntu <ubuntu@ip-172-31-34-245.ap-northeast-1.compute.internal>
Co-authored-by: Rahul Kar <karahulx@amazon.com>
Co-authored-by: Soren Ptak <ptaksoren@gmail.com>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
Co-authored-by: Gaurav Aggarwal <aggarg@amazon.com>
2 years agoUpdate xTaskGetIdleTaskHandle() For SMP (#868)
Darian [Tue, 5 Dec 2023 06:31:11 +0000 (14:31 +0800)]
Update xTaskGetIdleTaskHandle() For SMP (#868)

* Update xTaskGetIdleTaskHandle() in SMP

This commit updates xTaskGetIdleTaskHandle() for SMP in the following ways:

- xTaskGetIdleTaskHandle() no longer accepts xCoreID argument in SMP so that
there is not change in API between single-core and SMP
- xTaskGetIdleTaskHandle() now returns the Active idle task handle in SMP,
which matches the behavior in single-core.
- Added xTaskGetIdleTaskHandleForCore() in SMP which accepts an xCoreID
argument. This function can be used to obtain the Passive idle task handles.

* Update xTaskGetIdleTaskHandle

---------

Co-authored-by: Ching-Hsin Lee <chinglee@amazon.com>
Co-authored-by: chinglee-iot <61685396+chinglee-iot@users.noreply.github.com>
Co-authored-by: Rahul Kar <118818625+kar-rahul-aws@users.noreply.github.com>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
2 years agoAdd SMP template port and example (#900)
chinglee-iot [Mon, 4 Dec 2023 02:49:41 +0000 (10:49 +0800)]
Add SMP template port and example (#900)

* Add SMP template port and example
* Add readme file for smp configuration
* Update SMP build flow and add CI build

---------

Co-authored-by: Soren Ptak <ptaksoren@gmail.com>
Co-authored-by: Rahul Kar <118818625+kar-rahul-aws@users.noreply.github.com>
2 years agoFix prototype of MPU_vTimerSetReloadMode (#913)
Rahul Kar [Thu, 30 Nov 2023 00:17:56 +0000 (05:47 +0530)]
Fix prototype of MPU_vTimerSetReloadMode (#913)

2 years agoFix typo in comment (#910)
Legend [Wed, 29 Nov 2023 15:32:30 +0000 (23:32 +0800)]
Fix typo in comment (#910)

Co-authored-by: Tony Josi <tonyjosi@amazon.com>
Co-authored-by: Soren Ptak <ptaksoren@gmail.com>
Co-authored-by: Rahul Kar <118818625+kar-rahul-aws@users.noreply.github.com>
Co-authored-by: Nikhil Kamath <110539926+amazonKamath@users.noreply.github.com>
2 years agoAdd portMEMORY_BARRIER() to RX MCU ports (#864)
Soren Ptak [Wed, 29 Nov 2023 10:22:16 +0000 (05:22 -0500)]
Add portMEMORY_BARRIER() to RX MCU ports (#864)

* Add portMEMORY_BARRIER() to RX MCU ports

* Remove the memory barrier from the SH2A_FPU portable directory

---------

Co-authored-by: Rahul Kar <118818625+kar-rahul-aws@users.noreply.github.com>
2 years agoUpgrade msvc port to winsock2 (#895)
Soren Ptak [Tue, 28 Nov 2023 20:16:16 +0000 (15:16 -0500)]
Upgrade msvc port to winsock2 (#895)

* Add the changes needed to the MSVC windows port to get it to build with winsock2.h
* Rely upon the WIN32_LEAN_AND_MEAN define to include winsock2.h

2 years agoRevert Portable/Renesas formatting (#876)
Soren Ptak [Tue, 28 Nov 2023 18:56:15 +0000 (13:56 -0500)]
Revert Portable/Renesas formatting (#876)

* Revert the formatting on Renesas ports

2 years agoCoverity Report Directory Fix (#909)
Rahul Kar [Tue, 28 Nov 2023 13:46:15 +0000 (19:16 +0530)]
Coverity Report Directory Fix (#909)

* Revert "The curl command to send the report expects the tar file to be in its current directory. The step either needed to have the working-directory: set to the build directory, or the tar file needs to be created in the parent directory. (#903)"

This reverts commit 76f3aa5b05e5c38e423e83eea23f5b34c15d3316.

* Update to separate build and upload steps

---------

Co-authored-by: tony-josi-aws <tonyjosi@amazon.com>
2 years agoSuppress MISRA C rule 11.3 in MISRA.md (#857)
chinglee-iot [Tue, 28 Nov 2023 13:34:29 +0000 (21:34 +0800)]
Suppress MISRA C rule 11.3 in MISRA.md (#857)

Suppress MISRA C rule 11.3 in MISRA.md

2 years agoFix MISRA 2012 Rule 10.8 violation (#853)
chinglee-iot [Tue, 28 Nov 2023 11:34:13 +0000 (19:34 +0800)]
Fix MISRA 2012 Rule 10.8 violation (#853)

Co-authored-by: Ubuntu <ubuntu@ip-172-31-34-245.ap-northeast-1.compute.internal>
Co-authored-by: Rahul Kar <118818625+kar-rahul-aws@users.noreply.github.com>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
2 years agoFix MISRA 2012 rule 10.4 violations (#852)
chinglee-iot [Tue, 28 Nov 2023 11:21:03 +0000 (19:21 +0800)]
Fix MISRA 2012 rule 10.4 violations (#852)

Fix MISRA 2012 rule 10.4 violations

2 years agoFix MISRA C 2012 Rule 10.3 errors (#860)
chinglee-iot [Tue, 28 Nov 2023 05:29:07 +0000 (13:29 +0800)]
Fix MISRA C 2012 Rule 10.3 errors (#860)

* The value of an expression shall not be assigned to an object with a narrower essential type or of a different essential type category.
---------

Co-authored-by: Ubuntu <ubuntu@ip-172-31-34-245.ap-northeast-1.compute.internal>
Co-authored-by: Rahul Kar <118818625+kar-rahul-aws@users.noreply.github.com>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
2 years agoThe curl command to send the report expects the tar file to be in its current directo...
Soren Ptak [Tue, 28 Nov 2023 05:08:57 +0000 (00:08 -0500)]
The curl command to send the report expects the tar file to be in its current directory. The step either needed to have the working-directory: set to the build directory, or the tar file needs to be created in the parent directory. (#903)

Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
2 years agoCoverity scan and upload in single step (#902)
Tony Josi [Mon, 27 Nov 2023 03:50:41 +0000 (09:20 +0530)]
Coverity scan and upload in single step (#902)

2 years agoNot to use object modified in the loop body (#861)
chinglee-iot [Fri, 24 Nov 2023 06:08:34 +0000 (14:08 +0800)]
Not to use object modified in the loop body (#861)

Co-authored-by: Ubuntu <ubuntu@ip-172-31-34-245.ap-northeast-1.compute.internal>
Co-authored-by: Rahul Kar <118818625+kar-rahul-aws@users.noreply.github.com>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
2 years agoCoverity Scan Workflow Fix (#891)
Soren Ptak [Thu, 23 Nov 2023 16:47:31 +0000 (08:47 -0800)]
Coverity Scan Workflow Fix (#891)

Currently the Coverity Scan attempts to run on every fork that pulls
the file. This leads to anybody who pulls this file getting emails that
their workflow failed to run when the cron job attempts to run. This
PR sets the scan to only run if the repo is FreeRTOS/FreeRTOS-Kernel.
Also, change the scan from a cron job to a job that runs on a commit
to mainline, or if triggered manually.

2 years agoRevert Portable/WizC Formatting (#888)
Soren Ptak [Thu, 23 Nov 2023 12:04:07 +0000 (04:04 -0800)]
Revert Portable/WizC Formatting (#888)

* Revert formatting on WizC ports

* Fix spelling mistakes

---------

Co-authored-by: Rahul Kar <118818625+kar-rahul-aws@users.noreply.github.com>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
2 years agoRevert formatting on Tasking ports (#887)
Soren Ptak [Thu, 23 Nov 2023 11:51:23 +0000 (03:51 -0800)]
Revert formatting on Tasking ports (#887)

Co-authored-by: Rahul Kar <118818625+kar-rahul-aws@users.noreply.github.com>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
2 years agoRevert Portable/Softune Formatting (#886)
Soren Ptak [Thu, 23 Nov 2023 11:39:28 +0000 (03:39 -0800)]
Revert Portable/Softune Formatting (#886)

* Revert formatting on Softune ports

* Fix spelling mistakes

---------

Co-authored-by: Rahul Kar <118818625+kar-rahul-aws@users.noreply.github.com>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
2 years agoRevert formatting on SDCC ports (#885)
Soren Ptak [Thu, 23 Nov 2023 11:14:36 +0000 (03:14 -0800)]
Revert formatting on SDCC ports (#885)

Co-authored-by: Rahul Kar <118818625+kar-rahul-aws@users.noreply.github.com>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
2 years agoRevert formatting on Rowley ports (#884)
Soren Ptak [Thu, 23 Nov 2023 10:53:55 +0000 (02:53 -0800)]
Revert formatting on Rowley ports (#884)

Co-authored-by: Rahul Kar <118818625+kar-rahul-aws@users.noreply.github.com>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
2 years agoRevert Portable/MPLAB Formatting (#883)
Soren Ptak [Thu, 23 Nov 2023 10:29:40 +0000 (02:29 -0800)]
Revert Portable/MPLAB Formatting (#883)

* Revert the formatting PR

* Fix spelling mistakes

---------

Co-authored-by: Rahul Kar <118818625+kar-rahul-aws@users.noreply.github.com>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
2 years agoRevert the formatting changes on MikroC ports. (#882)
Soren Ptak [Thu, 23 Nov 2023 10:20:15 +0000 (02:20 -0800)]
Revert the formatting changes on MikroC ports. (#882)

Co-authored-by: Rahul Kar <118818625+kar-rahul-aws@users.noreply.github.com>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
2 years agoRevert formatting on CCS port files (#881)
Soren Ptak [Thu, 23 Nov 2023 10:09:09 +0000 (02:09 -0800)]
Revert formatting on CCS port files (#881)

Co-authored-by: Rahul Kar <118818625+kar-rahul-aws@users.noreply.github.com>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
2 years agoUpdate system call entry mechanism (#898)
Gaurav-Aggarwal-AWS [Thu, 23 Nov 2023 05:17:47 +0000 (10:47 +0530)]
Update system call entry mechanism (#898)

Earlier the System Call entry from an unprivileged task
looked like:

1. SVC for entering system call.
2. System call implementation.
3. SVC for exiting system call.

Now, the system call entry needs to make only one SVC
call and everything else is handled internally.

This PR also makes the following changes:

1. Update the Access Control List (ACL) mechanism to
    grant access to all the kernel objects before the
    scheduler is started.
2. Add one struct param for system calls with 5 parameters.
    This removes the need for special handling for system
    calls with 5 parameters.
3. Remove raise privilege SVC when MPU wrapper v2 is used.
4. Add additional run time parameter checks to MPU wrappers
    for xTaskGenericNotify and xQueueTakeMutexRecursive APIs.

2 years agofix IAR/CM0/portmacro.h missing semicolon (#894)
Ha Thach [Sat, 18 Nov 2023 08:01:50 +0000 (15:01 +0700)]
fix IAR/CM0/portmacro.h missing semicolon (#894)

Co-authored-by: Rahul Kar <118818625+kar-rahul-aws@users.noreply.github.com>
2 years agoIn smp, every core has a idle task. (#893)
Moral-Hao [Thu, 16 Nov 2023 19:53:27 +0000 (03:53 +0800)]
In smp, every core has a idle task. (#893)

Co-authored-by: chinglee-iot <61685396+chinglee-iot@users.noreply.github.com>
2 years agoAdd vApplicationGetPassiveIdleTaskMemory for SMP (#890)
chinglee-iot [Thu, 16 Nov 2023 01:04:05 +0000 (09:04 +0800)]
Add vApplicationGetPassiveIdleTaskMemory for SMP (#890)

* Update vApplicationGetIdleTaskMemory prototype for SMP. Now SMP and
  single core use the same prototype for compatibility.
* Add vApplicationGetPassiveIdleTaskMemory for SMP to get passive idle
  task memory.