Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add daemon task startup hook / timer task creation consistency check #1009

Conversation

RichardBarry
Copy link
Contributor

Description

Add a compile time check that emits a helpful error message if the user attempts to create a daemon task startup hook without also creating the timer/daemon task.

The timer/daemon task startup hook runs in the context of the timer/daemon task. Therefore, it won't run even if configUSE_DAEMON_TASK_STARTUP_HOOK is set to 1 if the timer task isn't created. The timer task is only created if configUSE_TIMERS is not equal to 0.

Test Steps

Manually checked as requires multiple compilations with different configurations.

Checklist:

  • [x ] I have tested my changes. No regression in existing tests.
  • I have modified and/or added unit-tests to cover the code changes in this Pull Request.

Related Issue

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

none added 5 commits March 6, 2024 08:37
…er attempts to create a daemon task startup hook without also creating the timer/daemon task.

The timer/daemon task startup hook runs in the context of the timer/daemon task.  Therefore, it won't run even if configUSE_DAEMON_TASK_STARTUP_HOOK is set to 1 if the timer task isn't created.  The timer task is only created if configUSE_TIMERS is not equal to 0.
Copy link

sonarqubecloud bot commented Mar 6, 2024

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
0.8% Duplication on New Code

See analysis details on SonarCloud

Copy link

codecov bot commented Mar 6, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 93.00%. Comparing base (d95451d) to head (13f428b).

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1009   +/-   ##
=======================================
  Coverage   93.00%   93.00%           
=======================================
  Files           6        6           
  Lines        3200     3200           
  Branches      879      879           
=======================================
  Hits         2976     2976           
  Misses        111      111           
  Partials      113      113           
Flag Coverage Δ
unittests 93.00% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@aggarg aggarg merged commit 4732b96 into FreeRTOS:main Mar 7, 2024
18 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants