mirror of
https://github.com/xen-project/xen.git
synced 2026-10-28 18:21:39 +01:00
and optionally running in user-space. Signed-off-by: Mike Wray <mike.wray@hp.com>
41 lines
1.3 KiB
C
41 lines
1.3 KiB
C
/*
|
|
* Copyright (C) 2004 Mike Wray <mike.wray@hp.com>
|
|
*
|
|
* This library is free software; you can redistribute it and/or modify
|
|
* it under the terms of the GNU Lesser General Public License as published by
|
|
* the Free Software Foundation; either version 2.1 of the License, or
|
|
* (at your option) any later version.
|
|
*
|
|
* This library is distributed in the hope that it will be useful,
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
* GNU Lesser General Public License for more details.
|
|
*
|
|
* You should have received a copy of the GNU Lesser General Public License
|
|
* along with this library; if not, write to the Free Software
|
|
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
*/
|
|
|
|
#ifndef _VNET_TIMER_H_
|
|
#define _VNET_TIMER_H_
|
|
|
|
struct Timer;
|
|
|
|
typedef void TimerFn(unsigned long);
|
|
|
|
typedef struct Timer {
|
|
struct Timer *next;
|
|
TimerFn *fn;
|
|
unsigned long data;
|
|
double expiry;
|
|
} Timer;
|
|
|
|
extern void timer_alarm(void);
|
|
extern double time_now(void);
|
|
extern int process_timers(void);
|
|
extern Timer * Timer_set(double delay, TimerFn *fn, unsigned long data);
|
|
extern void Timer_add(Timer *timer);
|
|
extern int Timer_cancel(Timer *timer);
|
|
|
|
#endif /* ! _VNET_TIMER_H_ */
|