wok-6.x rev 15470
memtest/bootloader.S: fix dos exit (again)
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Fri Nov 08 14:20:43 2013 +0000 (2013-11-08) |
parents | d9dd83ccc85f |
children | 499de5b72463 |
files | memtest/stuff/bootloader.S |
line diff
1.1 --- a/memtest/stuff/bootloader.S Fri Nov 08 12:52:29 2013 +0000 1.2 +++ b/memtest/stuff/bootloader.S Fri Nov 08 14:20:43 2013 +0000 1.3 @@ -44,24 +44,20 @@ 1.4 .ascii "(SliTaz)" 1.5 end_header: 1.6 comstart: 1.7 + cld # assume nothing 1.8 #ifdef CMDLINE 1.9 - cld # assume nothing 1.10 - .byte 0xA3 // mov %ax,[stacktop] 1.11 - .word stacktop 1.12 -#else 1.13 - cld # assume nothing 1.14 + movw $stacktop, %di 1.15 #undef HELP 1.16 #endif 1.17 pushw $INITSEG 1.18 popw %es 1.19 #ifdef CMDLINE 1.20 - movw %sp, %di 1.21 movw $0x80, %si 1.22 lodsb 1.23 cbw 1.24 xchgw %ax, %cx 1.25 jcxz nocmdline 1.26 - movb $0x3F, 0x7F(%si) 1.27 + movw $0xA33F, 0x7F(%si) 1.28 skipspace: 1.29 lodsb 1.30 cmpb $0x20, %al 1.31 @@ -77,7 +73,6 @@ 1.32 movw $EXEADRS(helpmsg), %si 1.33 cmpb $'/', %al 1.34 je puts 1.35 - movb setup_sects-helpmsg(%si), %ch 1.36 # endif 1.37 nocmdline: 1.38 #endif 1.39 @@ -102,9 +97,7 @@ 1.40 #endif 1.41 movw $0x100, %si 1.42 movw $end_header, %di 1.43 -#ifndef HELP 1.44 movb EXEADRS(setup_sects), %ch 1.45 -#endif 1.46 movb $(512-(end_header-_start))/2, %cl 1.47 rep 1.48 movsw