Skip to content

core/thread_flags: collect predefined flags#22365

Open
axelixy wants to merge 1 commit into
RIOT-OS:masterfrom
axelixy:core/thread-flags-predefined-mask-20867
Open

core/thread_flags: collect predefined flags#22365
axelixy wants to merge 1 commit into
RIOT-OS:masterfrom
axelixy:core/thread-flags-predefined-mask-20867

Conversation

@axelixy

@axelixy axelixy commented Jun 9, 2026

Copy link
Copy Markdown

Contribution description

This centralizes RIOT's predefined thread flag definitions in
core/include/thread_flags.h.

The PR moves the thread flag definitions listed in #20867 out of individual
modules and test applications, while preserving their existing bit values.
THREAD_FLAG_PREDEFINED_MASK now also accounts for module-specific predefined
flags when the corresponding module is selected.

The updated mask includes flags used by event queues, USBUS, POSIX select,
Kinetis I2C, KW41ZRF, LVGL, lwIP netdev, and the listed test applications.

Testing procedure

I checked the diff locally with:

git diff --check

Issues/PRs references

Fixes #20867

@github-actions

github-actions Bot commented Jun 9, 2026

Copy link
Copy Markdown

Hey @axelixy, thank you for your first contribution! We really appreciate it! If you haven't already, please take a look at our contributing guidelines before the review process starts. Also, due to how the GitHub review system works, please avoid force-pushing or squashing your commits unless asked to by a maintainer (or unless your commit is still in "draft commit" stage). Your pull request will be reviewed as soon as possible.

@github-actions github-actions Bot added Platform: ARM Platform: This PR/issue effects ARM-based platforms Area: network Area: Networking Area: tests Area: tests and testing framework Area: core Area: RIOT kernel. Handle PRs marked with this with care! Area: pkg Area: External package ports Area: drivers Area: Device drivers Area: cpu Area: CPU/MCU ports Area: USB Area: Universal Serial Bus Area: sys Area: System labels Jun 9, 2026
@crasbe crasbe added Type: enhancement The issue suggests enhanceable parts / The PR enhances parts of the codebase / documentation Process: needs >1 ACK Integration Process: This PR requires more than one ACK labels Jun 10, 2026
@crasbe crasbe requested a review from Enoch247 June 10, 2026 08:11
@github-actions github-actions Bot added the Process: missing approvals Integration Process: PR needs more ACKS (handled by action) label Jun 10, 2026
@axelixy

axelixy commented Jun 10, 2026

Copy link
Copy Markdown
Author

It looks like the tools-build failure is caused by a Docker pull failure. Could someone re-run that job?

@Enoch247

Copy link
Copy Markdown
Contributor

It looks like this PR is missing the Declaration of AI-Tools / LLMs usage.

@Enoch247 Enoch247 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some of these flags should not be centralized. Particularly the ones used in test apps, but also ones that are private to a module. There was some discussion about this on #riot-os:matrix.org. There is a link in issue #20867 to that discussion.

#endif

#include "bitfield.h"
#include "thread_flags.h"

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't believe this line is needed. I believe the only two users of POSIX_SELECT_THREAD_FLAG already include thread_flags.h, correct?

@crasbe crasbe added the CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR label Jun 11, 2026
@riot-ci

riot-ci commented Jun 11, 2026

Copy link
Copy Markdown

Murdock results

✔️ PASSED

657bb66 core/thread_flags: collect predefined flags

Success Failures Total Runtime
11124 0 11124 13m:39s

Artifacts

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Area: core Area: RIOT kernel. Handle PRs marked with this with care! Area: cpu Area: CPU/MCU ports Area: drivers Area: Device drivers Area: network Area: Networking Area: pkg Area: External package ports Area: sys Area: System Area: tests Area: tests and testing framework Area: USB Area: Universal Serial Bus CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR Platform: ARM Platform: This PR/issue effects ARM-based platforms Process: missing approvals Integration Process: PR needs more ACKS (handled by action) Process: needs >1 ACK Integration Process: This PR requires more than one ACK Type: enhancement The issue suggests enhanceable parts / The PR enhances parts of the codebase / documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

definition of thread flags are uncoordindated between modules

4 participants