summaryrefslogtreecommitdiffstats
path: root/sys
diff options
context:
space:
mode:
authorjhb <jhb@FreeBSD.org>2008-06-07 03:07:32 +0000
committerjhb <jhb@FreeBSD.org>2008-06-07 03:07:32 +0000
commit0c94928735a0c1b2c8e69e4b676f2b4ad29062db (patch)
tree010445162a2883286aad189da29dfc8d9b519ded /sys
parentf031db47eec4fc1f21691d8473d3a50461c3909b (diff)
downloadFreeBSD-src-0c94928735a0c1b2c8e69e4b676f2b4ad29062db.zip
FreeBSD-src-0c94928735a0c1b2c8e69e4b676f2b4ad29062db.tar.gz
Workaround a bug in the BIOS of Dell R900 machines. Specifically, each
entry in the SMAP is a 20 byte structure and they are queried from the BIOS via sucessive BIOS calls. Due to an apparent bug in the R900's BIOS, for some SMAP requests the BIOS overflows the 20 byte buffer trashing a few bytes of memory immediately after the SMAP structure. As a workaround, add 8 bytes of padding after the SMAP structure used in the loader for SMAP queries. PR: i386/122668 Submitted by: Mike Hibler mike flux.utah.edu, silby MFC after: 3 days
Diffstat (limited to 'sys')
-rw-r--r--sys/boot/i386/libi386/biossmap.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/sys/boot/i386/libi386/biossmap.c b/sys/boot/i386/libi386/biossmap.c
index 5a617f7..51f015a 100644
--- a/sys/boot/i386/libi386/biossmap.c
+++ b/sys/boot/i386/libi386/biossmap.c
@@ -39,7 +39,10 @@ __FBSDID("$FreeBSD$");
#include "libi386.h"
#include "btxv86.h"
-static struct bios_smap smap;
+static struct {
+ struct bios_smap _smap_entry;
+ char pad[8]; /* Bad BIOS writer, no cookie! */
+} smap;
static struct bios_smap *smapbase;
static int smaplen;
OpenPOWER on IntegriCloud