Re: [PATCH 1/2] posix-timers: Prevents overrun counter overflow

2015-01-24 Thread Thomas Gleixner
On Fri, 23 Jan 2015, Daniel Church wrote: > + overruns = (unsigned int) hrtimer_forward(timer, > + timer->base->get_time(), > + timr->it.real.interval); > + if (overruns >= delaytimer_max || > + (timr->it_ov

[PATCH 1/2] posix-timers: Prevents overrun counter overflow

2015-01-23 Thread Daniel Church
If a timer overruns too many times before a call to timer_getoverrun the overrun count can overflow and go negative. Adds delaytimer_max value to cap overrun count and prevent overflow. Signed-off-by: Daniel Church --- include/linux/posix-timers.h | 3 +++ kernel/time/posix-timers.c | 42 +++