doc: kernel: workqueue: explicitly mention K_WORK_DEFINE
Point out that this macro can be used to avoid the need to initialize a work item. This is still of limited use since it can't statically initialize a work item within another structure. Signed-off-by: Peter Bigot <peter.bigot@nordicsemi.no>
This commit is contained in:
parent
537f966997
commit
1f0082249e
1 changed files with 3 additions and 1 deletions
|
@ -245,7 +245,9 @@ Submitting a Work Item
|
|||
======================
|
||||
|
||||
A work item is defined using a variable of type :c:struct:`k_work`. It must
|
||||
be initialized by calling :c:func:`k_work_init`.
|
||||
be initialized by calling :c:func:`k_work_init`, unless it is defined using
|
||||
:c:macro:`K_WORK_DEFINE` in which case initialization is performed at
|
||||
compile-time.
|
||||
|
||||
An initialized work item can be submitted to the system workqueue by
|
||||
calling :c:func:`k_work_submit`, or to a specified workqueue by
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue