kernel: Add note regarding safe use of the k_work_pending return value
Add note regarding safe use of the k_work_pending return value. Similar to the note for k_delayed_work_pending. Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
This commit is contained in:
parent
ea9590448d
commit
f327ed2fb9
1 changed files with 4 additions and 0 deletions
|
@ -3222,6 +3222,10 @@ static inline int k_work_submit_to_user_queue(struct k_work_q *work_q,
|
|||
* This routine indicates if work item @a work is pending in a workqueue's
|
||||
* queue.
|
||||
*
|
||||
* @note Checking if the work is pending gives no guarantee that the
|
||||
* work will still be pending when this information is used. It is up to
|
||||
* the caller to make sure that this information is used in a safe manner.
|
||||
*
|
||||
* @note Can be called by ISRs.
|
||||
*
|
||||
* @param work Address of work item.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue