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

up_squared_adsp:running tests/kernel/workq/work_queue/ failed #28589

Closed
KangJianX opened this issue Sep 22, 2020 · 2 comments · Fixed by #28655
Closed

up_squared_adsp:running tests/kernel/workq/work_queue/ failed #28589

KangJianX opened this issue Sep 22, 2020 · 2 comments · Fixed by #28655
Assignees
Labels
bug The issue is a bug, or the PR is fixing a bug priority: low Low impact/importance bug

Comments

@KangJianX
Copy link
Collaborator

KangJianX commented Sep 22, 2020

Describe the bug
running test/kernel/workq/work_queue/ error, it showed assertion failed.

To Reproduce
Steps to reproduce the behavior:

sanitycheck -W -p up_squared_adsp --device-testing -T tests/kernel/workq/work_queue/ --west-flash="/home/ztest/work/zephyrproject/zephyr/boards/xtensa/up_squared_adsp/tools/up_squared_adsp_flash.sh, /home/ztest/work/sof/rimage/keys/otc_private_key.pem" --device-serial-pty="/home/ztest/work/ambient/set_ambient /home/ztest/work/zephyrproject/zephyr/boards/xtensa/up_squared_adsp/tools/mbterm.py" -x=CONFIG_IPM=y -x=CONFIG_CONSOLE=y -x=CONFIG_LOG_PRINTK=n

see error

PASS - test_triggered_wait

===================================================================
START - test_triggered_wait_expired
Starting triggered test
- Initializing triggered test items
- Submitting triggered test items
- Submitting triggered work 1
- Submitting triggered work 2
- Submitting triggered work 3
- Submitting triggered work 4
- Submitting triggered work 5
- Submitting triggered work 6
- Checking results (before timeout)
- Running triggered test item 1
- Running triggered test item 2
- Checking results (after timeout)
Assertion failed at WEST_TOPDIR/zephyr/tests/kernel/workq/work_queue/src/main.c:133: check_results: (num_results not equal t
o num_tests)
*** work items finished: 2 (expected: 6)
- Running triggered test item 3
- Running triggered test item 4
- Running triggered test item 5
- Running triggered test item 6
FAIL - test_triggered_wait_expired
===================================================================
Test suite workqueue failed.
===================================================================
PROJECT EXECUTION FAILED

Environment (please complete the following information):
OS: Fedora28
Toolchain: Zephyr-sdk-0.11.3
Commit ID: 2cd556a

@KangJianX KangJianX added the bug The issue is a bug, or the PR is fixing a bug label Sep 22, 2020
@MaureenHelm MaureenHelm added the priority: low Low impact/importance bug label Sep 22, 2020
@dcpleung
Copy link
Member

Could you re-test? I could not reproduce it on master and on the commit you provided.

@dcpleung dcpleung added the Waiting for response Waiting for author's response label Sep 22, 2020
@KangJianX
Copy link
Collaborator Author

Yes, I reproduce issue on this commit.

@dcpleung dcpleung removed the Waiting for response Waiting for author's response label Sep 23, 2020
dcpleung added a commit to dcpleung/zephyr that referenced this issue Sep 23, 2020
The test_triggered_wait_expired test submits the items with
2*SUBMIT_WAIT timeout and waits for the timeout to expire
so the items are being worked on. It waits one SUBMIT_WAIT
and checks none of the items have started. Then waits
another SUBMIT_WAIT to check if they have all finished.
However, since the timeout is at 2*SUBMIT_WAIT, the work
queue may have just started going through the list of items.
This means some items may have started while others have not.
This results in the test failing as not all items have
finished. So lengthen the second sleep to allow items to
finish before checking.

Fixes zephyrproject-rtos#28589

Signed-off-by: Daniel Leung <[email protected]>
MaureenHelm pushed a commit that referenced this issue Oct 5, 2020
The test_triggered_wait_expired test submits the items with
2*SUBMIT_WAIT timeout and waits for the timeout to expire
so the items are being worked on. It waits one SUBMIT_WAIT
and checks none of the items have started. Then waits
another SUBMIT_WAIT to check if they have all finished.
However, since the timeout is at 2*SUBMIT_WAIT, the work
queue may have just started going through the list of items.
This means some items may have started while others have not.
This results in the test failing as not all items have
finished. So lengthen the second sleep to allow items to
finish before checking.

Fixes #28589

Signed-off-by: Daniel Leung <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug The issue is a bug, or the PR is fixing a bug priority: low Low impact/importance bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants