Keith Hui has uploaded this change for review.

View Change

nb/intel/i440bx: Die with standard POST code on fatal conditions

When encountering really incompatible memory configurations, post a
standard POST_RAM_FAILURE code when dying. Gone are the "HALT"
messages that no longer serve any good purpose, instead fatal messages
are edited to always end with "!" to make them stand out even with
loglevel prefix off.

Change-Id: Ie1b9e5a0415e4c64b1f4e935689263f62db012b2
Signed-off-by: Keith Hui <buurin@gmail.com>
---
M src/northbridge/intel/i440bx/raminit.c
1 file changed, 26 insertions(+), 9 deletions(-)

git pull ssh://review.coreboot.org:29418/coreboot refs/changes/86/73886/1
diff --git a/src/northbridge/intel/i440bx/raminit.c b/src/northbridge/intel/i440bx/raminit.c
index b3f8780..80ccaed 100644
--- a/src/northbridge/intel/i440bx/raminit.c
+++ b/src/northbridge/intel/i440bx/raminit.c
@@ -8,6 +8,7 @@
#include <device/pci_def.h>
#include <device/smbus_host.h>
#include <console/console.h>
+#include <commonlib/console/post_codes.h>
#include <timestamp.h>
#include "i440bx.h"
#include "raminit.h"
@@ -763,8 +764,8 @@
PRINT_DEBUG("Found DIMM in slot %d\n", i);

if (edo && sd) {
- printk(BIOS_ERR, "Mixing EDO/SDRAM unsupported!\n");
- die("HALT\n");
+ die_with_post_code(POST_RAM_FAILURE,
+ "Mixing EDO/SDRAM unsupported!\n");
}

/* "DRA" is our RPS for the two rows on this DIMM. */
@@ -868,12 +869,12 @@
if (col == 4)
bpr |= 0xc0;
} else {
- printk(BIOS_ERR, "# of banks of DIMM unsupported!\n");
- die("HALT\n");
+ die_with_post_code(POST_RAM_FAILURE,
+ "# of banks of DIMM unsupported!\n");
}
if (dra == -1) {
- printk(BIOS_ERR, "Page size not supported\n");
- die("HALT\n");
+ die_with_post_code(POST_RAM_FAILURE,
+ "Page size not supported!\n");
}

/*
@@ -883,9 +884,9 @@
*/
struct dimm_size sz = spd_get_dimm_size(device);
if ((sz.side1 < 8)) {
- printk(BIOS_ERR, "DIMMs smaller than 8MB per side\n"
- "are not supported on this NB.\n");
- die("HALT\n");
+ die_with_post_code(POST_RAM_FAILURE,
+ "DIMMs smaller than 8MB per side "
+ "are not supported!\n");
}

/* Divide size by 8 to set up the DRB registers. */

To view, visit change 73886. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: Ie1b9e5a0415e4c64b1f4e935689263f62db012b2
Gerrit-Change-Number: 73886
Gerrit-PatchSet: 1
Gerrit-Owner: Keith Hui <buurin@gmail.com>
Gerrit-MessageType: newchange