From: mark gross <mgross@linux.intel.com>
To: akpm@osdl.org
Cc: linux-kernel@vger.kernel.org,
bluesmoke-devel@lists.sourceforge.net, mark.gross@intel.com
Subject: [PATCH] EDAC Coexistance with BIOS
Date: Wed, 3 May 2006 12:58:48 -0700 [thread overview]
Message-ID: <20060503195848.GA13018@linux.intel.com> (raw)
The following patch addresses the issue of EDAC/BIOS coexistence for the
e752x chip-sets. It is a patch agaist 2.6.17-rc3-mm1.
We have found a problem where the BIOS will start the system with the error
registers (dev0:fun1) hidden and assuming it has exclusive access to them.
The edac driver violates this assumption.
The work around this patch offers is to honor the hidden-ness as an
indication that it is not safe to use those registers.
Please apply
Signed-off-by: Mark Gross <mark.gross@intel.com>
Thanks,
diff -urN -X linux-2.6.17-rc3-mm1/Documentation/dontdiff linux-2.6.17-rc3-mm1/drivers/edac/e752x_edac.c linux-2.6.17-rc3-mm1_edac/drivers/edac/e752x_edac.c
--- linux-2.6.17-rc3-mm1/drivers/edac/e752x_edac.c 2006-05-03 11:31:04.000000000 -0700
+++ linux-2.6.17-rc3-mm1_edac/drivers/edac/e752x_edac.c 2006-05-03 11:20:54.000000000 -0700
@@ -25,6 +25,8 @@
#include <linux/slab.h>
#include "edac_mc.h"
+static int force_function_unhide;
+
#define e752x_printk(level, fmt, arg...) \
edac_printk(level, "e752x", fmt, ##arg)
@@ -782,8 +784,16 @@
debugf0("%s(): mci\n", __func__);
debugf0("Starting Probe1\n");
- /* enable device 0 function 1 */
+ /* check to see if device 0 function 1 is enabled; if it isn't, we
+ * assume the BIOS has reserved it for a reason and is expecting
+ * exclusive access, we take care not to violate that assumption and
+ * fail the probe. */
pci_read_config_byte(pdev, E752X_DEVPRES1, &stat8);
+ if (!force_function_unhide && !(stat8 & (1 << 5))) {
+ printk(KERN_INFO "Contact your BIOS vendor to see if the "
+ "E752x error registers can be safely un-hidden\n");
+ goto fail;
+ }
stat8 |= (1 << 5);
pci_write_config_byte(pdev, E752X_DEVPRES1, stat8);
@@ -1063,3 +1073,8 @@
MODULE_LICENSE("GPL");
MODULE_AUTHOR("Linux Networx (http://lnxi.com) Tom Zimmerman\n");
MODULE_DESCRIPTION("MC support for Intel e752x memory controllers");
+
+module_param(force_function_unhide, int, 0444);
+MODULE_PARM_DESC(force_function_unhide, "if BIOS sets Dev0:Fun1 up as hidden:"
+" 1=force unhide and hope BIOS doesn't fight driver for Dev0:Fun1 access");
+
reply other threads:[~2006-05-03 19:50 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20060503195848.GA13018@linux.intel.com \
--to=mgross@linux.intel.com \
--cc=akpm@osdl.org \
--cc=bluesmoke-devel@lists.sourceforge.net \
--cc=linux-kernel@vger.kernel.org \
--cc=mark.gross@intel.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