All pastes #745828 Raw Edit

possible CAR fix

public text v1 · immutable
·published 2007-10-22 18:39 UTC
rendered paste body
Index: LinuxBIOSv2/src/northbridge/amd/amdk8/raminit_f_dqs.c
===================================================================
--- LinuxBIOSv2.orig/src/northbridge/amd/amdk8/raminit_f_dqs.c	2007-10-22 08:33:37.000000000 -0600
+++ LinuxBIOSv2/src/northbridge/amd/amdk8/raminit_f_dqs.c	2007-10-22 08:35:17.000000000 -0600
@@ -1987,6 +1987,16 @@
 	struct sys_info *sysinfox = ((CONFIG_LB_MEM_TOPK<<10) - DCACHE_RAM_GLOBAL_VAR_SIZE);
 	wait_till_sysinfo_in_ram(); // use pci to get it
 
+	/* In SimNow, when we get to this point, CAR is disabled, so
+	 * our stack pointer points to never-never land, andjust it.
+	 */
+
+	__asm__ volatile (
+		"subl   %0, %%ebp\n\t"
+		"subl   %0, %%esp\n\t"
+		::"a"( (DCACHE_RAM_BASE + DCACHE_RAM_SIZE)- (CONFIG_LB_MEM_TOPK<<10) )
+	);
+
 	if(sysinfox->mem_trained[nodeid] == 0x80) {
 	#if 0
 		sysinfo->tom_k = sysinfox->tom_k;