blob: 665add4b2105f49112cfa935d066ef4bb8842186 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
/*
* libdect timer handling
*
* Copyright (c) 2009-2010 Patrick McHardy <kaber@trash.net>
*/
#ifndef _LIBDECT_TIMER_H
#define _LIBDECT_TIMER_H
#include <utils.h>
#include <dect/timer.h>
struct dect_handle;
enum dect_timer_state {
DECT_TIMER_STOPPED,
DECT_TIMER_RUNNING,
};
/**
* struct dect_timer - libdect timer
*
* @callback: callback to invoke on timer expiry
* @data: libdect internal data
* @state: libdect internal state
* @priv: libdect user private timer storage
*/
struct dect_timer {
void (*callback)(struct dect_handle *,
struct dect_timer *);
void *data;
enum dect_timer_state state;
uint8_t priv[] __aligned(__alignof__(uint64_t));
};
#endif /* _LIBDECT_TIMER_H */
|