FreeRTOS C-Addons
1.1.0
C-Addon functionality to FreeRTOS
|
Go to the source code of this file.
Typedefs | |
typedef void * | ReadWriteLock_t |
Functions | |
ReadWriteLock_t * | CreateReadWriteLockPreferReader (void) |
ReadWriteLock_t * | CreateReadWriteLockPreferWriter (void) |
void | FreeReadWriteLock (ReadWriteLock_t *lock) |
void | ReaderLock (ReadWriteLock_t *Lock) |
void | ReaderUnlock (ReadWriteLock_t *Lock) |
void | WriterLock (ReadWriteLock_t *Lock) |
void | WriterUnlock (ReadWriteLock_t *Lock) |
typedef void* ReadWriteLock_t |
Handle for Reader/Writer locks.
Definition at line 47 of file read_write_lock.h.
ReadWriteLock_t* CreateReadWriteLockPreferReader | ( | void | ) |
Create a Reader/Writer lock that offers preference to all readers.
Definition at line 132 of file read_write_lock.c.
ReadWriteLock_t* CreateReadWriteLockPreferWriter | ( | void | ) |
Create a Reader/Writer lock that offers preference to all writers.
Definition at line 198 of file read_write_lock.c.
void FreeReadWriteLock | ( | ReadWriteLock_t * | lock | ) |
Free an already allocated Reader/Writer lock.
lock | The lock you are freeing. |
Definition at line 296 of file read_write_lock.c.
void ReaderLock | ( | ReadWriteLock_t * | Lock | ) |
Lock as a Reader.
This allows you shared read only access to whatever is being protected by this lock.
Lock | The lock you are taking. |
Definition at line 321 of file read_write_lock.c.
void ReaderUnlock | ( | ReadWriteLock_t * | Lock | ) |
Unlock as a Reader.
You should have already locked this using ReaderLock().
Lock | The lock you are releasing. |
Definition at line 359 of file read_write_lock.c.
void WriterLock | ( | ReadWriteLock_t * | Lock | ) |
Lock as a Writer.
This allows you exclusive read / write access to whatever is being protected by this lock.
Lock | The lock you are taking. |
Definition at line 395 of file read_write_lock.c.
void WriterUnlock | ( | ReadWriteLock_t * | Lock | ) |
Unlock as a Writer.
You should have already locked this using WriterLock().
Lock | The lock you are releasing. |
Definition at line 427 of file read_write_lock.c.