All of lore.kernel.org
 help / color / mirror / Atom feed
From: Yury Polyanskiy <ypolyans@princeton.edu>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: Joel Becker <joel.becker@oracle.com>,
	linux-kernel@vger.kernel.org, john stultz <johnstul@us.ibm.com>,
	Jan Glauber <jan.glauber@de.ibm.com>
Subject: Re: [PATCH] hangcheck-timer is broken on x86
Date: Fri, 26 Mar 2010 17:52:01 -0400	[thread overview]
Message-ID: <20100326175201.3dbac6ce@penta.localdomain> (raw)
In-Reply-To: <20100326142423.1334d407.akpm@linux-foundation.org>

[-- Attachment #1: Type: text/plain, Size: 1203 bytes --]

On Fri, 26 Mar 2010 14:24:23 -0700
Andrew Morton <akpm@linux-foundation.org> wrote:

> On Tue, 23 Mar 2010 23:36:11 -0400
> Yury Polyanskiy <ypolyans@princeton.edu> wrote:
> 
> > The drivers/char/hangcheck-timer.c is doubly broken. First, the
> > following line overflows unsigned long:
> > # define TIMER_FREQ (HZ*loops_per_jiffy)
> > 
> > Second, and more importantly, loops_per_jiffy has little to do with the conversion from the
> > the time scale of get_cycles() (aka rdtsc) to the time scale of jiffies.
> 
> It's a bit odd to have a driver be this broken on x86_32 for five years
> without anyone noticing.  What are the user-visible effects of these
> shortcomings?

When the overflown value of TIMER_FREQ is abnormally low, it spams the
syslog with KERN_CRIT messages "Hangcheck: hangcheck value past margin!"
But whether it happens or not depends on HZ and lpj in a complex way.
People have hit it occasionally as far as google search can tell. 

> 
> Also, please do send us a Signed-off-by: for this patch, as explained
> in Documentation/SubmittingPatches, thanks.
> 

Sorry.

Signed-off-by: Yury Polyanskiy <polyanskiy@gmail.com>

Thank you Andrew!

Yury

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 198 bytes --]

  reply	other threads:[~2010-03-26 21:52 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-03-24  3:36 [PATCH] hangcheck-timer is broken on x86 Yury Polyanskiy
2010-03-26 21:24 ` Andrew Morton
2010-03-26 21:52   ` Yury Polyanskiy [this message]
2010-03-26 21:46 ` Joel Becker
2010-03-26 22:00   ` Yury Polyanskiy
2010-03-27  0:57     ` Joel Becker
2010-03-27  2:02       ` Yury Polyanskiy
2010-03-27 22:03         ` Joel Becker
2010-03-27 22:51           ` Yury Polyanskiy
2010-03-27 23:36             ` Joel Becker
2010-03-28  2:08               ` Yury Polyanskiy
2010-03-29  1:00   ` john stultz
2010-03-29 14:11     ` Yury Polyanskiy
2010-03-29 16:43       ` john stultz
2010-03-29 17:04         ` Yury Polyanskiy
2010-03-29 18:44           ` john stultz
2010-03-29 19:53             ` Joel Becker
2010-03-29 21:08             ` Yury Polyanskiy
2010-03-29 21:43               ` john stultz
2010-03-29 22:34                 ` Yury Polyanskiy
2010-04-08  0:52                   ` Joel Becker

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20100326175201.3dbac6ce@penta.localdomain \
    --to=ypolyans@princeton.edu \
    --cc=akpm@linux-foundation.org \
    --cc=jan.glauber@de.ibm.com \
    --cc=joel.becker@oracle.com \
    --cc=johnstul@us.ibm.com \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.