hdf_workqueue.h
Overview
Related Modules:
Description:
Declares work queue structures and interfaces.
This file provides interfaces such as initializing a work queue, a work item, and a delayed work item, adding a work or delayed work item to a work queue, and destroying a work queue, a work item, and a delayed work item. You need to define a work queue, a work item, and a delayed work item, and then call the initialization function to initialize them. The work item, delayed work item, and work queue must be destroyed when they are no longer used.
Since:
1.0
Version:
1.0
Summary
Data Structures
Describes a work item and a delayed work item. This structure defines the work and delayed work items, and then calls the initialization function HdfWorkInit or HdfDelayedWorkInit to perform initialization. The HdfAddWork() function is to add a work item to a work queue immediately, and the HdfAddDelayedWork() function is to add a work item to a work queue after the configured delayed time. |
|
Typedefs
HdfWorkFunc) (void ) |
Enumerations
{ HDF_WORK_BUSY_PENDING = 1 << 0, HDF_WORK_BUSY_RUNNING = 1 << 1 } |
Functions
HdfWorkQueueInit (HdfWorkQueue queue, char name) |
|
HdfWorkInit (HdfWork work, HdfWorkFunc func, void arg) |
|
HdfDelayedWorkInit (HdfWork work, HdfWorkFunc func, void arg) |
|
HdfWorkDestroy (HdfWork work) |
|
HdfWorkQueueDestroy (HdfWorkQueue queue) |
|
HdfDelayedWorkDestroy (HdfWork work) |
|
HdfAddWork (HdfWorkQueue queue, HdfWork work) |
|
HdfAddDelayedWork (HdfWorkQueue queue, HdfWork work, unsigned long ms) |
|
HdfWorkBusy (HdfWork work) |
|
HdfCancelWorkSync (HdfWork work) |
Cancels a work item. This function waits until the work item is complete. |
HdfCancelDelayedWorkSync (HdfWork work) |