diff options
author | Stefan Reinauer <reinauer@chromium.org> | 2012-06-18 14:38:40 -0700 |
---|---|---|
committer | Ronald G. Minnich <rminnich@gmail.com> | 2012-07-25 00:35:45 +0200 |
commit | 696262bd99fb7e4177dbce533ae50a287871d830 (patch) | |
tree | eb4511782b8f812d28c78ca9569d720b708ccabb | |
parent | 0c32c9795b1cb2270f677e55ba38e7d293e723ee (diff) |
More descriptive error messages in Sandybridge raminit code
MRC returns specific error codes; print the according error
message if we know what it means.
Change-Id: Iaaf1512b9d577d4291fccfb94d879043ab5b11b5
Signed-off-by: Stefan Reinauer <reinauer@google.com>
Reviewed-on: http://review.coreboot.org/1289
Tested-by: build bot (Jenkins)
Reviewed-by: Ronald G. Minnich <rminnich@gmail.com>
-rw-r--r-- | src/northbridge/intel/sandybridge/raminit.c | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/src/northbridge/intel/sandybridge/raminit.c b/src/northbridge/intel/sandybridge/raminit.c index 0df86d6187..bb8b25cd25 100644 --- a/src/northbridge/intel/sandybridge/raminit.c +++ b/src/northbridge/intel/sandybridge/raminit.c @@ -249,8 +249,17 @@ void sdram_initialize(struct pei_data *pei_data) "call *%%ecx\n\t" :"=a" (rv) : "c" (entry), "a" (pei_data)); if (rv) { - printk(BIOS_ERR, "MRC returned %x\n", rv); - die("Nonzero MRC return value\n"); + switch (rv) { + case -1: + printk(BIOS_ERR, "PEI version mismatch."); + break; + case -2: + printk(BIOS_ERR, "Invalid memory frequency.\n"); + break; + default: + printk(BIOS_ERR, "MRC returned %x.\n", rv); + } + die("Nonzero MRC return value.\n"); } } else { die("UEFI PEI System Agent not found.\n"); |