Go to the source code of this file.
◆ LWP_SEM_NULL
#define LWP_SEM_NULL 0xffffffff |
◆ sem_t
◆ LWP_SemDestroy()
Close and destroy a semaphore, release all threads and handles locked on this semaphore.
- Parameters
-
[in] | sem | handle to the sem_t structure. |
- Returns
- 0 on success, <0 on error
◆ LWP_SemInit()
Initializes a semaphore.
- Parameters
-
[out] | sem | pointer to a sem_t handle. |
[in] | start | start count of the semaphore |
[in] | max | maximum count of the semaphore |
- Returns
- 0 on success, <0 on error
◆ LWP_SemPost()
Count up semaphore counter and release lock if counter >0.
- Parameters
-
[in] | sem | handle to the sem_t structure. |
- Returns
- 0 on success, <0 on error
◆ LWP_SemWait()
Count down semaphore counter and enter lock if counter <=0.
- Parameters
-
[in] | sem | handle to the sem_t structure. |
- Returns
- 0 on success, <0 on error