aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorH. Peter Anvin <hpa@zytor.com>2006-08-17 16:17:24 -0700
committerH. Peter Anvin <hpa@zytor.com>2006-08-17 16:17:24 -0700
commit417fd5c59cf7907a95cc45b65c69a748a980fea7 (patch)
tree75b03482b5a224213e30cf04455556a0f7e16556
parent20ceb4162ee177562cf4fd4d3fed9a5770a0fab1 (diff)
downloadsyslinux-417fd5c59cf7907a95cc45b65c69a748a980fea7.tar.gz
syslinux-417fd5c59cf7907a95cc45b65c69a748a980fea7.tar.xz
syslinux-417fd5c59cf7907a95cc45b65c69a748a980fea7.zip
More cleanup of comboot exit codesyslinux-3.20-pre15
-rw-r--r--comboot.inc31
1 files changed, 21 insertions, 10 deletions
diff --git a/comboot.inc b/comboot.inc
index 9a96326d..0ce82b24 100644
--- a/comboot.inc
+++ b/comboot.inc
@@ -141,6 +141,7 @@ is_comboot_image:
; Proper return vector
comboot_return: cli ; Don't trust anyone
+ push enter_command ; Normal return to command prompt
jmp comboot_exit
;
@@ -196,16 +197,27 @@ comboot_resume:
; Attempted to execute non-21h DOS system call
comboot_bogus: cli ; Don't trust anyone
- mov ax,err_notdos
+ mov cx,err_notdos
+ push enter_command
+ jmp comboot_exit_msg
+
;
; Generic COMBOOT return to command line code
-; BX -> where to go next
+; stack -> where to go next
+; CX -> message (for _msg version)
;
comboot_exit:
- mov bx,enter_command ; Normal return to command prompt
-comboot_exit_special:
+ xor cx,cx
+comboot_exit_msg:
+ pop bx ; Return address
RESET_STACK_AND_SEGS AX
call adjust_screen ; The COMBOOT program might have changed the screen
+ jcxz .nomsg
+ mov si,KernelCName
+ call cwritestr
+ mov si,cx
+ call cwritestr
+.nomsg:
jmp bx
;
@@ -361,8 +373,8 @@ comapi_run:
mov si,P_BX
mov di,command_line
call strcpy
- mov bx,load_kernel ; Run a new kernel
- jmp comboot_exit_special ; Terminate task, clean up
+ push load_kernel ; Run a new kernel
+ jmp comboot_exit ; Terminate task, clean up
;
; INT 22h AX=0004h Run default command
@@ -371,8 +383,8 @@ comapi_run:
; as if a timeout had happened or the user pressed <Enter>.
;
comapi_run_default:
- mov bx,auto_boot
- jmp comboot_exit_special
+ push auto_boot
+ jmp comboot_exit
;
; INT 22h AX=0005h Force text mode
@@ -700,8 +712,7 @@ comapi_runkernel:
mov [IPAppend],al
%endif
- mov bx,.finish
- jmp comboot_exit_special
+ call comboot_exit
.finish:
; Copy the command line into its proper place