Merge master.kernel.org:/pub/scm/linux/kernel/git/wim/linux-2.6-watchdog
[sfrench/cifs-2.6.git] / include / linux / hrtimer.h
index 93830158348e711ad50bc921dec68dd34f649d17..306acf1dc6d58b54aef407d2ab9e370ff18eaa99 100644 (file)
@@ -57,6 +57,19 @@ struct hrtimer {
        struct hrtimer_base     *base;
 };
 
+/**
+ * struct hrtimer_sleeper - simple sleeper structure
+ *
+ * @timer:     embedded timer structure
+ * @task:      task to wake up
+ *
+ * task is set to NULL, when the timer expires.
+ */
+struct hrtimer_sleeper {
+       struct hrtimer timer;
+       struct task_struct *task;
+};
+
 /**
  * struct hrtimer_base - the timer base for a specific clock
  *
@@ -67,7 +80,7 @@ struct hrtimer {
  * @first:             pointer to the timer node which expires first
  * @resolution:                the resolution of the clock, in nanoseconds
  * @get_time:          function to retrieve the current time of the clock
- * @get_sofirq_time:   function to retrieve the current time from the softirq
+ * @get_softirq_time:  function to retrieve the current time from the softirq
  * @curr_timer:                the timer which is executing a callback right now
  * @softirq_time:      the time when running the hrtimer queue in the softirq
  */
@@ -127,6 +140,9 @@ extern long hrtimer_nanosleep(struct timespec *rqtp,
                              const enum hrtimer_mode mode,
                              const clockid_t clockid);
 
+extern void hrtimer_init_sleeper(struct hrtimer_sleeper *sl,
+                                struct task_struct *tsk);
+
 /* Soft interrupt function to run the hrtimer queues: */
 extern void hrtimer_run_queues(void);