rwlock.h File Reference

This file contains rwlock API and provides its fake implementation based on futexes. More...

#include <atomic.h>
#include <sys/types.h>
#include <futex.h>

Go to the source code of this file.

Defines

#define rwlock_initialize(rwlock)   futex_initialize((rwlock), 1)
#define RWLOCK_INITIALIZE(rwlock)   rwlock_t rwlock = FUTEX_INITIALIZER
#define rwlock_read_lock(rwlock)   futex_down((rwlock))
#define rwlock_read_unlock(rwlock)   futex_up((rwlock))
#define rwlock_write_lock(rwlock)   futex_down((rwlock))
#define rwlock_write_unlock(rwlock)   futex_up((rwlock))

Typedefs

typedef atomic_t rwlock_t


Detailed Description

This file contains rwlock API and provides its fake implementation based on futexes.

Definition in file rwlock.h.


Generated on Thu Jun 2 07:45:53 2011 for HelenOS/USB by  doxygen 1.4.7