Kernel: set proper stack pointer value for kernel bootloader.

git-svn-id: svn://kolibrios.org@5786 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
Sergey Semyonov (Serge) 2015-09-03 14:37:07 +00:00
parent eaac3b79f5
commit 66c8eb59f3

View File

@ -159,7 +159,7 @@ FirstDataSector dw 0 ; begin of data
; ;
;========================================================================= ;=========================================================================
include 'bootvesa.inc' ;Include source for boot vesa include 'bootvesa.inc' ;Include source for boot vesa
if defined extended_primary_loader if defined extended_primary_loader
include 'parsers.inc' include 'parsers.inc'
end if end if
@ -176,9 +176,9 @@ if defined extended_primary_loader
mov [bootfs], bx mov [bootfs], bx
; set up stack ; set up stack
mov ax, 3000h mov ax, TMP_STACK_TOP shr 16
mov ss, ax mov ss, ax
mov sp, 0EC00h mov sp, TMP_STACK_TOP and 0xFFFF
; try to load configuration file ; try to load configuration file
mov ax, 1 mov ax, 1
@ -293,9 +293,9 @@ else
no_hd_load: no_hd_load:
; set up stack ; set up stack
mov ax, 3000h mov ax, TMP_STACK_TOP shr 16
mov ss, ax mov ss, ax
mov sp, 0EC00h mov sp, TMP_STACK_TOP and 0xFFFF
; set up segment registers ; set up segment registers
push cs push cs
pop ds pop ds
@ -534,7 +534,7 @@ end if
cmp byte [di+preboot_dma-preboot_device], 1 cmp byte [di+preboot_dma-preboot_device], 1
adc byte [di+preboot_dma-preboot_device], 0 adc byte [di+preboot_dma-preboot_device], 0
cmp byte [di+preboot_launcher-preboot_device], 1 ; Start LAUNCHER by default cmp byte [di+preboot_launcher-preboot_device], 1 ; Start LAUNCHER by default
adc byte [di+preboot_launcher-preboot_device], 0 adc byte [di+preboot_launcher-preboot_device], 0
; cmp byte [di+preboot_biosdisk-preboot_device], 1 ; cmp byte [di+preboot_biosdisk-preboot_device], 1
; adc byte [di+preboot_biosdisk-preboot_device], 0 ; adc byte [di+preboot_biosdisk-preboot_device], 0
;; default value for VRR is OFF ;; default value for VRR is OFF
@ -678,7 +678,7 @@ if defined extended_primary_loader
_ask_question bdev,'12',preboot_device ; range accepted for answer: 1-2 _ask_question bdev,'12',preboot_device ; range accepted for answer: 1-2
else else
_ask_question bdev,'14',preboot_device ; range accepted for answer: 1-4 _ask_question bdev,'14',preboot_device ; range accepted for answer: 1-4
end if end if
_setcursor 14,0 _setcursor 14,0
.d: .d: