linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Hugh Dickins <hugh@veritas.com>
To: "Rafał Miłecki" <zajec5@gmail.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>,
	Jeremy Fitzhardinge <jeremy@goop.org>,
	Yinghai Lu <yhlu.kernel@gmail.com>, Ingo Molnar <mingo@elte.hu>,
	Alan Jenkins <alan-jenkins@tuffmail.co.uk>,
	"H. Peter Anvin" <hpa@zytor.com>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH RFC] x86: check for and defend against BIOS memory corruption
Date: Fri, 29 Aug 2008 11:24:44 +0100 (BST)	[thread overview]
Message-ID: <Pine.LNX.4.64.0808291120540.8561@blonde.site> (raw)
In-Reply-To: <b170af450808290313x574b4561i3048ffca3e4da197@mail.gmail.com>

[-- Attachment #1: Type: TEXT/PLAIN, Size: 1203 bytes --]

> On Fri, 29 Aug 2008, Rafał Miłecki wrote:
> 
> Out of current discussion I tried using s2ram on patched kernel (I did
> not try s2ram earlier, my problem was (un)plugging HDMI - some ACPI
> code probably).
> 
> Corruption output is quite huge, I attached it to bug report:
> http://bugzilla.kernel.org/show_bug.cgi?id=11237
> http://bugzilla.kernel.org/attachment.cgi?id=17526

Not quite the output we were expecting!  I've not got around to trying
it yet, so beware, but I think Jeremy's patch needs the following on top.
Or you may prefer to wait until one of us reports that it is now working
as intended.

--- a/arch/x86/kernel/setup.c	2008-08-29 11:17:16.000000000 +0100
+++ b/arch/x86/kernel/setup.c	2008-08-29 11:19:24.000000000 +0100
@@ -636,11 +636,12 @@ void check_for_bios_corruption(void)
 		unsigned long *addr = __va(scan_areas[i].addr);
 		unsigned long size = scan_areas[i].size;
 
-		for(; size; addr++, size--) {
+		for(; size; addr++, size -= sizeof(unsigned long)) {
 			if (!*addr)
 				continue;
 			printk(KERN_ERR "Corrupted low memory at %p (%lx phys) = %08lx\n",
 			       addr, __pa(addr), *addr);
+			*addr = 0;
 			corruption = 1;
 		}
 	}

  parent reply	other threads:[~2008-08-29 10:25 UTC|newest]

Thread overview: 35+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-08-28 19:52 [PATCH RFC] x86: check for and defend against BIOS memory corruption Jeremy Fitzhardinge
2008-08-29  1:49 ` Yinghai Lu
2008-08-29  3:28   ` Jeremy Fitzhardinge
2008-08-29  9:25     ` Alan Cox
2008-08-29 10:13       ` Rafał Miłecki
2008-08-29 10:06         ` Alan Cox
2008-08-29 10:24         ` Hugh Dickins [this message]
2008-08-29 11:54           ` Rafał Miłecki
2008-08-29 12:09             ` Alan Jenkins
2008-08-29 13:21               ` Hugh Dickins
2008-08-29 16:30                 ` Rafał Miłecki
2008-08-29 17:39                 ` Rafał Miłecki
2008-09-04 19:42                   ` Rafał Miłecki
2008-09-04 20:23                     ` Hugh Dickins
2008-09-04 23:04                       ` Jeremy Fitzhardinge
2008-09-06 18:09                         ` Ingo Molnar
2008-08-29 14:08           ` Jeremy Fitzhardinge
2008-08-29 14:18       ` Jeremy Fitzhardinge
2008-08-29 20:31     ` Kasper Sandberg
2008-08-30  1:15       ` Jeremy Fitzhardinge
2008-08-29  6:20 ` Rafał Miłecki
2008-08-29  6:45   ` Ingo Molnar
2008-08-29  7:21     ` Jeremy Fitzhardinge
2008-08-29  7:30       ` Ingo Molnar
2008-08-29  8:02         ` Jeremy Fitzhardinge
2008-08-29  7:22   ` Jeremy Fitzhardinge
2008-08-29  8:14 ` Hugh Dickins
2008-08-29 14:48   ` Jeremy Fitzhardinge
2008-08-29 17:20     ` H. Peter Anvin
2008-09-08 11:35     ` Hugh Dickins
2008-09-08 17:16       ` Jeremy Fitzhardinge
2008-09-08 19:14         ` Hugh Dickins
2008-09-08 19:45           ` Jeremy Fitzhardinge
2008-08-29 17:02   ` H. Peter Anvin
2008-08-29 17:03   ` H. Peter Anvin

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=Pine.LNX.4.64.0808291120540.8561@blonde.site \
    --to=hugh@veritas.com \
    --cc=alan-jenkins@tuffmail.co.uk \
    --cc=alan@lxorguk.ukuu.org.uk \
    --cc=hpa@zytor.com \
    --cc=jeremy@goop.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=yhlu.kernel@gmail.com \
    --cc=zajec5@gmail.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).