Skip to content

Commit 88a5316

Browse files
authored
Merge branch 'main' into fix/posix-compat
2 parents 96c227a + 6bf3a75 commit 88a5316

File tree

27 files changed

+1771
-1620
lines changed

27 files changed

+1771
-1620
lines changed

.github/CONTRIBUTING.md

Lines changed: 70 additions & 70 deletions
Original file line numberDiff line numberDiff line change
@@ -1,70 +1,70 @@
1-
# Contribution guidelines
2-
3-
Thank you for your interest in contributing to our project. Whether it's a bug report, new feature, code, or
4-
documentation, we welcome our community to be involved in this project.
5-
6-
Please read through this document before submitting any issues or pull requests to ensure we are able to help you and all members of the community as effectively as possible.
7-
8-
## Code of conduct
9-
This project has adopted the [Amazon Open Source Code of Conduct](https://aws.github.io/code-of-conduct).
10-
For more information see the [Code of Conduct FAQ](https://aws.github.io/code-of-conduct-faq) or contact
11-
[email protected] with any additional questions or comments.
12-
13-
14-
## Security issue notifications
15-
If you discover a potential security issue in this project we ask that you notify AWS/Amazon Security via our [vulnerability reporting page](https://aws.amazon.com/security/vulnerability-reporting/). Please do **not** create a public github issue.
16-
17-
18-
## Submitting a bugs/feature request
19-
Have a bug to report or feature to request? Follow these steps:
20-
1. Search on the [FreeRTOS Community Support Forums](https://forums.freertos.org/) and [GitHub issue tracker](https://github.com/FreeRTOS/FreeRTOS/issues?utf8=%E2%9C%93&q=is%3Aissue) to be sure this hasn't been already reported or discussed.
21-
2. If your search turns up empty, create a new topic in the [forums](https://forums.freertos.org/) and work with the community to help clarify issues or refine the idea. Include as many of the details listed below.
22-
3. Once the community has had time to discuss and digest, we welcome you to create an [issue](https://github.com/FreeRTOS/FreeRTOS/issues) to report bugs or suggest features.
23-
24-
When creating a new topic on the forums or filing an issue, please include as many relevant details as possible. Examples include:
25-
26-
* A clear description of the situation — what you observe, what you expect, and your view on how the two differ.
27-
* A reproducible test case or sequence of steps.
28-
* The version of our code being used.
29-
* Any modifications you've made relevant to the bug.
30-
* Details of your environment or deployment. Highlight anything unusual.
31-
32-
33-
## Contributing via pull request
34-
Contributions via pull requests are much appreciated. Before sending us a pull request, please ensure that:
35-
36-
1. You are working against the latest source on the *master* branch.
37-
2. You check existing open, and recently merged, pull requests to make sure someone else hasn't addressed the problem already.
38-
3. You open an issue to discuss any significant work - we would hate for your time to be wasted.
39-
40-
To send us a pull request, please:
41-
42-
1. Fork the repository.
43-
2. Modify the source; focus on the specific change you are contributing. If you also reformat all the code, it will be hard for us to focus on your change.
44-
3. Follow the [coding style guide](https://www.FreeRTOS.org/FreeRTOS-Coding-Standard-and-Style-Guide.html).
45-
4. Commit to your fork using clear commit messages.
46-
5. Send us a pull request, answering any default questions in the pull request interface.
47-
NOTE: Please make sure the default option (Allow edits from maintainers) is left checked.
48-
6. Pay attention to any automated CI failures reported in the pull request, and stay involved in the conversation.
49-
50-
GitHub provides additional document on [forking a repository](https://help.github.com/articles/fork-a-repo/) and
51-
[creating a pull request](https://help.github.com/articles/creating-a-pull-request/).
52-
53-
## Coding style
54-
* Please ensure that your code complies to the [FreeRTOS coding style guidelines](https://www.FreeRTOS.org/FreeRTOS-Coding-Standard-and-Style-Guide.html).
55-
56-
57-
## Getting your pull request merged
58-
All pull requests must be approved by our review team before it can be merged in. We appreciate your patience while pull requests are reviewed. The time it takes to review will depend on complexity and consideration of wider implications.
59-
60-
61-
## Finding contributions to work on
62-
Looking at the existing issues is a great way to find something to contribute on. As our projects, by default, use the default GitHub issue labels (enhancement/bug/duplicate/help wanted/invalid/question/wontfix), tackling open 'help wanted' issues is a great place to start.
63-
64-
65-
## Licensing
66-
The FreeRTOS kernel is released under the MIT open source license, the text of which can be found [here](https://github.com/FreeRTOS/FreeRTOS/blob/master/FreeRTOS/License/license.txt)
67-
68-
Additional license files can be found in the folders containing any supplementary libraries licensed by their respective copyright owners where applicable.
69-
70-
We may ask you to sign a [Contributor License Agreement (CLA)](https://en.wikipedia.org/wiki/Contributor_License_Agreement) for larger changes.
1+
# Contribution guidelines
2+
3+
Thank you for your interest in contributing to our project. Whether it's a bug report, new feature, code, or
4+
documentation, we welcome our community to be involved in this project.
5+
6+
Please read through this document before submitting any issues or pull requests to ensure we are able to help you and all members of the community as effectively as possible.
7+
8+
## Code of conduct
9+
This project has adopted the [Amazon Open Source Code of Conduct](https://aws.github.io/code-of-conduct).
10+
For more information see the [Code of Conduct FAQ](https://aws.github.io/code-of-conduct-faq) or contact
11+
[email protected] with any additional questions or comments.
12+
13+
14+
## Security issue notifications
15+
If you discover a potential security issue in this project we ask that you notify AWS/Amazon Security via our [vulnerability reporting page](https://aws.amazon.com/security/vulnerability-reporting/). Please do **not** create a public github issue.
16+
17+
18+
## Submitting a bugs/feature request
19+
Have a bug to report or feature to request? Follow these steps:
20+
1. Search on the [FreeRTOS Community Support Forums](https://forums.freertos.org/) and [GitHub issue tracker](https://github.com/FreeRTOS/FreeRTOS/issues?utf8=%E2%9C%93&q=is%3Aissue) to be sure this hasn't been already reported or discussed.
21+
2. If your search turns up empty, create a new topic in the [forums](https://forums.freertos.org/) and work with the community to help clarify issues or refine the idea. Include as many of the details listed below.
22+
3. Once the community has had time to discuss and digest, we welcome you to create an [issue](https://github.com/FreeRTOS/FreeRTOS/issues) to report bugs or suggest features.
23+
24+
When creating a new topic on the forums or filing an issue, please include as many relevant details as possible. Examples include:
25+
26+
* A clear description of the situation — what you observe, what you expect, and your view on how the two differ.
27+
* A reproducible test case or sequence of steps.
28+
* The version of our code being used.
29+
* Any modifications you've made relevant to the bug.
30+
* Details of your environment or deployment. Highlight anything unusual.
31+
32+
33+
## Contributing via pull request
34+
Contributions via pull requests are much appreciated. Before sending us a pull request, please ensure that:
35+
36+
1. You are working against the latest source on the *main* branch.
37+
2. You check existing open, and recently merged, pull requests to make sure someone else hasn't addressed the problem already.
38+
3. You open an issue to discuss any significant work - we would hate for your time to be wasted.
39+
40+
To send us a pull request, please:
41+
42+
1. Fork the repository.
43+
2. Modify the source; focus on the specific change you are contributing. If you also reformat all the code, it will be hard for us to focus on your change.
44+
3. Follow the [coding style guide](https://www.FreeRTOS.org/FreeRTOS-Coding-Standard-and-Style-Guide.html).
45+
4. Commit to your fork using clear commit messages.
46+
5. Send us a pull request, answering any default questions in the pull request interface.
47+
NOTE: Please make sure the default option (Allow edits from maintainers) is left checked.
48+
6. Pay attention to any automated CI failures reported in the pull request, and stay involved in the conversation.
49+
50+
GitHub provides additional document on [forking a repository](https://help.github.com/articles/fork-a-repo/) and
51+
[creating a pull request](https://help.github.com/articles/creating-a-pull-request/).
52+
53+
## Coding style
54+
* Please ensure that your code complies to the [FreeRTOS coding style guidelines](https://www.FreeRTOS.org/FreeRTOS-Coding-Standard-and-Style-Guide.html).
55+
56+
57+
## Getting your pull request merged
58+
All pull requests must be approved by our review team before it can be merged in. We appreciate your patience while pull requests are reviewed. The time it takes to review will depend on complexity and consideration of wider implications.
59+
60+
61+
## Finding contributions to work on
62+
Looking at the existing issues is a great way to find something to contribute on. As our projects, by default, use the default GitHub issue labels (enhancement/bug/duplicate/help wanted/invalid/question/wontfix), tackling open 'help wanted' issues is a great place to start.
63+
64+
65+
## Licensing
66+
The FreeRTOS kernel is released under the MIT open source license, the text of which can be found [here](https://github.com/FreeRTOS/FreeRTOS/blob/main/FreeRTOS/License/license.txt)
67+
68+
Additional license files can be found in the folders containing any supplementary libraries licensed by their respective copyright owners where applicable.
69+
70+
We may ask you to sign a [Contributor License Agreement (CLA)](https://en.wikipedia.org/wiki/Contributor_License_Agreement) for larger changes.

.github/workflows/kernel-checks.yml

Lines changed: 27 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
name: Kernel-Checker
22

3-
on: [pull_request]
3+
on: [push, pull_request]
44

55
jobs:
66
kernel-checker:
@@ -21,7 +21,7 @@ jobs:
2121
uses: actions/checkout@v2
2222
with:
2323
repository: FreeRTOS/FreeRTOS
24-
ref: master
24+
ref: main
2525
path: tools
2626

2727
# Checkout user pull request changes
@@ -45,3 +45,28 @@ jobs:
4545
cd inspect
4646
.github/scripts/kernel_checker.py --json ${HOME}/files_modified.json ${HOME}/files_added.json ${HOME}/files_renamed.json
4747
exit $?
48+
build-checker:
49+
name: FreeRTOS Posix Build Check
50+
runs-on: ubuntu-latest
51+
steps:
52+
- name: Checkout the parent repository
53+
uses: actions/checkout@v2
54+
with:
55+
ref: main
56+
repository: FreeRTOS/FreeRTOS
57+
submodules: 'recursive'
58+
fetch-depth: 1
59+
path: ./workspace
60+
- name: Checkout the current repository
61+
uses: actions/checkout@v2
62+
with:
63+
path: ./workspace/FreeRTOS/Source
64+
- name: Posix Build Checker
65+
run: |
66+
bash workspace/.github/scripts/posix_build_checker.sh workspace
67+
- name: Install lib pcap dev
68+
run: |
69+
sudo apt-get install libpcap-dev
70+
- name: Posix Network Build Checker
71+
run: |
72+
bash workspace/.github/scripts/posix_network_build_checker.sh workspace

.github/workflows/unit-tests.yml

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
name: CMock Unit Tests
2+
on: [push, pull_request]
3+
4+
jobs:
5+
run:
6+
runs-on: ubuntu-latest
7+
steps:
8+
- name: Checkout Parent Repository
9+
uses: actions/checkout@v2
10+
with:
11+
ref: main
12+
repository: FreeRTOS/FreeRTOS
13+
submodules: 'recursive'
14+
fetch-depth: 1
15+
- name: Clone This Repo
16+
uses: actions/checkout@v2
17+
with:
18+
path: ./FreeRTOS/Source
19+
20+
- name: Setup Python
21+
uses: actions/setup-python@master
22+
with:
23+
python-version: 3.8
24+
25+
- name: Install packages
26+
run: |
27+
sudo apt-get install lcov cflow ruby doxygen build-essential
28+
- name: Run Unit Tests with ENABLE_SANITIZER=1
29+
run: |
30+
make -C FreeRTOS/Test/CMock clean
31+
make -C FreeRTOS/Test/CMock ENABLE_SANITIZER=1 run_col_formatted
32+
- name: Run Unit Tests for coverage
33+
run: |
34+
make -C FreeRTOS/Test/CMock clean
35+
make -C FreeRTOS/Test/CMock lcovhtml
36+
lcov --config-file FreeRTOS/Test/CMock/lcovrc --summary FreeRTOS/Test/CMock/build/cmock_test.info > FreeRTOS/Test/CMock/build/cmock_test_summary.txt
37+
- name: Upload coverage to Codecov
38+
uses: codecov/codecov-action@v1
39+
with:
40+
files: FreeRTOS/Test/CMock/build/cmock_test.info
41+
working-directory: .
42+
root_dir: FreeRTOS/Source
43+
flags: unittests
44+
fail_ci_if_error: false
45+
path_to_write_report: coverage/codecov_report.txt
46+
verbose: false
47+
- name: Archive code coverage data
48+
uses: actions/upload-artifact@v2
49+
with:
50+
name: coverage-data
51+
path: FreeRTOS/Test/CMock/build/cmock_test*
52+
- name: Archive code coverage html report
53+
uses: actions/upload-artifact@v2
54+
with:
55+
name: coverage-report
56+
path: FreeRTOS/Test/CMock/build/coverage

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ See the readme file in the ```./portable``` directory for more information.
3131
- The ```./include``` directory contains the real time kernel header files.
3232

3333
### Code Formatting
34-
FreeRTOS files are formatted using the "uncrustify" tool. The configuration file used by uncrustify can be found in the [FreeRTOS/FreeRTOS repository](https://github.com/FreeRTOS/FreeRTOS/blob/master/tools/uncrustify.cfg).
34+
FreeRTOS files are formatted using the "uncrustify" tool. The configuration file used by uncrustify can be found in the [FreeRTOS/FreeRTOS repository](https://github.com/FreeRTOS/FreeRTOS/blob/main/tools/uncrustify.cfg).
3535

3636
### Spelling
3737
*lexicon.txt* contains words that are not traditionally found in an English dictionary. It is used by the spellchecker to verify the various jargon, variable names, and other odd words used in the FreeRTOS code base. If your pull request fails to pass the spelling and you believe this is a mistake, then add the word to *lexicon.txt*.

event_groups.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -625,6 +625,8 @@ EventBits_t xEventGroupSetBits( EventGroupHandle_t xEventGroup,
625625

626626
void vEventGroupDelete( EventGroupHandle_t xEventGroup )
627627
{
628+
configASSERT( xEventGroup );
629+
628630
EventGroup_t * pxEventBits = xEventGroup;
629631
const List_t * pxTasksWaitingForBits = &( pxEventBits->xTasksWaitingForBits );
630632

include/FreeRTOS.h

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -896,11 +896,6 @@
896896
#define configSUPPORT_DYNAMIC_ALLOCATION 1
897897
#endif
898898

899-
#ifndef configSTACK_ALLOCATION_FROM_SEPARATE_HEAP
900-
/* Defaults to 0 for backward compatibility. */
901-
#define configSTACK_ALLOCATION_FROM_SEPARATE_HEAP 0
902-
#endif
903-
904899
#ifndef configSTACK_DEPTH_TYPE
905900

906901
/* Defaults to uint16_t for backward compatibility, but can be overridden
@@ -1059,6 +1054,11 @@
10591054
#define configRUN_FREERTOS_SECURE_ONLY 0
10601055
#endif
10611056

1057+
#ifndef configRUN_ADDITIONAL_TESTS
1058+
#define configRUN_ADDITIONAL_TESTS 0
1059+
#endif
1060+
1061+
10621062
/* Sometimes the FreeRTOSConfig.h settings only allow a task to be created using
10631063
* dynamically allocated RAM, in which case when any task is deleted it is known
10641064
* that both the task's stack and TCB need to be freed. Sometimes the

include/croutine.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ typedef struct corCoRoutineControlBlock
6565
* crCOROUTINE_CODE pxCoRoutineCode,
6666
* UBaseType_t uxPriority,
6767
* UBaseType_t uxIndex
68-
* );
68+
* );
6969
* </pre>
7070
*
7171
* Create a new co-routine and add it to the list of co-routines that are

0 commit comments

Comments
 (0)