lkml.org 
[lkml]   [2017]   [May]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[patch 19/26] posix-timers: Add cancel/arm callbacks
Add timer_try_to_cancel() and timer_arm() callbacks to kclock which allow
to make common_timer_set() usable by both hrtimer and alarmtimer based
clocks.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
---
include/linux/posix-timers.h | 3 +++
1 file changed, 3 insertions(+)

Index: b/include/linux/posix-timers.h
===================================================================
--- a/include/linux/posix-timers.h
+++ b/include/linux/posix-timers.h
@@ -126,6 +126,9 @@ struct k_clock {
void (*timer_rearm)(struct k_itimer *timr);
int (*timer_forward)(struct k_itimer *timr, ktime_t now);
ktime_t (*timer_remaining)(struct k_itimer *timr, ktime_t now);
+ int (*timer_try_to_cancel)(struct k_itimer *timr);
+ void (*timer_arm)(struct k_itimer *timr, ktime_t expires,
+ bool absolute, bool sigev_none);
};

void run_posix_cpu_timers(struct task_struct *task);

\
 
 \ /
  Last update: 2017-05-30 23:43    [W:0.367 / U:0.060 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site