From: Dave Jones <davej@redhat.com>
To: Avi Kivity <avi@argo.co.il>
Cc: Linux Kernel <linux-kernel@vger.kernel.org>
Subject: Re: discriminate single bit error hardware failure from slab corruption.
Date: Thu, 2 Feb 2006 20:46:45 -0500 [thread overview]
Message-ID: <20060203014645.GD10209@redhat.com> (raw)
In-Reply-To: <43E2A784.2070809@argo.co.il>
On Fri, Feb 03, 2006 at 02:44:52AM +0200, Avi Kivity wrote:
> total += hweight8(data[offset+i] ^ POISON_FREE);
>
> > printk(" %02x", (unsigned char)data[offset + i]);
> > }
> > printk("\n");
> >@@ -1019,6 +1023,18 @@ static void dump_line(char *data, int of
> > }
> > }
> > printk("\n");
> >+ switch (total) {
> >+ case 0x36:
> >+ case 0x6a:
> >+ case 0x6f:
> >+ case 0x81:
> >+ case 0xac:
> >+ case 0xd3:
> >+ case 0xd5:
> >+ case 0xea:
> >+ printk (KERN_ERR "Single bit error detected.
> >Possibly bad RAM. Please run memtest86.\n");
> >+ return;
> >+ }
> >
> >
> and a
>
> if (total == 1)
> printk(...);
>
> here? it seems more readable and more correct as well.
More readable ? Are you kidding ?
What I wrote is smack-you-in-the-face-obvious what it's doing.
With your variant, I have to sit down and think it through.
wrt correctness, what do you see wrong with my approach?
Dave
next prev parent reply other threads:[~2006-02-03 1:47 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 [this message]
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
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=20060203014645.GD10209@redhat.com \
--to=davej@redhat.com \
--cc=avi@argo.co.il \
--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.