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

Prevent use of deleted ticker in Ticker test #5255

Merged
merged 1 commit into from Oct 9, 2017

Conversation

Projects
None yet
4 participants
@c1728p9
Contributor

c1728p9 commented Oct 4, 2017

In test_case_2x_callbacks two tickers are setup to repeatedly reschedule each other. When these tickers are deleted this rescheduling is still occurring and can lead to a deleted ticker being scheduled.

When this happens the following error message is displayed:
Thread 0x0 error -6: Not allowed in ISR context

Note - this problem was not detected by CI since the test reported the correct results back to the host test and only experienced this error on tear down.

This problem can be reproduced on an nrf51 by first building the ticker
test with:

> mbed test -t GCC_ARM -m NRF51_DK -n tests-mbed_drivers-ticker --compile -DMBED_TRAP_ERRORS_ENABLED=1 -DMBED_HEAP_STATS_ENABLED=1 -DMBED_STACK_STATS_ENABLED=1

And then running testing with:

> mbed test -t GCC_ARM -m NRF51_DK -n tests-mbed_drivers-ticker --run"
Prevent use of deleted ticker in Ticker test
In test_case_2x_callbacks two tickers are setup to repeatedly
reschedule each other. When these tickers are deleted this
rescheduling is still occurring and can lead to a deleted ticker
being scheduled.

When this happens the following error message is displayed:
Thread 0x0 error -6: Not allowed in ISR context

Note - this problem was not detected by CI since the test reported
the correct results back to the host test and only experienced this
error on tear down.

This problem can be reproduced on an nrf51 by first building the ticker
test with:
"mbed test -t GCC_ARM -m NRF51_DK -n tests-mbed_drivers-ticker
--compile -DMBED_TRAP_ERRORS_ENABLED=1
-DMBED_HEAP_STATS_ENABLED=1 -DMBED_STACK_STATS_ENABLED=1"

And then running testing with:
"mbed test -t GCC_ARM -m NRF51_DK -n tests-mbed_drivers-ticker --run"
@c1728p9

This comment has been minimized.

Contributor

c1728p9 commented Oct 4, 2017

Created issue #5256 for not detecting the failure.

@0xc0170

0xc0170 approved these changes Oct 5, 2017

@theotherjimmy

This comment has been minimized.

Contributor

theotherjimmy commented Oct 5, 2017

@tommikas It looks like pr-head is lost. Could you take a look?

@0xc0170

This comment has been minimized.

Member

0xc0170 commented Oct 7, 2017

/morph test-nightly

@mbed-bot

This comment has been minimized.

mbed-bot commented Oct 7, 2017

Result: SUCCESS

Your command has finished executing! Here's what you wrote!

/morph test-nightly

Output

mbed Build Number: 1540

All builds and test passed!

@0xc0170 0xc0170 merged commit 943fc32 into ARMmbed:master Oct 9, 2017

4 checks passed

Cam-CI uvisor Build & Test Success
Details
ci/morph-test-nightly Job has completed
Details
continuous-integration/jenkins/pr-head This commit looks good
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details

@0xc0170 0xc0170 removed the ready for merge label Oct 9, 2017

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