Commit Graph

3107 Commits

Author SHA1 Message Date
clemenskresser
7b95420ad9
fixed deadlock in event groups when a mutex is used for memory allocation (#284)
Co-authored-by: Clemens Kresser <clemens.kresser@gmail.com>
Co-authored-by: Joseph Julicher <jjulicher@mac.com>
2021-12-29 09:58:24 -07:00
Joseph Julicher
f5df2c140c
Documentation update for xEventGroupClearBitsFromISR (#432)
* Documented the correct use of xEventGroupClearBitsFromISR

* removed typo
2021-12-28 14:20:33 -07:00
Fabian
481c722ef3
RISC-V: No #error on RV64 regarding byte alignment (#367)
Co-authored-by: Joseph Julicher <jjulicher@mac.com>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
2021-12-28 11:52:33 -08:00
leona
81d15dc550
Fix: Interrut Handler Register Function and Exception Process (#41)
Signed-off-by: shiode <shiode@aptpod.co.jp>

Co-authored-by: Cobus van Eeden <35851496+cobusve@users.noreply.github.com>
Co-authored-by: David Chalco <59750547+dachalco@users.noreply.github.com>
Co-authored-by: Joseph Julicher <jjulicher@mac.com>
2021-12-28 10:54:23 -07:00
Joseph Julicher
455df7a07a
uxAutoReload replaced with xAutoReload to improve MISRA compliance (#429)
* Created xTimerGetReloadMode and uxTimerGetReloadMode.

* Changed the use of uxAutoReload to xAutoReload

* updated history.txt

* Update History.txt

Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>

* Update timers.c

Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>

* Added xTimerGetReloadMode to lexicon.txt

* uncrustified timers.c

* Fix formatting check

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

Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
Co-authored-by: Gaurav Aggarwal <aggarg@amazon.com>
2021-12-27 11:36:59 -07:00
Gaurav-Aggarwal-AWS
53b9a80b8e
Update third party ports readme (#428)
Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
2021-12-21 14:10:06 -08:00
Graham Sanderson
debbd254b6
RP2040 fixes (#424)
* RP2040: malloc needs to be thread safe for FreeRTOS whether both cores are used or not

* RP2040: CMake file had broken left over test code

* RP2040: portIS_FREE_RTOS_CORE() returned an incorrect value prior to scheduler init when the application was compiled without multicore support

* RP2040: Bad initialization code was causing IRQs to get disabled before main() was called when using non static allocation
2021-12-21 11:08:41 -08:00
Pramith K V
4c4089b154
Remove tickless idle mode dependency with include v task suspend (#422)
* Fix Remove tickless idle feature dependency with INCLUDE_vTaskSuspend
* fix unused variable warning
* Fix CI fomatting check

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
Authored-by: pramithkv <pramit@lifesignals.com>
2021-12-08 15:47:07 -08:00
R. Dunbar Poor
052e364686
Fix #415: Compiling tasks.c with configSUPPORT_DYNAMIC_ALLOCATION = 0 (#416)
* Fix #415: Compiling tasks.c with configSUPPORT_DYNAMIC_ALLOCATION = 0
2021-11-18 14:38:41 -08:00
RichardBarry
271bdfb880
Simplify prvInitialiseNewTask() (#417)
Memset newly allocated TCB structures to zero, and remove code
that set individual structure members to zero.
2021-11-18 14:22:02 -08:00
RichardBarry
e13f990385
Fix keil compilation error (#418)
* Fix compilation error when using the Keil tools with the Keil compiler.
2021-11-18 11:04:57 -08:00
Gaurav Aggarwal
6ac9aaec95 Fix formatting error
Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
2021-11-15 15:09:12 -08:00
Gaurav Aggarwal
44fc137428 Add option to disable unprivileged critical sections
This commit introduces a new config
configALLOW_UNPRIVILEGED_CRITICAL_SECTIONS which enables developers to
prevent critical sections from unprivileged tasks. It defaults to 1 for
backward compatibility. Application should set it to 0 to disable
critical sections from unprivileged tasks.

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
2021-11-15 15:09:12 -08:00
Gaurav Aggarwal
7a3848753b Change xPortRaisePrivilege and vPortResetPrivilege to macros
This prevents non-kernel code from calling these functions.

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
2021-11-15 15:09:12 -08:00
Gaurav-Aggarwal-AWS
78da9cb261
Fix code example in timers.h (#412)
The example was trying to create a timer with period 0 which is not a
valid period.

This was reported here - https://forums.freertos.org/t/multiple-timers/13884

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
2021-11-12 10:36:49 -08:00
Laukik Hase
683811bd8c
bugfix: Initialize uxTaskNumber at task initialization (#374)
* bugfix: Initialize uxTaskNumber at task initialization
2021-11-11 14:17:21 -08:00
Tobias Nießen
4896d6b1a1 Mention portMAX_DELAY in xEventGroupWaitBits docs (#411)
The public function xEventGroupWaitBits passes xTicksToWait to the
function vTaskPlaceOnUnorderedEventList, which passes the number of
ticks to prvAddCurrentTaskToDelayedList and sets xCanBlockIndefinitely
to pdTRUE, causing the latter to block indefinitely if
xTicksToWait == portMAX_DELAY and INCLUDE_vTaskSuspend == 1.
2021-11-10 17:39:01 -08:00
Kevin Thibedeau
cd0b7fc271
Build with -Wmissing-prototypes flags vPortYieldFromISR() in the Posix port. (#409)
There's already a portYIELD_FROM_ISR() macro that calls vPortYield() which wraps the FromISR code.
It doesn't appear that vPortYieldFromISR() is intended to be publicly accessible in this port so
I've marked it as private to silence the warning.

event_create() also got flagged due to missing void in prototype.

Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
2021-11-08 13:51:25 -08:00
Gaurav-Aggarwal-AWS
1ec7e50722
Change hyphen to ASCII character (#410)
Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
2021-11-08 11:11:11 -08:00
Gaurav-Aggarwal-AWS
5a2a1d0702
Change taskYIELD_FROM_ISR to portYIELD_FROM_ISR in docs (#408) 2021-11-05 14:33:15 -07:00
prplz
a40d52dc05
Fix documentation mistake (#407)
ulTaskNotification -> ulTaskNotify
2021-11-05 10:55:17 -07:00
andrewtjs
a432a688ca
bugfix: Initialise stack correctly on dsPIC port (#405)
* Use compiler predefined constants.

Use of MPLAB_DSPIC_PORT is deprecated.
2021-11-01 12:38:37 -07:00
Archit Gupta
d649a77128
Fix prvWriteMessageToBuffer on big endian (#391)
prvWriteMessageToBuffer wrote the first sbBYTES_TO_STORE_MESSAGE_LENGTH
bytes of the size_t-typed length to the buffer as the data length. While
this functions on little endian, it copies the wrong bytes on big
endian. This fix converts the length to configMESSAGE_BUFFER_LENGTH_TYPE
first, and then copies the exact amount, thus fixing the issue.
Additionally it adds an assert to verify the size is not greater than
the max value of configMESSAGE_BUFFER_LENGTH_TYPE; previously this would
truncate silently.

Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
2021-10-16 16:36:44 -07:00
Gaurav-Aggarwal-AWS
06fb777e43
Update comments for the ARM_CA53_64_BIT_SRE port (#403)
Mention that FreeRTOS_IRQ_Handler should not be used for FIQs and the
reason for assuming Group 1 for Interrupt Acknowledge and End Of
Interrupt registers.

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
2021-10-16 13:45:03 -07:00
Stephane Viau
68ddb32b55
Handle interrupt acknowledge register in Cortex-A53 SRE port (#392)
Let the FreeRTOS IRQ handler properly store and restore the ICCIAR
register value around the vApplicationIRQHandler() call.

Signed-off-by: Stephane Viau <stephane.viau@oss.nxp.com>

Co-authored-by: Stephane Viau <stephane.viau@oss.nxp.com>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
2021-10-15 09:21:56 -07:00
swaldhoer
a030d0a02b
fix typo (#399) 2021-10-06 15:32:07 -07:00
Qikai
1fb4e847ed
Fix the defect that Heap_1.c may waste first portBYTE_ALIGNMENT bytes of ucHeap[] (#238)
* Fix the defect that Heap_1.c may waste first 8 bytes of ucHeap[]

* Fix the same byte waste issue in heap_2
2021-10-04 11:15:00 -07:00
Andres O. Vela
5f290e4559
Fix typo in comment (#398) 2021-09-30 10:18:47 -07:00
Shubham Kulkarni
741185f1d0
Xtensa_ESP32: Add definition for portMEMORY_BARRIER (#395)
This fixes crash observed in Amazon FreeRTOS when optimisations are enabled
2021-09-16 14:16:22 -07:00
Gaurav-Aggarwal-AWS
1b86b39940
Remove AVR ports from main repo (#394)
These ports now exist in the
https://github.com/FreeRTOS/FreeRTOS-Kernel-Partner-Supported-Ports repo.

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
2021-09-14 19:25:46 -07:00
Gaurav Aggarwal
384ffc5b91 Fix spell-check failure
Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
2021-09-10 16:44:36 -07:00
Gaurav Aggarwal
68889fdd79 Update History.txt
Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
2021-09-10 16:44:36 -07:00
Gaurav Aggarwal
99a5a5fe82 Fix free secure context for Cortex-M23 ports
Update the branching condition to correctly free secure context when
there is one.

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
2021-09-10 16:44:36 -07:00
Gaurav Aggarwal
06ea7275b3 Implement secure stack sealing as per ARM's recommendation
Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
2021-09-10 16:44:36 -07:00
Gaurav Aggarwal
61f7560243 Associate secure context with task handle
The secure side context management code now checks that the secure
context being saved or restored belongs to the task being switched-out
or switched-in respectively.

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
2021-09-10 16:44:36 -07:00
Gaurav Aggarwal
ccaa0f4d6e Pre-allocate secure-side context structures
This commit improves ARMv8-M security by pre-allocating secure-side task
context structures and changing how tasks reference a secure-side
context structure when calling a secure function. The new configuration
constant secureconfigMAX_SECURE_CONTEXTS sets the number of secure
context structures to pre-allocate. secureconfigMAX_SECURE_CONTEXTS
defaults to 8 if left undefined.

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
2021-09-10 16:44:36 -07:00
Zim Kalinowski
f8ada39d85
Replace <pre> with @code - remaining files (#388)
Co-authored-by: Paul Bartell <pbartell@amazon.com>
Co-authored-by: Ming Yue <mingyue86010@gmail.com>
2021-09-07 12:03:12 -07:00
Gaurav-Aggarwal-AWS
fa0f5c436c
Add freertos_risc_v_chip_specific_extensions.h for 64-bit ports (#385)
* Add freertos_risc_v_chip_specific_extensions.h for 64-bit ports

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
2021-09-01 15:38:07 -07:00
Zim Kalinowski
bb02cf647d
minor fix in stream buffer doc (#387)
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
2021-08-31 11:24:56 -07:00
Zim Kalinowski
ae73f0de41
Replace <pre> with @code{c} (#386)
* replace <pre> with @code{c}

* endcode must pass spellcheck
2021-08-31 09:04:36 -07:00
sherryzhang
c290780e34
Update the README to align with TF-Mv1.4.0 in TF-M integration (#384)
Change-Id: I41fc8e18657086e86eacd38ed70f474555739a3c
Signed-off-by: Sherry Zhang <sherry.zhang2@arm.com>
2021-08-26 23:07:58 -07:00
Zim Kalinowski
0b1e9d79c8
fixes in queue documentation (#382)
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
2021-08-12 18:15:57 -07:00
Shubham Kulkarni
6ba8aa63c1
Xtensa_ESP32: Fix build issues when external SPIRAM is enabled (#381)
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
2021-08-12 17:46:25 -07:00
Paul Adelsbach
d858d1ff36
fix example usage of xMessageBufferCreateStatic and xStreamBufferCrea… (#380)
Example usage is actually correct, so remove the -1. but update
the incorrect parameter description for pucStreamBufferStorageArea
and pucMessageBufferStorageArea.
2021-08-12 17:06:41 -07:00
Jack Lam
d01801807d
Tidy up the 8051 sdcc port (#376)
* Tidy up the 8051 sdcc port

* Replace tabs with spaces in SDCC Cygnal port.c file.

Co-authored-by: John Lin <shaojun.lin@delonghigroup.com>
Co-authored-by: Paul Bartell <pbartell@amazon.com>
2021-08-12 11:50:52 -07:00
Zim Kalinowski
1b38078939
fixed parameter names documentation (#378) 2021-08-12 11:18:53 -07:00
RichardBarry
b97bb48e06
Indent contents of a taskENTER_CRITICAL/taskEXIT_CRITICAL block. (#348)
* Indent contents of a taskENTER_CRITICAL/taskEXIT_CRITICAL block.
Move a few configASSERT() statements out of a path where they would always be triggered to prevent "condition is always true" compiler warnings.

* Replace configASSERT() positions due to unintended semantic change from the version where asserts were at the top of the file.

Co-authored-by: RichardBarry <richardbarry.c@gmail.com>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
2021-08-04 10:05:23 -07:00
alfred gedeon
ce81bcb33f
Run uncrustify with github workflows (#369)
* uncrustify with github workflows

* Fix find expression

* Add uncrustify configuration file

* Uncrustify some files

* uncrustify some more files

* uncrustify more files

* Fix whitespace at end of lines

Co-authored-by: Cobus van Eeden <35851496+cobusve@users.noreply.github.com>
2021-07-28 17:53:10 -07:00
Gaurav-Aggarwal-AWS
85a23127cc
Add ReadMe for third party port contributions (#371)
* Add ReadMe for third party port contributions

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
2021-07-28 10:37:51 -07:00
Craig Kewley
d9d5d53a75
doc: fix function name typo (#368) 2021-07-20 17:21:18 -07:00