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] [thread-next>] [day] [month] [year] [list]
Message-Id: <1160589297.3000.389.camel@laptopd505.fenrus.org>
Date:	Wed, 11 Oct 2006 19:54:57 +0200
From:	Arjan van de Ven <arjan@...ux.intel.com>
To:	Christoph Hellwig <hch@...radead.org>
Cc:	linux-kernel@...r.kernel.org, akpm@...l.org, mingo@...e.hu
Subject: Re: [patch 0/2] Introduce round_jiffies() to save spurious wakeups

On Wed, 2006-10-11 at 18:23 +0100, Christoph Hellwig wrote:
> On Tue, Oct 10, 2006 at 06:02:45PM +0200, Arjan van de Ven wrote:
> > Hi,
> > 
> > the following 2 patches will introduce the round_jiffies() api and users
> > thereof. 
> > 
> > The general idea is that by rounding the jiffies for certain timers to
> > the next whole second will make those timers all happen at the same
> > time; and thus reduce the number of times the cpu has to wake up to
> > service timers (this assumes a tickless kernel)
> > 
> > Obviously only timers where the exact time of firing isn't so important
> > can do this; several of the recurring "always live" timers of the kernel
> > are of this kind, they want "about once a second" or "about once every 4
> > seconds" and such, and don't really care about the exact jiffy in which
> > they fire.
> > 
> > An alternative would have been to introduce mod_timer_rounded() or
> > somesuch APIs (but there's many variants that take jiffies); I feel that
> > an explicit caller based rounding actually is quite reasonable.
> 
> I think the API you proposed is horrible.  Having jiffies exposed in
> ani API is a mistake, and adding more makes this problem worse.  

and other people like Linus disagree with you.

> I'd suggest
> to start with Alan's patches that add a timer variant that takes a miliseconds
> argument instead of jiffies and add a _rounded varaint to it that has
> a new parameter that specifies the precision.

it's half a solution; there's many apis that currently take either
absolute or relative jiffies, and want rounding. Duplicating that lot
doesn't look like the best idea either...

-
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