kernel/poll: no error happened when mutil-threads poll a same event at a same time. #33712
Labels
area: Kernel
bug
The issue is a bug, or the PR is fixing a bug
priority: low
Low impact/importance bug
Describe the bug
I took a look at Zephyr Specification https://docs.zephyrproject.org/latest/reference/kernel/other/polling.html#c.k_poll about kernel/poll , I think there is a test point that was not tested before, the info as below:
It means if there are two thread polling a same event(sem/fifo) at a same time, k_poll() immediately returns with the return value -EADDRINUSE. Is this right?
So I designed a testcase to test this, the code as below:
and the output as below:
As you see, there is no error return value returned. So I think either the zephyr specification is wrong or there is something wrong with my code. Could you have any comments about this?
The text was updated successfully, but these errors were encountered: