lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Mon, 24 Sep 2007 22:28:05 +0200
From:	Thomas Gleixner <tglx@...utronix.de>
To:	Davide Libenzi <davidel@...ilserver.org>
Cc:	Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
	Michael Kerrisk <mtk-manpages@....net>,
	Andrew Morton <akpm@...ux-foundation.org>,
	Linus Torvalds <torvalds@...ux-foundation.org>
Subject: Re: [patch 1/4] new timerfd API v2 - introduce a new
	hrtimer_forward_now() function


On Mon, 2007-09-24 at 13:22 -0700, Davide Libenzi wrote:
> I think that advancing the timer against the timer's current "now" can
> be a pretty common usage, so, w/out exposing hrtimer's internals, we add
> a new hrtimer_forward_now() function.
> 
> 
> 
> Signed-off-by: Davide Libenzi <davidel@...ilserver.org>

Reviewed-and-Acked-by: Thomas Gleixner <tglx@...utronix.de>

> 
> - Davide
> 
> 
> ---
>  include/linux/hrtimer.h |    7 +++++++
>  1 file changed, 7 insertions(+)
> 
> Index: linux-2.6.mod/include/linux/hrtimer.h
> ===================================================================
> --- linux-2.6.mod.orig/include/linux/hrtimer.h	2007-09-24 12:27:20.000000000 -0700
> +++ linux-2.6.mod/include/linux/hrtimer.h	2007-09-24 12:29:39.000000000 -0700
> @@ -298,6 +298,13 @@
>  extern unsigned long
>  hrtimer_forward(struct hrtimer *timer, ktime_t now, ktime_t interval);
>  
> +/* Forward a hrtimer so it expires after the hrtimer's current now */
> +static inline unsigned long hrtimer_forward_now(struct hrtimer *timer,
> +						ktime_t interval)
> +{
> +	return hrtimer_forward(timer, timer->base->get_time(), interval);
> +}
> +
>  /* Precise sleep: */
>  extern long hrtimer_nanosleep(struct timespec *rqtp,
>  			      struct timespec __user *rmtp,
> 

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ