2 * Linux ethernet bridge
5 * Lennert Buytenhek <buytenh@gnu.org>
7 * $Id: br_private_timer.h,v 1.1 2000/02/18 16:47:13 davem Exp $
9 * This program is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU General Public License
11 * as published by the Free Software Foundation; either version
12 * 2 of the License, or (at your option) any later version.
15 #ifndef _BR_PRIVATE_TIMER_H
16 #define _BR_PRIVATE_TIMER_H
21 unsigned long expires;
24 extern __inline__ void br_timer_clear(struct br_timer *t)
29 extern __inline__ unsigned long br_timer_get_residue(struct br_timer *t)
32 return jiffies - t->expires;
37 extern __inline__ void br_timer_set(struct br_timer *t, unsigned long x)
43 extern __inline__ int br_timer_is_running(struct br_timer *t)
48 extern __inline__ int br_timer_has_expired(struct br_timer *t, unsigned long to)
50 return t->running && time_after_eq(jiffies, t->expires + to);