Re: [PATCH 0/3] Deferrable timers support for timerfd API
From: Alexey Perevalov
Date: Fri Jan 03 2014 - 12:45:27 EST
On 01/03/2014 03:17 AM, John Stultz wrote:
On 01/02/2014 10:30 AM, Alexey Perevalov wrote:
This version introduces new clockid (CLOCK_DEFERRABLE) , for timerfd_create, instead ofSo why did you make this change?
new flag (TFD_TIMER_DEFERRABLE) for timerfd_settime introduced in previous version.
I looked at alarm timers and found approach of making timer behavior
persistent per file descriptor is better than
changeable by timerfd_settime. I think "end user wake up from suspend"
and "don't wake up in idle" is the same thing on the same abstraction level.
Yes Anton's previous patches worked with CLOCK_MONOTONIC only and I
didn't intend to use it with CLOCK_REALTIME, cause it's hard to me to
find such use case.
Another way - it's stay as was Anton's patch, I mean as flag for the
timerfd_settime, but in original patch set both hrtimer and deferrable
timers initialized in timerfd_create, I think it's not needed. Also
ability to change timer behavior looks not good if you couldn't change
alarm timer behavior, not unified API.
If I'm right, only high resolution timer could be REALTIME, and there is
no deferrable behavior for hrtimer only for timer_list.
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/