mirror of
https://github.com/mmueller41/genode.git
synced 2026-01-21 20:42:56 +01:00
hw_x86_64: Zero-fill BSS segment in x86_64 crt0.s
Make sure all content of the BSS segment is initialized to zero.
This commit is contained in:
committed by
Christian Helmuth
parent
69a58c4bd5
commit
ace61c54d6
@@ -29,6 +29,16 @@
|
||||
.global _start
|
||||
_start:
|
||||
|
||||
/**
|
||||
* zero-fill BSS segment
|
||||
*/
|
||||
leal _bss_start, %edi
|
||||
leal _bss_end, %ecx
|
||||
sub %edi, %ecx
|
||||
shr $2, %ecx
|
||||
xor %eax, %eax
|
||||
rep stosl
|
||||
|
||||
/* Enable PAE (prerequisite for IA-32e mode) and OSFXSR */
|
||||
movl %cr4, %eax
|
||||
btsl $5, %eax
|
||||
|
||||
Reference in New Issue
Block a user