Skip to content

Commit a1471c9

Browse files
authored
Merge branch 'main' into fix/smp-preemption-disable-yield-pending
2 parents 47691e6 + 129b09f commit a1471c9

126 files changed

Lines changed: 14918 additions & 3912 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/.cSpellWords.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -433,6 +433,7 @@ LDRAS
433433
ldrb
434434
ldrbs
435435
LDRBS
436+
ldrex
436437
LDRNE
437438
ldsr
438439
ldxr

.github/scripts/kernel_checker.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
#/*
33
# * FreeRTOS Kernel <DEVELOPMENT BRANCH>
44
# * Copyright (C) 2024 Amazon.com, Inc. or its affiliates. All Rights Reserved.
5+
# * Copyright 2026 Arm Limited and/or its affiliates <open-source-office@arm.com>
56
# *
67
# * SPDX-License-Identifier: MIT
78
# *
@@ -157,9 +158,10 @@
157158

158159

159160
FREERTOS_COPYRIGHT_REGEX = r"^(;|#)?( *(\/\*|\*|#|\/\/))? Copyright \(C\) 20\d\d Amazon.com, Inc. or its affiliates. All Rights Reserved\.( \*\/)?$"
161+
ARM_COLLAB_YEAR_REGEX = r"20\d\d(?:-20\d\d|, 20\d\d)?"
160162

161163
FREERTOS_ARM_COLLAB_COPYRIGHT_REGEX = r"(^(;|#)?( *(\/\*|\*|#|\/\/))? Copyright \(C\) 20\d\d Amazon.com, Inc. or its affiliates. All Rights Reserved\.( \*\/)?$)|" + \
162-
r"(^(;|#)?( *(\/\*|\*|#|\/\/))? Copyright 20\d\d(-20\d\d)? Arm Limited and/or its affiliates( +<open-source-office@arm\.com>)?( \*\/)?$)|" + \
164+
rf"(^(;|#)?( *(\/\*|\*|#|\/\/))? Copyright { ARM_COLLAB_YEAR_REGEX } Arm Limited and/or its affiliates( +<open-source-office@arm\.com>)?( \*\/)?$)|" + \
163165
r"(^(;|#)?( *(\/\*|\*|#|\/\/))? Copyright \(c\) 20\d\d(-20\d\d)? Arm Technology \(China\) Co., Ltd.All Rights Reserved\.( \*\/)?$)|" + \
164166
r"(^(;|#)?( *(\/\*|\*|#|\/\/))? <open-source-office@arm\.com>( \*\/)?$)"
165167

.github/workflows/auto-release.yml

Lines changed: 105 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,8 @@ on:
1919
jobs:
2020
release-packager:
2121
permissions:
22+
contents: write
23+
pull-requests: write
2224
id-token: write
2325
name: Release Packager
2426
runs-on: ubuntu-latest
@@ -31,6 +33,16 @@ jobs:
3133
env:
3234
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
3335

36+
- name: Install GitHub CLI
37+
run: |
38+
command -v gh >/dev/null 2>&1 || {
39+
curl -fsSL https://cli.github.com/packages/githubcli-archive-keyring.gpg | sudo dd of=/usr/share/keyrings/githubcli-archive-keyring.gpg
40+
sudo chmod go+r /usr/share/keyrings/githubcli-archive-keyring.gpg
41+
echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/githubcli-archive-keyring.gpg] https://cli.github.com/packages stable main" | sudo tee /etc/apt/sources.list.d/github-cli.list > /dev/null
42+
sudo apt update
43+
sudo apt install gh
44+
}
45+
3446
# Currently FreeRTOS/.github/scripts houses the release script. Download it for upcoming usage
3547
- name: Checkout FreeRTOS Release Tools
3648
uses: actions/checkout@v4.1.1
@@ -52,15 +64,23 @@ jobs:
5264
git config --global user.name "$ACTOR"
5365
git config --global user.email "$ACTOR"@users.noreply.github.com
5466
55-
- name: create a new branch that references commit id
67+
- name: Create version branch
5668
env:
5769
VERSION_NUMBER: ${{ github.event.inputs.version_number }}
5870
COMMIT_ID: ${{ github.event.inputs.commit_id }}
5971
working-directory: ./local_kernel
6072
run: |
6173
git checkout -b "$VERSION_NUMBER" "$COMMIT_ID"
74+
git push -u origin "$VERSION_NUMBER"
6275
echo "COMMIT_SHA_1=$(git rev-parse HEAD)" >> $GITHUB_ENV
6376
77+
- name: Create release preparation branch
78+
env:
79+
VERSION_NUMBER: ${{ github.event.inputs.version_number }}
80+
working-directory: ./local_kernel
81+
run: |
82+
git checkout -b "release-prep-$VERSION_NUMBER"
83+
6484
- name: Update source files with version info
6585
env:
6686
VERSION_NUMBER: ${{ github.event.inputs.version_number }}
@@ -73,37 +93,100 @@ jobs:
7393
./tools/.github/scripts/update_src_version.py FreeRTOS --kernel-repo-path=local_kernel --kernel-commit="$COMMIT_SHA_1" --new-kernel-version="$VERSION_NUMBER" --new-kernel-main-br-version="$MAIN_BR_VERSION_NUMBER"
7494
exit $?
7595
76-
- name : Update version number in manifest.yml
96+
- name: Update version number in manifest.yml
7797
env:
7898
VERSION_NUMBER: ${{ github.event.inputs.version_number }}
7999
working-directory: ./local_kernel
80100
run: |
81101
./.github/scripts/manifest_updater.py -v "$VERSION_NUMBER"
82102
exit $?
83103
84-
- name : Commit version number change in manifest.yml
104+
- name: Commit and push release preparation branch
85105
env:
86106
VERSION_NUMBER: ${{ github.event.inputs.version_number }}
87107
working-directory: ./local_kernel
88108
run: |
109+
# The update_src_version.py script detaches HEAD by checking out a SHA.
110+
# Re-attach HEAD to the release prep branch, keeping all commits.
111+
git branch -f "release-prep-$VERSION_NUMBER" HEAD
112+
git checkout "release-prep-$VERSION_NUMBER"
113+
89114
git add .
90-
git commit -m '[AUTO][RELEASE]: Update version number in manifest.yml'
91-
git push -u origin "$VERSION_NUMBER"
115+
if git diff --cached --quiet; then
116+
echo "No new changes to commit — source files and manifest already up to date."
117+
else
118+
git commit -m '[AUTO][RELEASE]: Update version number in manifest.yml and source files'
119+
fi
120+
git push -u origin "release-prep-$VERSION_NUMBER"
121+
122+
- name: Create pull request
123+
env:
124+
VERSION_NUMBER: ${{ github.event.inputs.version_number }}
125+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
126+
REPO_FULL_NAME: ${{ github.repository }}
127+
working-directory: ./local_kernel
128+
run: |
129+
PR_URL=$(gh pr create \
130+
--repo "$REPO_FULL_NAME" \
131+
--base "$VERSION_NUMBER" \
132+
--head "release-prep-$VERSION_NUMBER" \
133+
--title "[AUTO][RELEASE]: Release $VERSION_NUMBER" \
134+
--body "Automated release preparation for $VERSION_NUMBER. Updates version numbers in source files and manifest.yml.")
135+
echo "PR_URL=$PR_URL" >> $GITHUB_ENV
136+
137+
- name: Wait for PR to be merged
138+
env:
139+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
140+
REPO_FULL_NAME: ${{ github.repository }}
141+
working-directory: ./local_kernel
142+
run: |
143+
PR_NUMBER=$(echo "$PR_URL" | grep -oE '[0-9]+$')
144+
while true; do
145+
STATE=$(gh pr view "$PR_NUMBER" --repo "$REPO_FULL_NAME" --json state --jq .state)
146+
if [ "$STATE" = "MERGED" ]; then
147+
echo "PR merged successfully"
148+
break
149+
elif [ "$STATE" = "CLOSED" ]; then
150+
echo "Error: PR was closed without merging"
151+
exit 1
152+
fi
153+
echo "Waiting for PR to be merged... (current state: $STATE)"
154+
sleep 30
155+
done
156+
157+
- name: Re-checkout after merge
158+
uses: actions/checkout@v4.1.1
159+
with:
160+
path: local_kernel
161+
ref: ${{ github.event.inputs.version_number }}
162+
fetch-depth: 0
92163

93164
- name: Generate SBOM
94165
uses: FreeRTOS/CI-CD-Github-Actions/sbom-generator@main
95166
with:
96-
repo_path: ./local_kernel
97-
source_path: ./
167+
directory: ./local_kernel
168+
distribution-type: repository
169+
creator: Amazon Web Services, Inc.
170+
download-location: git+https://github.com/${{ github.repository_owner }}/${{ github.event.repository.name }}.git@${{ github.event.inputs.version_number }}
171+
homepage: https://github.com/${{ github.repository_owner }}/${{ github.event.repository.name }}
172+
namespace-prefix: https://github.com/${{ github.repository_owner }}/${{ github.event.repository.name }}/releases/download/V${{ github.event.inputs.version_number }}/
173+
include-file-hashes: true
98174

99-
- name: commit SBOM file
175+
- name: Commit SBOM file
100176
env:
101177
VERSION_NUMBER: ${{ github.event.inputs.version_number }}
102-
working-directory: ./local_kernel
178+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
103179
run: |
180+
# SBOM generator writes files to the workspace root — copy them into the repo
181+
cp *SPDX* ./local_kernel/ 2>/dev/null || cp *spdx* ./local_kernel/ 2>/dev/null || true
182+
cd ./local_kernel
104183
git add .
105-
git commit -m '[AUTO][RELEASE]: Update SBOM'
106-
git push -u origin "$VERSION_NUMBER"
184+
if git diff --cached --quiet; then
185+
echo "No SBOM changes to commit."
186+
else
187+
git commit -m '[AUTO][RELEASE]: Update SBOM'
188+
git push -u origin "$VERSION_NUMBER"
189+
fi
107190
echo "COMMIT_SHA_2=$(git rev-parse HEAD)" >> $GITHUB_ENV
108191
109192
- name: Release
@@ -125,12 +208,19 @@ jobs:
125208
# This is dependent on the release script putting this zip file
126209
# in this exact location.
127210
artifact_path: ./FreeRTOS-KernelV${{ github.event.inputs.version_number }}.zip
128-
release_tag: ${{ github.event.inputs.version_number }}
211+
release_tag: V${{ github.event.inputs.version_number }}
129212

130-
- name: Cleanup
213+
- name: Delete release preparation branch
214+
if: always()
131215
env:
132216
VERSION_NUMBER: ${{ github.event.inputs.version_number }}
217+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
133218
working-directory: ./local_kernel
134219
run: |
135-
# Delete the branch created for Tag by SBOM generator
136-
git push -u origin --delete "$VERSION_NUMBER"
220+
# Only delete release-prep branch if the PR was already merged
221+
PR_STATE=$(gh pr list --repo "${{ github.repository }}" --head "release-prep-$VERSION_NUMBER" --json state --jq '.[0].state' 2>/dev/null || echo "")
222+
if [ "$PR_STATE" = "MERGED" ] || [ -z "$PR_STATE" ]; then
223+
git push origin --delete "release-prep-$VERSION_NUMBER" || true
224+
else
225+
echo "Skipping release-prep branch deletion — PR is still open (state: $PR_STATE)"
226+
fi

History.txt

Lines changed: 115 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,120 @@
11
Documentation and download available at https://www.FreeRTOS.org/
22

3+
Changes between FreeRTOS V11.2.0 and FreeRTOS V11.3.0 released March 2026
4+
5+
+ Correct minor mistakes in code comments in event_groups.c, include/queue.h,
6+
and include/task.h. We thank @wirelinker for their contribution.
7+
+ Add Arm China STAR-MC3 port support. We thank @cpussw01 for their
8+
contribution.
9+
+ Add Memory Protection Unit (MPU) support to the ARM Cortex-R82 port. We
10+
thank @AhmedIsmail02 for their contribution.
11+
+ Add ARM Cortex-M52 port support for GCC and IAR compilers. We thank
12+
@Armchina_JidongMei for their contribution.
13+
+ Add ARM Cortex-R82 non-MPU port for ARMv8-R AArch64 with SMP support. We
14+
thank @AhmedIsmail02 for their contribution.
15+
+ Add Floating Point Unit (FPU) context save support to the RISC-V port.
16+
We thank @cubidesj for their contribution.
17+
+ Add Vector context save support to the RISC-V port. We thank @cubidesj
18+
for their contribution.
19+
+ Add xPortIsInsideInterrupt API to the RP2040 port to match other ARM
20+
ports. We thank @graham-sanderson for their contribution.
21+
+ Add catch up behavior documentation to xTaskDelayUntil API to explain
22+
frequency breaks when catching up for past events.
23+
+ Add asserts to check for stack overflow at task creation time.
24+
+ Add assert to check for overflow in xStreamBufferSendFromISR API.
25+
+ Add assert to check for overflow of recursive mutex counter. We thank
26+
@InnerSteff for their contribution.
27+
+ Add CFI frame unwind information in portable/IAR/RXv2/port_asm.s to
28+
enable debugger callstack display beyond __interrupt_27. We thank
29+
@bernd-edlinger for their contribution.
30+
+ Update xTaskDelayUntil to be the preferred delay function in the
31+
FreeRTOSConfig.h template.
32+
+ Update RISC-V port to use saved mstatus for FPU/VPU state determination
33+
instead of re-reading after writes, addressing specification-compliant
34+
implementations where FS field may change to Dirty.
35+
+ Update RISC-V port to refine vector context layout on stack for proper
36+
register ordering. We thank @Saiiijchan for their contribution.
37+
+ Update RISC-V port to refine FPU register context offset calculation. We
38+
thank @Saiiijchan for their contribution.
39+
+ Update RISC-V port to use UBaseType_t for ullMachineTimerCompareRegisterBase
40+
to resolve warnings on 32-bit platforms.
41+
+ Update FreeRTOS MPU to remove the assertion and runtime check enforcing
42+
matching between configTOTAL_MPU_REGIONS and physical MPU regions,
43+
allowing applications to manage a subset of available regions. We thank
44+
@ErickReyesR for their contribution.
45+
+ Update ARM_CRx_No_GIC port to set Data endianness bit in SPSR register
46+
for big-endian compilation. We thank @maximdeclercq00 for their
47+
contribution.
48+
+ Update Win32 port to guard timeapi.h include for MinGW compatibility and
49+
add compiler-specific headers for cross-compiler support. We thank
50+
@nordync for their contribution.
51+
+ Update Win32 port to move Windows headers to port.c to prevent inclusion
52+
of windows.h in all header files and avoid macro conflicts. We thank
53+
@creiter64 for their contribution.
54+
+ Update POSIX port to delete thread key on process exit instead of in
55+
xPortStartScheduler to ensure proper cleanup of thread-specific memory.
56+
+ Update POSIX port to fix race condition in vPortEndScheduler by moving
57+
scheduler thread signal after FreeRTOS thread check. We thank
58+
@arctic-alpaca for their contribution.
59+
+ Update RP2040 port to fix use of deprecated volatile semantics for C++20
60+
compatibility. We thank @mathiasgredal for their contribution.
61+
+ Update RP2040 port to propagate PICO_SDK_VERSION_* to parent scope in
62+
CMake. We thank @shengtai25 for their contribution.
63+
+ Update RP2040 port to remove unused code and preprocessor directives. We
64+
thank @pascalr for their contribution.
65+
+ Update RL78 port to fix incorrect register image for pvParameters in FAR
66+
data model for IAR compiler. We thank @sauleThsQuin for their
67+
contribution.
68+
+ Update RL78 port to fix compilation failure on portasm.s file due to
69+
indentation on ASM macro. We thank @5iBri for their contribution.
70+
+ Update ARM_CRx_MPU port to add LLVM assembler compatibility by
71+
explicitly specifying section flags. We thank @malsyned for their
72+
contribution.
73+
+ Update Cortex-M ports to rename ulStackFrameSize to
74+
ulHardwareSavedExceptionFrameSize for improved readability. We thank
75+
@AhmedIsmail02 for their contribution.
76+
+ Update MPLAB PIC32MZ-EF port to add assert to catch register overflow.
77+
We thank @mrluzeiro for their contribution.
78+
+ Update comments related to taskYIELD in queue.h. We thank @Saiiijchan
79+
for their contribution.
80+
+ Fix priority disinheritance in vTaskPriorityDisinheritAfterTimeout to
81+
reset the correct priority when the task disinheriting timeout was the
82+
only task at that priority.
83+
+ Fix event groups to remove direct mapping of xEventGroupClearBitsFromISR
84+
and xEventGroupSetBitsFromISR to xTimerPendFunctionCallFromISR,
85+
resolving redefinition warnings. We thank @AhmedIsmail02 for their
86+
contribution.
87+
+ Fix datatype of queue item length macros from uint8_t to UBaseType_t to
88+
match API parameter types.
89+
+ Fix possible NULL pointer dereference after configASSERT() calls in
90+
queue.c and stream_buffer.c. We thank @Florian.LaRoche for their
91+
contribution.
92+
+ Fix Win32 port to prevent SetWaitableTimer() call from being ignored
93+
when configASSERT expands to nothing. We thank @kim-schwaner for their
94+
contribution.
95+
+ Fix compiler warnings from gcc -Wconversion. We thank @Florian.LaRoche
96+
for their contribution.
97+
+ Fix compiler warning about gcc -Wwrite-strings in POSIX port. We thank
98+
@Florian.LaRoche for their contribution.
99+
+ Fix set but unused variable warning in pxPortInitialiseStack. We thank
100+
@razrbro for their contribution.
101+
+ Fix missing include to resolve compile error. We thank @mike919192 for
102+
their contribution.
103+
+ Fix missing cast to BaseType_t.
104+
+ Fix cast in stack allocation for task creation for negative
105+
portSTACK_GROWTH. We thank @sidharthseela for their contribution.
106+
+ Fix missing macro guards in task.h to prevent unintended API access. We
107+
thank @SoniHarsh1 for their contribution.
108+
+ Fix CMake build for GCC_ARM_CRx_MPU by adding to mpu_wrappers patterns.
109+
We thank @malsyned for their contribution.
110+
+ Fix initialization of size_t-type variable by changing macro from
111+
portMAX_DELAY to SIZE_MAX. We thank @duyicheng741 for their
112+
contribution.
113+
+ Define configENABLE_PAC and configENABLE_BTI before including portable.h
114+
to prevent "used before definition" warnings.
115+
+ Remove stray semicolon from gcc-ARM_CRx_MPU port.c. We thank
116+
@Florian.LaRoche for their contribution.
117+
3118
Changes between FreeRTOS V11.1.0 and FreeRTOS V11.2.0 released March 04, 2025
4119

5120
+ Add CC-RH port for Renesas F1Kx devices. We thank @TrongNguyenR for their

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ See the readme file in the ```./portable``` directory for more information.
130130

131131
- The ```./include``` directory contains the real time kernel header files.
132132

133-
- The ```./template_configuration``` directory contains a sample `FreeRTOSConfig.h` to help jumpstart a new project.
133+
- The ```./examples/template_configuration``` directory contains a sample `FreeRTOSConfig.h` to help jumpstart a new project.
134134
See the [FreeRTOSConfig.h](examples/template_configuration/FreeRTOSConfig.h) file for instructions.
135135

136136
### Code Formatting

0 commit comments

Comments
 (0)