From: Dave Jones <davej@redhat.com>
To: Roland Dreier <rdreier@cisco.com>
Cc: Avi Kivity <avi@argo.co.il>, Linux Kernel <linux-kernel@vger.kernel.org>
Subject: Re: discriminate single bit error hardware failure from slab corruption.
Date: Fri, 3 Feb 2006 00:03:30 -0500 [thread overview]
Message-ID: <20060203050330.GA3171@redhat.com> (raw)
In-Reply-To: <ada3bj1xde1.fsf@cisco.com>
On Thu, Feb 02, 2006 at 08:41:26PM -0800, Roland Dreier wrote:
> Dave> Hmm, I made a mistake in my maths somewhere, and some of
> Dave> those values are incorrect, so having the compiler do the
> Dave> work would have stopped me screwing up, but once the correct
> Dave> values are used, I doubt there's ever a really compelling
> Dave> reason to change the slab poison pattern.
>
> But Avi is still correct about false positives. For example, if
> something stomps on the slab poison and leaves it as
>
> e0 08 03 00
>
> then that will add up to eb and still trigger your message, even
> though it's far from a single bit error.
Ah, now I see the point Avi was making.
> Maybe making the loop be something like
>
> unsigned char total = 0, bad_count = 0;
> printk(KERN_ERR "%03x:", offset);
> for (i = 0; i < limit; i++) {
> if (data[offset+i] != POISON_FREE) {
> total += data[offset+i];
> ++bad_count;
> }
> printk(" %02x", (unsigned char)data[offset + i]);
> }
>
> and then you can put
>
> if (bad_count == 1)
>
> before the switch statement.
>
> I have to admit that Avi's code seems clearer to me too, though.
I'm easily persuaded either way really, as long as
we arrive at a desirable end-result ;)
Dave
next prev parent reply other threads:[~2006-02-03 5:03 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-02-02 19:24 discriminate single bit error hardware failure from slab corruption Dave Jones
2006-02-02 19:28 ` Randy.Dunlap
2006-02-02 19:38 ` Jesper Juhl
2006-02-02 19:53 ` Pekka Enberg
2006-02-03 0:44 ` Avi Kivity
2006-02-03 1:46 ` Dave Jones
2006-02-03 2:05 ` Avi Kivity
2006-02-03 4:20 ` Dave Jones
2006-02-03 4:41 ` Roland Dreier
2006-02-03 5:03 ` Dave Jones [this message]
2006-02-03 14:12 ` Jan Engelhardt
2006-02-03 11:05 ` Olivier Galibert
2006-02-06 20:19 ` Pavel Machek
2006-02-03 14:09 ` Jan Engelhardt
-- strict thread matches above, loose matches on Subject: below --
2006-02-03 9:25 linux
2006-02-03 14:14 ` Jan Engelhardt
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=20060203050330.GA3171@redhat.com \
--to=davej@redhat.com \
--cc=avi@argo.co.il \
--cc=linux-kernel@vger.kernel.org \
--cc=rdreier@cisco.com \
/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.