Include dependency graph for bits.c:
Go to the source code of this file.
Defines | |
#define | MASK0(x) ((unsigned long *)&(x))[0] |
#define | MASK1(x) ((unsigned long *)&(x))[1] |
#define | CHECK_BITS_MAGIC(bits) do { if (bits->magic != RT_BITS_MAGIC) return RTE_OBJINV; } while (0) |
#define | TEST_BUF(x, y) do { (x)->retval = (unsigned long)(y); } while (0) |
#define | TEST_FUN(x) ((long *)((unsigned long)(x)->retval))[0] |
#define | TEST_MASK(x) ((unsigned long *)((unsigned long)(x)->retval))[1] |
Functions | |
MODULE_LICENSE ("GPL") | |
static int | all_set (BITS *bits, unsigned long mask) |
static int | any_set (BITS *bits, unsigned long mask) |
static int | all_clr (BITS *bits, unsigned long mask) |
static int | any_clr (BITS *bits, unsigned long mask) |
static int | all_set_and_any_set (BITS *bits, unsigned long masks) |
static int | all_set_and_all_clr (BITS *bits, unsigned long masks) |
static int | all_set_and_any_clr (BITS *bits, unsigned long masks) |
static int | any_set_and_all_clr (BITS *bits, unsigned long masks) |
static int | any_set_and_any_clr (BITS *bits, unsigned long masks) |
static int | all_clr_and_any_clr (BITS *bits, unsigned long masks) |
static int | all_set_or_any_set (BITS *bits, unsigned long masks) |
static int | all_set_or_all_clr (BITS *bits, unsigned long masks) |
static int | all_set_or_any_clr (BITS *bits, unsigned long masks) |
static int | any_set_or_all_clr (BITS *bits, unsigned long masks) |
static int | any_set_or_any_clr (BITS *bits, unsigned long masks) |
static int | all_clr_or_any_clr (BITS *bits, unsigned long masks) |
static void | set_bits_mask (BITS *bits, unsigned long mask) |
static void | clr_bits_mask (BITS *bits, unsigned long mask) |
static void | set_clr_bits_mask (BITS *bits, unsigned long masks) |
static void | nop_fun (BITS *bits, unsigned long mask) |
void | rt_bits_init (BITS *bits, unsigned long mask) |
int | rt_bits_delete (BITS *bits) |
RTAI_SYSCALL_MODE unsigned long | rt_get_bits (BITS *bits) |
RTAI_SYSCALL_MODE unsigned long | rt_bits_reset (BITS *bits, unsigned long mask) |
RTAI_SYSCALL_MODE unsigned long | rt_bits_signal (BITS *bits, int setfun, unsigned long masks) |
RTAI_SYSCALL_MODE int | _rt_bits_wait (BITS *bits, int testfun, unsigned long testmasks, int exitfun, unsigned long exitmasks, unsigned long *resulting_mask, int space) |
RTAI_SYSCALL_MODE int | _rt_bits_wait_if (BITS *bits, int testfun, unsigned long testmasks, int exitfun, unsigned long exitmasks, unsigned long *resulting_mask, int space) |
RTAI_SYSCALL_MODE int | _rt_bits_wait_until (BITS *bits, int testfun, unsigned long testmasks, int exitfun, unsigned long exitmasks, RTIME time, unsigned long *resulting_mask, int space) |
RTAI_SYSCALL_MODE int | _rt_bits_wait_timed (BITS *bits, int testfun, unsigned long testmasks, int exitfun, unsigned long exitmasks, RTIME delay, unsigned long *resulting_mask, int space) |
RTAI_SYSCALL_MODE BITS * | rt_named_bits_init (const char *bits_name, unsigned long mask) |
RTAI_SYSCALL_MODE int | rt_named_bits_delete (BITS *bits) |
RTAI_SYSCALL_MODE void * | rt_bits_init_u (unsigned long name, unsigned long mask) |
RTAI_SYSCALL_MODE int | rt_bits_delete_u (BITS *bits) |
int | set_rt_fun_entries (struct rt_native_fun_entry *entry) |
void | reset_rt_fun_entries (struct rt_native_fun_entry *entry) |
int | __rtai_bits_init (void) |
void | __rtai_bits_exit (void) |
module_init (__rtai_bits_init) | |
module_exit (__rtai_bits_exit) | |
EXPORT_SYMBOL (rt_bits_init) | |
EXPORT_SYMBOL (rt_bits_delete) | |
EXPORT_SYMBOL (rt_get_bits) | |
EXPORT_SYMBOL (rt_bits_reset) | |
EXPORT_SYMBOL (rt_bits_signal) | |
EXPORT_SYMBOL (_rt_bits_wait) | |
EXPORT_SYMBOL (_rt_bits_wait_if) | |
EXPORT_SYMBOL (_rt_bits_wait_until) | |
EXPORT_SYMBOL (_rt_bits_wait_timed) | |
EXPORT_SYMBOL (rt_named_bits_init) | |
EXPORT_SYMBOL (rt_named_bits_delete) | |
EXPORT_SYMBOL (rt_bits_init_u) | |
EXPORT_SYMBOL (rt_bits_delete_u) | |
Variables | |
static int(*[]) | test_fun (BITS *, unsigned long) |
static void(*[]) | exec_fun (BITS *, unsigned long) |
rt_native_fun_entry | rt_bits_entries [] |
#define CHECK_BITS_MAGIC | ( | bits | ) | do { if (bits->magic != RT_BITS_MAGIC) return RTE_OBJINV; } while (0) |
Definition at line 150 of file bits.c.
Referenced by _rt_bits_wait(), _rt_bits_wait_if(), _rt_bits_wait_until(), rt_bits_delete(), rt_bits_reset(), and rt_bits_signal().
#define MASK0 | ( | x | ) | ((unsigned long *)&(x))[0] |
Definition at line 32 of file bits.c.
Referenced by all_clr_and_any_clr(), all_clr_or_any_clr(), all_set_and_all_clr(), all_set_and_any_clr(), all_set_and_any_set(), all_set_or_all_clr(), all_set_or_any_clr(), all_set_or_any_set(), any_set_and_all_clr(), any_set_and_any_clr(), any_set_or_all_clr(), any_set_or_any_clr(), and set_clr_bits_mask().
#define MASK1 | ( | x | ) | ((unsigned long *)&(x))[1] |
Definition at line 33 of file bits.c.
Referenced by all_clr_and_any_clr(), all_clr_or_any_clr(), all_set_and_all_clr(), all_set_and_any_clr(), all_set_and_any_set(), all_set_or_all_clr(), all_set_or_any_clr(), all_set_or_any_set(), any_set_and_all_clr(), any_set_and_any_clr(), any_set_or_all_clr(), any_set_or_any_clr(), and set_clr_bits_mask().
#define TEST_BUF | ( | x, | |||
y | ) | do { (x)->retval = (unsigned long)(y); } while (0) |
#define TEST_FUN | ( | x | ) | ((long *)((unsigned long)(x)->retval))[0] |
Definition at line 190 of file bits.c.
Referenced by _rt_bits_wait(), _rt_bits_wait_until(), and rt_bits_signal().
#define TEST_MASK | ( | x | ) | ((unsigned long *)((unsigned long)(x)->retval))[1] |
Definition at line 191 of file bits.c.
Referenced by _rt_bits_wait(), _rt_bits_wait_until(), and rt_bits_signal().
void __rtai_bits_exit | ( | void | ) |
Definition at line 469 of file bits.c.
References reset_rt_fun_entries().
Here is the call graph for this function:
int __rtai_bits_init | ( | void | ) |
Definition at line 464 of file bits.c.
References set_rt_fun_entries().
Here is the call graph for this function:
RTAI_SYSCALL_MODE int _rt_bits_wait | ( | BITS * | bits, | |
int | testfun, | |||
unsigned long | testmasks, | |||
int | exitfun, | |||
unsigned long | exitmasks, | |||
unsigned long * | resulting_mask, | |||
int | space | |||
) |
Definition at line 258 of file bits.c.
References CHECK_BITS_MAGIC, dequeue_blocked(), enqueue_blocked(), exec_fun, flags, likely, RT_SCHED_SEMAPHORE, rt_schedule(), RTE_OBJREM, RTE_UNBLKD, RTP_OBJREM, TEST_BUF, TEST_FUN, test_fun, TEST_MASK, and unlikely.
Here is the call graph for this function:
RTAI_SYSCALL_MODE int _rt_bits_wait_if | ( | BITS * | bits, | |
int | testfun, | |||
unsigned long | testmasks, | |||
int | exitfun, | |||
unsigned long | exitmasks, | |||
unsigned long * | resulting_mask, | |||
int | space | |||
) |
RTAI_SYSCALL_MODE int _rt_bits_wait_timed | ( | BITS * | bits, | |
int | testfun, | |||
unsigned long | testmasks, | |||
int | exitfun, | |||
unsigned long | exitmasks, | |||
RTIME | delay, | |||
unsigned long * | resulting_mask, | |||
int | space | |||
) |
Definition at line 382 of file bits.c.
References _rt_bits_wait_until().
Here is the call graph for this function:
RTAI_SYSCALL_MODE int _rt_bits_wait_until | ( | BITS * | bits, | |
int | testfun, | |||
unsigned long | testmasks, | |||
int | exitfun, | |||
unsigned long | exitmasks, | |||
RTIME | time, | |||
unsigned long * | resulting_mask, | |||
int | space | |||
) |
Definition at line 330 of file bits.c.
References CHECK_BITS_MAGIC, dequeue_blocked(), enqueue_blocked(), exec_fun, flags, likely, RT_SCHED_DELAYED, RT_SCHED_SEMAPHORE, rt_schedule(), RTE_OBJREM, RTE_TIMOUT, RTE_UNBLKD, RTP_HIGERR, RTP_OBJREM, TEST_BUF, TEST_FUN, test_fun, TEST_MASK, and unlikely.
Referenced by _rt_bits_wait_timed().
Here is the call graph for this function:
static int all_clr | ( | BITS * | bits, | |
unsigned long | mask | |||
) | [static] |
static int all_clr_and_any_clr | ( | BITS * | bits, | |
unsigned long | masks | |||
) | [static] |
static int all_clr_or_any_clr | ( | BITS * | bits, | |
unsigned long | masks | |||
) | [static] |
static int all_set | ( | BITS * | bits, | |
unsigned long | mask | |||
) | [static] |
static int all_set_and_all_clr | ( | BITS * | bits, | |
unsigned long | masks | |||
) | [static] |
static int all_set_and_any_clr | ( | BITS * | bits, | |
unsigned long | masks | |||
) | [static] |
static int all_set_and_any_set | ( | BITS * | bits, | |
unsigned long | masks | |||
) | [static] |
static int all_set_or_all_clr | ( | BITS * | bits, | |
unsigned long | masks | |||
) | [static] |
static int all_set_or_any_clr | ( | BITS * | bits, | |
unsigned long | masks | |||
) | [static] |
static int all_set_or_any_set | ( | BITS * | bits, | |
unsigned long | masks | |||
) | [static] |
static int any_clr | ( | BITS * | bits, | |
unsigned long | mask | |||
) | [static] |
static int any_set | ( | BITS * | bits, | |
unsigned long | mask | |||
) | [static] |
static int any_set_and_all_clr | ( | BITS * | bits, | |
unsigned long | masks | |||
) | [static] |
static int any_set_and_any_clr | ( | BITS * | bits, | |
unsigned long | masks | |||
) | [static] |
static int any_set_or_all_clr | ( | BITS * | bits, | |
unsigned long | masks | |||
) | [static] |
static int any_set_or_any_clr | ( | BITS * | bits, | |
unsigned long | masks | |||
) | [static] |
static void clr_bits_mask | ( | BITS * | bits, | |
unsigned long | mask | |||
) | [static] |
EXPORT_SYMBOL | ( | rt_bits_delete_u | ) |
EXPORT_SYMBOL | ( | rt_bits_init_u | ) |
EXPORT_SYMBOL | ( | rt_named_bits_delete | ) |
EXPORT_SYMBOL | ( | rt_named_bits_init | ) |
EXPORT_SYMBOL | ( | _rt_bits_wait_timed | ) |
EXPORT_SYMBOL | ( | _rt_bits_wait_until | ) |
EXPORT_SYMBOL | ( | _rt_bits_wait_if | ) |
EXPORT_SYMBOL | ( | _rt_bits_wait | ) |
EXPORT_SYMBOL | ( | rt_bits_signal | ) |
EXPORT_SYMBOL | ( | rt_bits_reset | ) |
EXPORT_SYMBOL | ( | rt_get_bits | ) |
EXPORT_SYMBOL | ( | rt_bits_delete | ) |
EXPORT_SYMBOL | ( | rt_bits_init | ) |
module_exit | ( | __rtai_bits_exit | ) |
module_init | ( | __rtai_bits_init | ) |
MODULE_LICENSE | ( | "GPL" | ) |
static void nop_fun | ( | BITS * | bits, | |
unsigned long | mask | |||
) | [static] |
void reset_rt_fun_entries | ( | struct rt_native_fun_entry * | entry | ) |
Definition at line 1696 of file sched.c.
Referenced by __rtai_bits_exit(), __rtai_mbx_exit(), __rtai_mq_exit(), __rtai_msg_exit(), __rtai_msg_queue_exit(), __rtai_netrpc_exit(), __rtai_sem_exit(), lxrt_exit(), and set_rt_fun_entries().
int rt_bits_delete | ( | BITS * | bits | ) |
Definition at line 162 of file bits.c.
References CHECK_BITS_MAGIC, flags, RT_SCHED_DELAYED, RT_SCHED_READY, RT_SCHED_SEMAPHORE, RTP_OBJREM, and task.
RTAI_SYSCALL_MODE int rt_bits_delete_u | ( | BITS * | bits | ) |
Definition at line 435 of file bits.c.
References rt_bits_delete(), rt_drg_on_adr(), and rt_free().
Here is the call graph for this function:
void rt_bits_init | ( | BITS * | bits, | |
unsigned long | mask | |||
) |
RTAI_SYSCALL_MODE void* rt_bits_init_u | ( | unsigned long | name, | |
unsigned long | mask | |||
) |
Definition at line 418 of file bits.c.
References current, IS_BIT, rt_bits_init(), rt_free(), rt_get_adr(), rt_malloc(), and rt_register().
Here is the call graph for this function:
RTAI_SYSCALL_MODE unsigned long rt_bits_reset | ( | BITS * | bits, | |
unsigned long | mask | |||
) |
Definition at line 198 of file bits.c.
References CHECK_BITS_MAGIC, dequeue_blocked(), flags, RT_SCHED_DELAYED, RT_SCHED_READY, RT_SCHED_SEMAPHORE, and task.
Here is the call graph for this function:
RTAI_SYSCALL_MODE unsigned long rt_bits_signal | ( | BITS * | bits, | |
int | setfun, | |||
unsigned long | masks | |||
) |
Definition at line 227 of file bits.c.
References CHECK_BITS_MAGIC, dequeue_blocked(), exec_fun, flags, RT_SCHED_DELAYED, RT_SCHED_READY, RT_SCHED_SEMAPHORE, task, TEST_FUN, test_fun, and TEST_MASK.
Here is the call graph for this function:
RTAI_SYSCALL_MODE int rt_named_bits_delete | ( | BITS * | bits | ) |
Definition at line 410 of file bits.c.
References rt_bits_delete(), rt_drg_on_adr(), and rt_free().
Here is the call graph for this function:
RTAI_SYSCALL_MODE BITS* rt_named_bits_init | ( | const char * | bits_name, | |
unsigned long | mask | |||
) |
Definition at line 391 of file bits.c.
References IS_BIT, rt_bits_delete(), rt_bits_init(), rt_free(), rt_get_adr(), rt_malloc(), and rt_register().
Here is the call graph for this function:
static void set_bits_mask | ( | BITS * | bits, | |
unsigned long | mask | |||
) | [static] |
static void set_clr_bits_mask | ( | BITS * | bits, | |
unsigned long | masks | |||
) | [static] |
int set_rt_fun_entries | ( | struct rt_native_fun_entry * | entry | ) |
Definition at line 1708 of file sched.c.
Referenced by __rtai_bits_init(), __rtai_mbx_init(), __rtai_mq_init(), __rtai_msg_init(), __rtai_msg_queue_init(), __rtai_netrpc_init(), __rtai_sem_init(), __rtai_shm_init(), and lxrt_init().
Initial value:
Definition at line 144 of file bits.c.
Referenced by _rt_bits_wait(), _rt_bits_wait_if(), _rt_bits_wait_until(), and rt_bits_signal().
struct rt_native_fun_entry rt_bits_entries[] |
Initial value:
{ { { 0, rt_bits_init_u }, BITS_INIT }, { { 0, rt_bits_delete_u }, BITS_DELETE }, { { 0, rt_named_bits_init }, NAMED_BITS_INIT }, { { 0, rt_named_bits_delete }, NAMED_BITS_DELETE }, { { 1, rt_get_bits }, BITS_GET }, { { 1, rt_bits_reset }, BITS_RESET }, { { 1, rt_bits_signal }, BITS_SIGNAL }, { { 1, _rt_bits_wait }, BITS_WAIT }, { { 1, _rt_bits_wait_if }, BITS_WAIT_IF }, { { 1, _rt_bits_wait_until }, BITS_WAIT_UNTIL }, { { 1, _rt_bits_wait_timed }, BITS_WAIT_TIMED }, { { 0, 0 }, 000 } }
Initial value:
{ all_set, any_set, all_clr, any_clr, all_set_and_any_set, all_set_and_all_clr, all_set_and_any_clr, any_set_and_all_clr, any_set_and_any_clr, all_clr_and_any_clr, all_set_or_any_set, all_set_or_all_clr, all_set_or_any_clr, any_set_or_all_clr, any_set_or_any_clr, all_clr_or_any_clr }
Definition at line 134 of file bits.c.
Referenced by _rt_bits_wait(), _rt_bits_wait_if(), _rt_bits_wait_until(), and rt_bits_signal().