#include <gctypes.h>
Defines | |
#define | LWP_SEM_NULL 0xffffffff |
Typedefs | |
typedef u32 | sem_t |
typedef for the semaphore handle | |
Functions | |
s32 | LWP_SemInit (sem_t *sem, u32 start, u32 max) |
Initializes a semaphore. | |
s32 | LWP_SemDestroy (sem_t sem) |
Close and destroy a semaphore, release all threads and handles locked on this semaphore. | |
s32 | LWP_SemWait (sem_t sem) |
Count down semaphore counter and enter lock if counter <=0. | |
s32 | LWP_SemPost (sem_t sem) |
Count up semaphore counter and release lock if counter >0. |
Close and destroy a semaphore, release all threads and handles locked on this semaphore.
[in] | sem | handle to the sem_t structure. |
Initializes a semaphore.
[out] | sem | pointer to a sem_t handle. |
[in] | start | start count of the semaphore |
[in] | max | maximum count of the semaphore |
Count up semaphore counter and release lock if counter >0.
[in] | sem | handle to the sem_t structure. |
Count down semaphore counter and enter lock if counter <=0.
[in] | sem | handle to the sem_t structure. |