blob: 071a7592741e1d1ca4b5dbf6a5829c55809d36df [file] [log] [blame]
The Android Open Source Project1dc9e472009-03-03 19:28:35 -08001/****************************************************************************
2 ****************************************************************************
3 ***
4 *** This header was automatically generated from a Linux kernel header
5 *** of the same name, to make information necessary for userspace to
6 *** call into the kernel available to libc. It contains only constants,
7 *** structures, and macros generated from the original header, and thus,
8 *** contains no copyrightable information.
9 ***
10 ****************************************************************************
11 ****************************************************************************/
12#ifndef _LINUX_TIMER_H
13#define _LINUX_TIMER_H
Ben Cheng4b29af02012-03-07 16:14:53 -080014
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080015#include <linux/list.h>
16#include <linux/spinlock.h>
17#include <linux/stddef.h>
Ben Cheng4b29af02012-03-07 16:14:53 -080018
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080019struct tvec_t_base_s;
Ben Cheng4b29af02012-03-07 16:14:53 -080020
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080021struct timer_list {
22 struct list_head entry;
23 unsigned long expires;
Ben Cheng4b29af02012-03-07 16:14:53 -080024
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080025 void (*function)(unsigned long);
26 unsigned long data;
Ben Cheng4b29af02012-03-07 16:14:53 -080027
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080028 struct tvec_t_base_s *base;
29};
Ben Cheng4b29af02012-03-07 16:14:53 -080030
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080031#define TIMER_INITIALIZER(_function, _expires, _data) { .function = (_function), .expires = (_expires), .data = (_data), .base = &boot_tvec_bases, }
Ben Cheng4b29af02012-03-07 16:14:53 -080032
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080033#define DEFINE_TIMER(_name, _function, _expires, _data) struct timer_list _name = TIMER_INITIALIZER(_function, _expires, _data)
Ben Cheng4b29af02012-03-07 16:14:53 -080034
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080035#define try_to_del_timer_sync(t) del_timer(t)
36#define del_timer_sync(t) del_timer(t)
37#define del_singleshot_timer_sync(t) del_timer_sync(t)
Ben Cheng4b29af02012-03-07 16:14:53 -080038
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080039struct hrtimer;
Ben Cheng4b29af02012-03-07 16:14:53 -080040
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080041#endif