diff options
author | H. Peter Anvin <hpa@zytor.com> | 2009-05-14 11:59:46 -0700 |
---|---|---|
committer | H. Peter Anvin <hpa@zytor.com> | 2009-05-14 11:59:46 -0700 |
commit | 410c91f5624370b1b6a7575d2049db62e6946eeb (patch) | |
tree | 45a19d0f93bb63ba952958fd98d0f10fd15971ab /core/init.inc | |
parent | 4cc0c3ab6541753b89cba58c345c0cae8c7d151d (diff) | |
download | syslinux-410c91f5624370b1b6a7575d2049db62e6946eeb.tar.gz |
First cut of doing 32-bit C code in the core
A very preliminary implementation of 32-bit C code in the core. This
currently breaks ADV, because the installer assumes the ADV is the
last two sectors in extlinux.sys -- need to figure out a way to deal
with this hopefully without breaking the migration protocol.
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Diffstat (limited to 'core/init.inc')
-rw-r--r-- | core/init.inc | 20 |
1 files changed, 14 insertions, 6 deletions
diff --git a/core/init.inc b/core/init.inc index 201d1b46..edfde5de 100644 --- a/core/init.inc +++ b/core/init.inc @@ -20,6 +20,19 @@ section .text16 common_init: + ; Initialize PM invocation framework + call pm_init + + ; Copy PM code to its target location + mov esi,__pm_code_lma + mov edi,__pm_code_start + mov ecx,__pm_code_len + call bcopy + or esi,-1 ; Set to zero + mov edi,__bss_start + mov ecx,__bss_len + call bcopy + ; Zero bss sections (but not .earlybss, since it may ; contain already-live data.) xor eax,eax @@ -39,13 +52,8 @@ common_init: call reset_config ; -; Clear Files structures +; Initialize Files structures (other than zeroing) ; - mov di,Files - mov cx,(MAX_OPEN*open_file_t_size)/4 - xor eax,eax - rep stosd - %if IS_PXELINUX mov di,Files+tftp_pktbuf mov cx,MAX_OPEN |