Changeset View
Changeset View
Standalone View
Standalone View
sys/compat/linuxkpi/common/include/linux/interrupt.h
Show First 20 Lines • Show All 183 Lines • ▼ Show 20 Lines | |||||
/* | /* | ||||
* LinuxKPI tasklet support | * LinuxKPI tasklet support | ||||
*/ | */ | ||||
typedef void tasklet_func_t(unsigned long); | typedef void tasklet_func_t(unsigned long); | ||||
struct tasklet_struct { | struct tasklet_struct { | ||||
TAILQ_ENTRY(tasklet_struct) entry; | TAILQ_ENTRY(tasklet_struct) entry; | ||||
tasklet_func_t *func; | tasklet_func_t *func; | ||||
/* Our state implementation is different. Avoid same name as Linux. */ | |||||
hselasky: Spelling:
impl->implementation :
Our implementation is different. Avoid same name as Linux. | |||||
Done Inline ActionsOk. I shortened it to avoid exceeding 80 chars. johalun: Ok. I shortened it to avoid exceeding 80 chars. | |||||
volatile u_int _state; | |||||
atomic_t count; | |||||
unsigned long data; | unsigned long data; | ||||
}; | }; | ||||
#define DECLARE_TASKLET(name, func, data) \ | #define DECLARE_TASKLET(name, func, data) \ | ||||
struct tasklet_struct name = { { NULL, NULL }, func, data } | struct tasklet_struct name = { { NULL, NULL }, func, ATOMIC_INIT(0), data } | ||||
#define tasklet_hi_schedule(t) tasklet_schedule(t) | #define tasklet_hi_schedule(t) tasklet_schedule(t) | ||||
extern void tasklet_schedule(struct tasklet_struct *); | extern void tasklet_schedule(struct tasklet_struct *); | ||||
extern void tasklet_kill(struct tasklet_struct *); | extern void tasklet_kill(struct tasklet_struct *); | ||||
extern void tasklet_init(struct tasklet_struct *, tasklet_func_t *, | extern void tasklet_init(struct tasklet_struct *, tasklet_func_t *, | ||||
unsigned long data); | unsigned long data); | ||||
extern void tasklet_enable(struct tasklet_struct *); | extern void tasklet_enable(struct tasklet_struct *); | ||||
extern bool tasklet_is_enabled(struct tasklet_struct *); | |||||
extern void tasklet_disable(struct tasklet_struct *); | extern void tasklet_disable(struct tasklet_struct *); | ||||
extern int tasklet_trylock(struct tasklet_struct *); | |||||
extern void tasklet_unlock(struct tasklet_struct *); | |||||
extern void tasklet_unlock_wait(struct tasklet_struct *ts); | |||||
#endif /* _LINUX_INTERRUPT_H_ */ | #endif /* _LINUX_INTERRUPT_H_ */ |
Spelling:
impl->implementation :
Our implementation is different. Avoid same name as Linux.