Am 10.02.2010 11:24, schrieb Bao, Zheng:
I am debugging the fam10+RS780+SB700. Now I am facing a problem which troubles me for quite a long time. It came up since CBFS play its role. The data in memory changes unexpectedly. The printk_debug can not help to narrow down the point where the writing happens.
So I set the memory address which changes during booting as a breakpoint trigger. Anyone writes data to this address will cause a breakpoint. But unfortunately nothing can be captured. So I had to set breakpoint in the whole process to narrow down. Now I narrow down to the initialize_cpus in src/cpu/x86/lapic/. The functions called in initialize_cpus are static which can not find a symbol in the coreboot.map. I need to disassemble the binary to find out why. Before that, I need to guess what on earth happens.
It seems to have something to do with the SMP. It seems that other cores write data into the memory which is not belong to them. Do you think it can happen?
Can you narrow down a bit what kind of data is overwritten there?
The only thing related to SMP that I can think of is stacks and CBFS loading. For both it might (but should not) happen that multiple cores try to do the same thing and overwrite each other's data.
Stacks seem fine in AMD code (from a short look), you could try to look what the APs so once they are started. cbfs might happen early, and we need to change things there, eg. have the BSP decompress the AP code once, before starting the APs, instead of the APs, which would require locking to not stumble over each other.
Patrick