From 5f967492e351ea6bc473a6d192fe4e2aafc00b1e Mon Sep 17 00:00:00 2001
From: Patrick Georgi <pgeorgi@google.com>
Date: Mon, 24 Nov 2014 22:15:09 +0100
Subject: intel/sandybridge: make sure to stay in HLT until reboot

It also tells the compiler that we never leave here.

Change-Id: I824569efd46b577588387b29fc7781abf8c42385
Found-by: Coverity Scan
Signed-off-by: Patrick Georgi <patrick@georgi-clan.de>
Reviewed-on: http://review.coreboot.org/7579
Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
Tested-by: build bot (Jenkins)
Reviewed-by: Edward O'Callaghan <eocallaghan@alterapraxis.com>
---
 src/northbridge/intel/sandybridge/raminit_native.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

(limited to 'src')

diff --git a/src/northbridge/intel/sandybridge/raminit_native.c b/src/northbridge/intel/sandybridge/raminit_native.c
index 5c1af4452f..9de39c6768 100644
--- a/src/northbridge/intel/sandybridge/raminit_native.c
+++ b/src/northbridge/intel/sandybridge/raminit_native.c
@@ -3751,7 +3751,9 @@ void init_dram_ddr3(spd_raw_data * spds, int mobile, int min_tck,
 		if (!mrc_cache || mrc_cache->mrc_data_size < sizeof (ctrl)) {
 			/* Failed S3 resume, reset to come up cleanly */
 			outb(0x6, 0xcf9);
-			hlt();
+			while (1) {
+				hlt();
+			}
 		}
 		memcpy(&ctrl, mrc_cache->mrc_data, sizeof (ctrl));
 	}
-- 
cgit v1.2.3