Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/external/bsd/drm2/include/linux Add Linux timer_pending ...



details:   https://anonhg.NetBSD.org/src/rev/af89ad5550cf
branches:  trunk
changeset: 801989:af89ad5550cf
user:      riastradh <riastradh%NetBSD.org@localhost>
date:      Tue Aug 26 17:26:05 2014 +0000

description:
Add Linux timer_pending and del_timer.

diffstat:

 sys/external/bsd/drm2/include/linux/timer.h |  16 +++++++++++++++-
 1 files changed, 15 insertions(+), 1 deletions(-)

diffs (36 lines):

diff -r f3fe6a0b1375 -r af89ad5550cf sys/external/bsd/drm2/include/linux/timer.h
--- a/sys/external/bsd/drm2/include/linux/timer.h       Tue Aug 26 17:13:42 2014 +0000
+++ b/sys/external/bsd/drm2/include/linux/timer.h       Tue Aug 26 17:26:05 2014 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: timer.h,v 1.4 2014/07/16 20:56:25 riastradh Exp $      */
+/*     $NetBSD: timer.h,v 1.5 2014/08/26 17:26:05 riastradh Exp $      */
 
 /*-
  * Copyright (c) 2013 The NetBSD Foundation, Inc.
@@ -83,12 +83,26 @@
 }
 
 static inline void
+del_timer(struct timer_list *timer)
+{
+
+       callout_stop(&timer->tl_callout);
+}
+
+static inline void
 del_timer_sync(struct timer_list *timer)
 {
 
        callout_halt(&timer->tl_callout, NULL);
 }
 
+static inline bool
+timer_pending(struct timer_list *timer)
+{
+
+       return callout_pending(&timer->tl_callout);
+}
+
 /*
  * XXX This is bogus -- the Linux version does various machinations to
  * give some jitter so that stuff doesn't wake up all at once.



Home | Main Index | Thread Index | Old Index