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]
Date:	Fri, 03 Oct 2014 14:15:12 +0200
From:	Paul Bolle <pebolle@...cali.nl>
To:	Christoph Lameter <cl@...ux.com>
Cc:	Thomas Gleixner <tglx@...utronix.de>, linux-kernel@...r.kernel.org
Subject: Re: Why do we still have 32 bit counters? Interrupt counters
 overflow within 50 days

On Fri, 2014-10-03 at 06:54 -0500, Christoph Lameter wrote:
> On Fri, 3 Oct 2014, Thomas Gleixner wrote:
> 
> > > Is this the way its intended or should the counters be expanded to 64 bit?
> >
> > There is no reason why we cannot or should not expand them.
> 
> Ok here is a patch to do just that:
> 
> 
> Subject: Increase irq counters to 64 bit
> 
> 
> Irq counters can overflow easily if they are just 32 bit.
> 
> For example the timer interrupt occurs 1000 times per second, so
> it is predictable that the timer interrupt will overflow in
> 
> 
> 2^ 32 / 1000 [interrupts per second] / 86400 [seconds in a day]
> 
> which results in 46 days.

dc -e "1 k 2 32 ^ 1000 / 86400 / p"
49.7

(That was the number I remembered from stories about a ancient Windows
lockup.)

> Other irq counters for devices may wrap even faster for example
> those for high speed networking devices.
> 
> This patch is needed to avoid the counter overflow by increasing
> the counters to 64 bit.
> 
> Signed-off-by: Christoph Lameter <cl@...ux.com>


Paul Bolle


--
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