Re: [PATCH 7/7] [hrtimers] Set correct initial expiry time for relative SIGEV_NONE timers

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

 



Thomas Gleixner <[email protected]> wrote:
>
> 
> The expiry time for relative timers with SIGEV_NONE set was never
> updated to the correct value.
> 

Ahem.

> +		if (mode == HRTIMER_REL)
> +			timer->expires = ktime_add(timer-expires,
> +						   timer->base->get_time());

doesn't compile, hence isn't tested.

Please confirm that with the below fix we get something which works OK?

--- devel/kernel/posix-timers.c~hrtimers-set-correct-initial-expiry-time-for-relative-fix	2006-01-19 21:08:44.000000000 -0800
+++ devel-akpm/kernel/posix-timers.c	2006-01-19 21:08:44.000000000 -0800
@@ -727,7 +727,7 @@ common_timer_set(struct k_itimer *timr, 
 	if (((timr->it_sigev_notify & ~SIGEV_THREAD_ID) == SIGEV_NONE)) {
 		/* Setup correct expiry time for relative timers */
 		if (mode == HRTIMER_REL)
-			timer->expires = ktime_add(timer-expires,
+			timer->expires = ktime_add(timer->expires,
 						   timer->base->get_time());
 		return 0;
 	}
_
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux