AMD K8 fam10-15: Consolidate post_cache_as_ram call
Change-Id: I5e7890aafbc8c80716ee49690e306482a482a863 Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com> Reviewed-on: https://review.coreboot.org/20573 Reviewed-by: Arthur Heymans <arthur@aheymans.xyz> Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Tested-by: Raptor Engineering Automated Test Stand <noreply@raptorengineeringinc.com>
This commit is contained in:
parent
b98391c0ee
commit
90e07b460c
|
@ -598,6 +598,8 @@ CAR_FAM10_ap_out:
|
|||
|
||||
call cache_as_ram_main
|
||||
|
||||
call post_cache_as_ram
|
||||
|
||||
/* We will not go back. */
|
||||
|
||||
post_code(0xaf) /* Should never see this POST code. */
|
||||
|
|
|
@ -209,8 +209,6 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
sb800_before_pci_init();
|
||||
|
||||
post_code(0x42);
|
||||
post_cache_as_ram(); /* BSP switch stack to ram, copy then execute LB. */
|
||||
post_code(0x43); /* Should never see this post code. */
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -204,8 +204,6 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
sb800_before_pci_init();
|
||||
|
||||
post_code(0x42);
|
||||
post_cache_as_ram(); /* BSP switch stack to ram, copy then execute LB. */
|
||||
post_code(0x43); /* Should never see this post code. */
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -141,6 +141,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
|
||||
rs690_before_pci_init();
|
||||
sb600_before_pci_init();
|
||||
|
||||
post_cache_as_ram();
|
||||
}
|
||||
|
|
|
@ -144,6 +144,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
|
||||
rs780_before_pci_init();
|
||||
sb7xx_51xx_before_pci_init();
|
||||
|
||||
post_cache_as_ram();
|
||||
}
|
||||
|
|
|
@ -220,8 +220,6 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
sb7xx_51xx_before_pci_init();
|
||||
|
||||
post_code(0x42);
|
||||
post_cache_as_ram(); // BSP switch stack to ram, copy then execute LB.
|
||||
post_code(0x43); // Should never see this post code.
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -153,6 +153,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
|
||||
rs690_before_pci_init();
|
||||
sb600_before_pci_init();
|
||||
|
||||
post_cache_as_ram();
|
||||
}
|
||||
|
|
|
@ -194,6 +194,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
/* Need to use TMICT to synchronize FID/VID */
|
||||
|
||||
sdram_initialize(sysinfo->nodes, sysinfo->ctrl, sysinfo);
|
||||
|
||||
post_cache_as_ram(); /* bsp swtich stack to RAM and copy sysinfo RAM now */
|
||||
}
|
||||
|
|
|
@ -313,8 +313,6 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
amdmct_cbmem_store_info(sysinfo);
|
||||
|
||||
post_code(0x42);
|
||||
post_cache_as_ram(); /* BSP switch stack to ram, copy then execute LB. */
|
||||
post_code(0x43); /* Should never see this post code. */
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -205,8 +205,6 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
sb7xx_51xx_before_pci_init();
|
||||
|
||||
post_code(0x42);
|
||||
post_cache_as_ram(); /* BSP switch stack to ram, copy then execute LB. */
|
||||
post_code(0x43); /* Should never see this post code. */
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -210,6 +210,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
|
||||
rs780_before_pci_init();
|
||||
sb7xx_51xx_before_pci_init();
|
||||
|
||||
post_cache_as_ram();
|
||||
}
|
||||
|
|
|
@ -147,6 +147,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
print_pci_devices();
|
||||
dump_pci_devices();
|
||||
#endif
|
||||
|
||||
post_cache_as_ram();
|
||||
}
|
||||
|
|
|
@ -203,5 +203,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
|
||||
enable_smbus();
|
||||
sdram_initialize(sysinfo->nodes, sysinfo->ctrl, sysinfo);
|
||||
post_cache_as_ram();
|
||||
}
|
||||
|
|
|
@ -203,5 +203,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
|
||||
enable_smbus();
|
||||
sdram_initialize(sysinfo->nodes, sysinfo->ctrl, sysinfo);
|
||||
post_cache_as_ram();
|
||||
}
|
||||
|
|
|
@ -179,5 +179,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
smbus_write_byte(0x4a, 0x03, 0x04 | mask);
|
||||
|
||||
sdram_initialize(sysinfo->nodes, sysinfo->ctrl, sysinfo);
|
||||
post_cache_as_ram();
|
||||
}
|
||||
|
|
|
@ -581,9 +581,6 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
pci_write_config16(PCI_DEV(0, 0x14, 0), 0x54, 0x0707);
|
||||
pci_write_config16(PCI_DEV(0, 0x14, 0), 0x56, 0x0bb0);
|
||||
pci_write_config16(PCI_DEV(0, 0x14, 0), 0x5a, 0x0ff0);
|
||||
|
||||
post_cache_as_ram(); // BSP switch stack to ram, copy then execute LB.
|
||||
post_code(0x43); // Should never see this post code.
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -355,9 +355,6 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
pnp_write_config(GPIO3_DEV, 0x2c, (cr2c & 0xf3) | 0x04);
|
||||
/* Restore default SuperIO access */
|
||||
outb(0xaa, port);
|
||||
|
||||
post_cache_as_ram(); // BSP switch stack to ram, copy then execute LB.
|
||||
post_code(0x43); // Should never see this post code.
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -359,7 +359,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
pnp_write_config(GPIO3_DEV, 0x2c, (cr2c & 0xf3) | 0x04);
|
||||
/* Restore default SuperIO access */
|
||||
outb(0xaa, port);
|
||||
|
||||
post_cache_as_ram(); // BSP switch stack to ram, copy then execute LB.
|
||||
post_code(0x43); // Should never see this post code.
|
||||
}
|
||||
|
|
|
@ -625,9 +625,6 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
|
||||
if (IS_ENABLED(CONFIG_LPC_TPM))
|
||||
init_tpm(s3resume);
|
||||
|
||||
post_cache_as_ram(); // BSP switch stack to ram, copy then execute LB.
|
||||
post_code(0x43); // Should never see this post code.
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -174,6 +174,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
|
||||
sdram_initialize(sysinfo->nodes, sysinfo->ctrl, sysinfo);
|
||||
|
||||
/* BSP switch stack to RAM and copy sysinfo RAM now. */
|
||||
post_cache_as_ram();
|
||||
}
|
||||
|
|
|
@ -180,5 +180,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
fill_mem_ctrl(sysinfo->nodes, sysinfo->ctrl, spd_addr);
|
||||
enable_smbus();
|
||||
sdram_initialize(sysinfo->nodes, sysinfo->ctrl, sysinfo);
|
||||
post_cache_as_ram();
|
||||
}
|
||||
|
|
|
@ -276,5 +276,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
fill_mem_ctrl(sysinfo->nodes, sysinfo->ctrl, spd_addr);
|
||||
enable_smbus();
|
||||
sdram_initialize(sysinfo->nodes, sysinfo->ctrl, sysinfo);
|
||||
post_cache_as_ram();
|
||||
}
|
||||
|
|
|
@ -220,8 +220,6 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
sb7xx_51xx_before_pci_init();
|
||||
|
||||
post_code(0x42);
|
||||
post_cache_as_ram(); // BSP switch stack to ram, copy then execute LB.
|
||||
post_code(0x43); // Should never see this post code.
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -221,8 +221,6 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
sb7xx_51xx_before_pci_init();
|
||||
|
||||
post_code(0x42);
|
||||
post_cache_as_ram(); // BSP switch stack to ram, copy then execute LB.
|
||||
post_code(0x43); // Should never see this post code.
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -225,8 +225,6 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
sb800_before_pci_init();
|
||||
|
||||
post_code(0x42);
|
||||
post_cache_as_ram(); // BSP switch stack to ram, copy then execute LB.
|
||||
post_code(0x43); // Should never see this post code.
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -209,8 +209,6 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
sb800_before_pci_init();
|
||||
|
||||
post_code(0x42);
|
||||
post_cache_as_ram(); /* BSP switch stack to ram, copy then execute LB. */
|
||||
post_code(0x43); /* Should never see this post code. */
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -125,6 +125,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
print_pci_devices();
|
||||
dump_pci_devices();
|
||||
#endif
|
||||
|
||||
post_cache_as_ram();
|
||||
}
|
||||
|
|
|
@ -191,5 +191,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
sdram_initialize(sysinfo->nodes, sysinfo->ctrl, sysinfo);
|
||||
|
||||
sis_init_stage2();
|
||||
post_cache_as_ram(); // bsp swtich stack to RAM and copy sysinfo RAM now
|
||||
}
|
||||
|
|
|
@ -207,6 +207,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
/* all ap stopped? */
|
||||
|
||||
sdram_initialize(sysinfo->nodes, sysinfo->ctrl, sysinfo);
|
||||
|
||||
post_cache_as_ram(); // bsp swtich stack to RAM and copy sysinfo RAM now
|
||||
}
|
||||
|
|
|
@ -216,8 +216,6 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
sb7xx_51xx_before_pci_init();
|
||||
|
||||
post_code(0x42);
|
||||
post_cache_as_ram(); // BSP switch stack to ram, copy then execute LB.
|
||||
post_code(0x43); // Should never see this post code.
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -216,8 +216,6 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
sb7xx_51xx_before_pci_init();
|
||||
|
||||
post_code(0x42);
|
||||
post_cache_as_ram(); // BSP switch stack to ram, copy then execute LB.
|
||||
post_code(0x43); // Should never see this post code.
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -218,8 +218,6 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
sb7xx_51xx_before_pci_init();
|
||||
|
||||
post_code(0x42);
|
||||
post_cache_as_ram(); // BSP switch stack to ram, copy then execute LB.
|
||||
post_code(0x43); // Should never see this post code.
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -197,7 +197,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
#endif
|
||||
sdram_initialize(sysinfo->nodes, sysinfo->ctrl, sysinfo);
|
||||
|
||||
//dump_pci_devices();
|
||||
|
||||
post_cache_as_ram();
|
||||
}
|
||||
|
|
|
@ -204,6 +204,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
// init_timer(); // Need to use TMICT to synchronize FID/VID
|
||||
|
||||
sdram_initialize(sysinfo->nodes, sysinfo->ctrl, sysinfo);
|
||||
|
||||
post_cache_as_ram();
|
||||
}
|
||||
|
|
|
@ -212,8 +212,6 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
amdmct_cbmem_store_info(sysinfo);
|
||||
|
||||
bcm5785_early_setup();
|
||||
|
||||
post_cache_as_ram();
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -218,8 +218,6 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
sb7xx_51xx_before_pci_init();
|
||||
|
||||
post_code(0x42);
|
||||
post_cache_as_ram(); // BSP switch stack to ram, copy then execute LB.
|
||||
post_code(0x43); // Should never see this post code.
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -160,6 +160,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
#if 0
|
||||
dump_pci_devices();
|
||||
#endif
|
||||
|
||||
post_cache_as_ram(); // bsp swtich stack to RAM and copy sysinfo RAM now
|
||||
}
|
||||
|
|
|
@ -223,8 +223,6 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
sb7xx_51xx_before_pci_init();
|
||||
|
||||
post_code(0x42);
|
||||
post_cache_as_ram(); // BSP switch stack to ram, copy then execute LB.
|
||||
post_code(0x43); // Should never see this post code.
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -145,6 +145,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
|
||||
rs690_before_pci_init();
|
||||
sb600_before_pci_init();
|
||||
|
||||
post_cache_as_ram();
|
||||
}
|
||||
|
|
|
@ -163,6 +163,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
#endif
|
||||
|
||||
sdram_initialize(nodes, ctrl);
|
||||
|
||||
post_cache_as_ram();
|
||||
}
|
||||
|
|
|
@ -195,6 +195,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
|
||||
sdram_initialize(sysinfo->nodes, sysinfo->ctrl, sysinfo);
|
||||
|
||||
/* bsp switch stack to RAM and copy sysinfo RAM now. */
|
||||
post_cache_as_ram();
|
||||
}
|
||||
|
|
|
@ -202,6 +202,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
dump_pci_device_index_wait(PCI_DEV(0, 0x18, 2), 0x98);
|
||||
dump_pci_device_index_wait(PCI_DEV(0, 0x19, 2), 0x98);
|
||||
#endif
|
||||
|
||||
post_cache_as_ram();
|
||||
}
|
||||
|
|
|
@ -178,6 +178,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
enable_smbus();
|
||||
|
||||
sdram_initialize(sysinfo->nodes, sysinfo->ctrl, sysinfo);
|
||||
|
||||
post_cache_as_ram();
|
||||
}
|
||||
|
|
|
@ -246,9 +246,6 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
post_code(0x41);
|
||||
|
||||
amdmct_cbmem_store_info(sysinfo);
|
||||
|
||||
post_cache_as_ram(); // BSP switch stack to ram, copy then execute LB.
|
||||
post_code(0x43); // Should never see this post code.
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -194,6 +194,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
/* all ap stopped? */
|
||||
|
||||
sdram_initialize(sysinfo->nodes, sysinfo->ctrl, sysinfo);
|
||||
|
||||
post_cache_as_ram(); // bsp swtich stack to RAM and copy sysinfo RAM now
|
||||
}
|
||||
|
|
|
@ -183,6 +183,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
|
||||
rs690_before_pci_init(); // does nothing
|
||||
sb600_before_pci_init();
|
||||
|
||||
post_cache_as_ram();
|
||||
}
|
||||
|
|
|
@ -147,6 +147,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
enable_smbus();
|
||||
|
||||
sdram_initialize(nodes, ctrl);
|
||||
|
||||
post_cache_as_ram();
|
||||
}
|
||||
|
|
|
@ -190,6 +190,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
/* all ap stopped? */
|
||||
|
||||
sdram_initialize(sysinfo->nodes, sysinfo->ctrl, sysinfo);
|
||||
|
||||
post_cache_as_ram(); // bsp swtich stack to RAM and copy sysinfo RAM now
|
||||
}
|
||||
|
|
|
@ -213,6 +213,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
/* all ap stopped? */
|
||||
|
||||
sdram_initialize(sysinfo->nodes, sysinfo->ctrl, sysinfo);
|
||||
|
||||
post_cache_as_ram(); // bsp swtich stack to RAM and copy sysinfo RAM now
|
||||
}
|
||||
|
|
|
@ -190,6 +190,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
/* all ap stopped? */
|
||||
|
||||
sdram_initialize(sysinfo->nodes, sysinfo->ctrl, sysinfo);
|
||||
|
||||
post_cache_as_ram(); // bsp swtich stack to RAM and copy sysinfo RAM now
|
||||
}
|
||||
|
|
|
@ -245,8 +245,6 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
|
||||
amdmct_cbmem_store_info(sysinfo);
|
||||
|
||||
post_cache_as_ram(); // BSP switch stack to ram, copy + execute stage 2
|
||||
post_code(0x42); // Should never see this post code.
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -308,8 +308,6 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
|
||||
amdmct_cbmem_store_info(sysinfo);
|
||||
|
||||
post_cache_as_ram(); /* BSP switch stack to ram, copy then execute CB. */
|
||||
post_code(0x42); /* Should never see this post code. */
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -234,8 +234,6 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
sb7xx_51xx_before_pci_init();
|
||||
|
||||
post_code(0x42);
|
||||
post_cache_as_ram(); // BSP switch stack to ram, copy then execute LB.
|
||||
post_code(0x43); // Should never see this post code.
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -157,6 +157,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
|
||||
rs690_before_pci_init();
|
||||
sb600_before_pci_init();
|
||||
|
||||
post_cache_as_ram();
|
||||
}
|
||||
|
|
|
@ -144,6 +144,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
|
||||
rs690_before_pci_init();
|
||||
sb600_before_pci_init();
|
||||
|
||||
post_cache_as_ram();
|
||||
}
|
||||
|
|
|
@ -193,6 +193,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
/* all ap stopped? */
|
||||
|
||||
sdram_initialize(sysinfo->nodes, sysinfo->ctrl, sysinfo);
|
||||
|
||||
post_cache_as_ram(); // bsp swtich stack to RAM and copy sysinfo RAM now
|
||||
}
|
||||
|
|
|
@ -243,8 +243,6 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
|
||||
amdmct_cbmem_store_info(sysinfo);
|
||||
|
||||
post_cache_as_ram(); // BSP switch stack to ram, copy then execute LB.
|
||||
post_code(0x43); // Should never see this post code.
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -144,6 +144,4 @@ void cache_as_ram_main(unsigned long bist, unsigned long cpu_init_detectedx)
|
|||
print_pci_devices();
|
||||
dump_pci_devices();
|
||||
#endif
|
||||
|
||||
post_cache_as_ram();
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue