event.h File Reference
Events handling. More...
#include <cfg/compiler.h>#include "cfg/cfg_proc.h"#include "cfg/cfg_signal.h"Go to the source code of this file.
Defines | |
| #define | event_initNone(e) ((e)->action = event_hook_ignore) |
| Initialize the event e as a no-op. | |
| #define | event_initSoftint(e, f, u) ((e)->action = event_hook_softint,(e)->Ev.Int.func = (f), (e)->Ev.Int.user_data = (u)) |
| Initialize the event e with a software interrupt (call function f, with parameter u). | |
| #define | event_initSignal(e, p, s) ((e)->action = event_hook_signal,(e)->Ev.Sig.sig_proc = (p), (e)->Ev.Sig.sig_bit = (s)) |
| Initialize the event e with a signal (send signal s to process p). | |
Typedefs | |
| typedef void(* | Hook )(void *) |
| User defined callback type. | |
Functions | |
| Event | event_createNone (void) |
| Same as event_initNone(), but returns the initialized event. | |
| Event | event_createSoftint (Hook func, void *user_data) |
| Same as event_initSoftint(), but returns the initialized event. | |
| Event | event_createSignal (struct Process *proc, sigbit_t bit) |
| Same as event_initSignal(), but returns the initialized event. | |
| void | event_do (struct Event *e) |
| Trigger an event. | |
Detailed Description
Events handling.
This module implements a common system for executing a user defined action calling a hook function.
- Version:
- Id
- event.h 2506 2009-04-15 08:29:07Z duplo
Definition in file event.h.
