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

Go to the source code of this file.

Data Structures

struct  bitstream_cursor
 
struct  bitstream
 

Macros

#define VLI_L_1_1()
 
#define LEVEL(t, b, v)
 
#define LEVEL(t, b, v)
 

Macro Definition Documentation

#define LEVEL (   t,
  b,
  v 
)
Value:
do { \
if ((in & ((1 << b) -1)) == v) { \
*out = ((in & ((~0ULL) >> (64-t))) >> b) + adj; \
return t; \
} \
adj += 1ULL << (t - b); \
} while (0)
#define LEVEL (   t,
  b,
  v 
)
Value:
do { \
max += 1ULL << (t - b); \
if (in <= max) { \
if (out) \
*out = ((in - adj) << b) | v; \
return t; \
} \
adj = max + 1; \
} while (0)
#define VLI_L_1_1 ( )
Value:
do { \
LEVEL( 2, 1, 0x00); \
LEVEL( 3, 2, 0x01); \
LEVEL( 5, 3, 0x03); \
LEVEL( 7, 4, 0x07); \
LEVEL(10, 5, 0x0f); \
LEVEL(14, 6, 0x1f); \
LEVEL(21, 8, 0x3f); \
LEVEL(29, 8, 0x7f); \
LEVEL(42, 8, 0xbf); \
LEVEL(64, 8, 0xff); \
} while (0)

Definition at line 129 of file drbd_vli.h.