Changeset View
Changeset View
Standalone View
Standalone View
sys/net/route/route_var.h
Show First 20 Lines • Show All 73 Lines • ▼ Show 20 Lines | |||||
#define RIB_RUNLOCK(rh) rm_runlock(&(rh)->rib_lock, &_rib_tracker) | #define RIB_RUNLOCK(rh) rm_runlock(&(rh)->rib_lock, &_rib_tracker) | ||||
#define RIB_WLOCK(rh) rm_wlock(&(rh)->rib_lock) | #define RIB_WLOCK(rh) rm_wlock(&(rh)->rib_lock) | ||||
#define RIB_WUNLOCK(rh) rm_wunlock(&(rh)->rib_lock) | #define RIB_WUNLOCK(rh) rm_wunlock(&(rh)->rib_lock) | ||||
#define RIB_LOCK_ASSERT(rh) rm_assert(&(rh)->rib_lock, RA_LOCKED) | #define RIB_LOCK_ASSERT(rh) rm_assert(&(rh)->rib_lock, RA_LOCKED) | ||||
#define RIB_WLOCK_ASSERT(rh) rm_assert(&(rh)->rib_lock, RA_WLOCKED) | #define RIB_WLOCK_ASSERT(rh) rm_assert(&(rh)->rib_lock, RA_WLOCKED) | ||||
/* Constants */ | /* Constants */ | ||||
#define RIB_MAX_RETRIES 3 | #define RIB_MAX_RETRIES 3 | ||||
#define RT_MAXFIBS UINT16_MAX | |||||
/* Macro for verifying fields in af-specific 'struct route' structures */ | /* Macro for verifying fields in af-specific 'struct route' structures */ | ||||
#define CHK_STRUCT_FIELD_GENERIC(_s1, _f1, _s2, _f2) \ | #define CHK_STRUCT_FIELD_GENERIC(_s1, _f1, _s2, _f2) \ | ||||
_Static_assert(sizeof(((_s1 *)0)->_f1) == sizeof(((_s2 *)0)->_f2), \ | _Static_assert(sizeof(((_s1 *)0)->_f1) == sizeof(((_s2 *)0)->_f2), \ | ||||
"Fields " #_f1 " and " #_f2 " size differs"); \ | "Fields " #_f1 " and " #_f2 " size differs"); \ | ||||
_Static_assert(__offsetof(_s1, _f1) == __offsetof(_s2, _f2), \ | _Static_assert(__offsetof(_s1, _f1) == __offsetof(_s2, _f2), \ | ||||
"Fields " #_f1 " and " #_f2 " offset differs"); | "Fields " #_f1 " and " #_f2 " offset differs"); | ||||
▲ Show 20 Lines • Show All 155 Lines • Show Last 20 Lines |