emulation/qemu-x86: Fix romstage stack alignment
Also tidy up some register usage. Change-Id: I5b4b4a29c854f4ca165cede4e9b6755a6c577e76 Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/34975 Reviewed-by: Arthur Heymans <arthur@aheymans.xyz> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
This commit is contained in:
parent
2dba2949fa
commit
a7cac0a681
|
@ -28,22 +28,22 @@ cache_as_ram:
|
||||||
* initialization.
|
* initialization.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
post_code(0x21)
|
|
||||||
|
|
||||||
movl $_car_stack_end, %esp
|
|
||||||
/* Align the stack and keep aligned for call to bootblock_c_entry() */
|
|
||||||
and $0xfffffff0, %esp
|
|
||||||
sub $12, %esp
|
|
||||||
|
|
||||||
/* Clear the cache memory region. This will also clear CAR GLOBAL */
|
/* Clear the cache memory region. This will also clear CAR GLOBAL */
|
||||||
movl $_car_region_start, %esi
|
movl $_car_region_start, %edi
|
||||||
movl %esi, %edi
|
|
||||||
movl $_car_region_end, %ecx
|
movl $_car_region_end, %ecx
|
||||||
sub $_car_region_start, %ecx
|
sub %edi, %ecx
|
||||||
shr $2, %ecx
|
shr $2, %ecx
|
||||||
xorl %eax, %eax
|
xorl %eax, %eax
|
||||||
rep stosl
|
rep stosl
|
||||||
|
|
||||||
|
post_code(0x21)
|
||||||
|
|
||||||
|
movl $_car_stack_end, %esp
|
||||||
|
|
||||||
|
/* Align the stack and keep aligned for call to bootblock_c_entry() */
|
||||||
|
and $0xfffffff0, %esp
|
||||||
|
sub $4, %esp
|
||||||
|
|
||||||
/* Restore the BIST result and timestamps. */
|
/* Restore the BIST result and timestamps. */
|
||||||
movd %mm0, %ebx
|
movd %mm0, %ebx
|
||||||
movd %mm1, %eax
|
movd %mm1, %eax
|
||||||
|
|
Loading…
Reference in New Issue