Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros
rwlock.h File Reference

Go to the source code of this file.

Data Structures

struct  __dummy_lock_t
 

Macros

#define RW_LOCK_BIAS   0x01000000
 
#define __dummy_lock(lock)   (*(__dummy_lock_t *)(lock))
 
#define RW_LOCK_BIAS_STR   "0x01000000"
 
#define __build_read_lock_ptr(rw, helper)
 
#define __build_read_lock_const(rw, helper)
 
#define __build_read_lock(rw, helper)
 
#define __build_write_lock_ptr(rw, helper)
 
#define __build_write_lock_const(rw, helper)
 
#define __build_write_lock(rw, helper)
 

Macro Definition Documentation

#define __build_read_lock (   rw,
  helper 
)
Value:
do { \
if (__builtin_constant_p(rw)) \
__build_read_lock_const(rw, helper); \
} while (0)

Definition at line 70 of file rwlock.h.

#define __build_read_lock_const (   rw,
  helper 
)
Value:
do { \
asm volatile( \
" mov (%0),d3 \n" \
" sub 1,d3 \n" \
" mov d3,(%0) \n" \
" blt 1f \n" \
" bra 2f \n" \
"1: jmp 3f \n" \
"2: \n" \
" .section .text.lock,\"ax\" \n" \
"3: call "helper"[],0 \n" \
" jmp 2b \n" \
" .previous" \
: \
: "d" (rw) \
: "memory", "d3", "cc"); \
} while (0)

Definition at line 51 of file rwlock.h.

#define __build_read_lock_ptr (   rw,
  helper 
)
Value:
do { \
asm volatile( \
" mov (%0),d3 \n" \
" sub 1,d3 \n" \
" mov d3,(%0) \n" \
" blt 1f \n" \
" bra 2f \n" \
"1: jmp 3f \n" \
"2: \n" \
" .section .text.lock,\"ax\" \n" \
"3: call "helper"[],0 \n" \
" jmp 2b \n" \
" .previous" \
: \
: "d" (rw) \
: "memory", "d3", "cc"); \
} while (0)

Definition at line 32 of file rwlock.h.

#define __build_write_lock (   rw,
  helper 
)
Value:
do { \
if (__builtin_constant_p(rw)) \
__build_write_lock_const(rw, helper); \
} while (0)

Definition at line 116 of file rwlock.h.

#define __build_write_lock_const (   rw,
  helper 
)
Value:
do { \
asm volatile( \
" mov (%0),d3 \n" \
" sub 1,d3 \n" \
" mov d3,(%0) \n" \
" blt 1f \n" \
" bra 2f \n" \
"1: jmp 3f \n" \
"2: \n" \
" .section .text.lock,\"ax\" \n" \
"3: call "helper"[],0 \n" \
" jmp 2b \n" \
" .previous" \
: \
: "d" (rw) \
: "memory", "d3", "cc"); \
} while (0)

Definition at line 97 of file rwlock.h.

#define __build_write_lock_ptr (   rw,
  helper 
)
Value:
do { \
asm volatile( \
" mov (%0),d3 \n" \
" sub 1,d3 \n" \
" mov d3,(%0) \n" \
" blt 1f \n" \
" bra 2f \n" \
"1: jmp 3f \n" \
"2: \n" \
" .section .text.lock,\"ax\" \n" \
"3: call "helper"[],0 \n" \
" jmp 2b \n" \
" .previous" \
: \
: "d" (rw) \
: "memory", "d3", "cc"); \
} while (0)

Definition at line 78 of file rwlock.h.

#define __dummy_lock (   lock)    (*(__dummy_lock_t *)(lock))

Definition at line 28 of file rwlock.h.

#define RW_LOCK_BIAS   0x01000000

Definition at line 23 of file rwlock.h.

#define RW_LOCK_BIAS_STR   "0x01000000"

Definition at line 30 of file rwlock.h.