wok diff plop/stuff/bootloader.S @ rev 24942
BootProg: clear cmdline
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Wed Apr 20 15:10:50 2022 +0000 (2022-04-20) |
parents | 89b052a8b781 |
children | e197a1539e2e |
line diff
1.1 --- a/plop/stuff/bootloader.S Wed Aug 19 13:03:10 2020 +0000 1.2 +++ b/plop/stuff/bootloader.S Wed Apr 20 15:10:50 2022 +0000 1.3 @@ -20,12 +20,13 @@ 1.4 /* some extra features */ 1.5 #define EXE_SUPPORT real mode dos .exe file support +208/264 1.6 #define CMDLINE dos kernel cmdline support +45 1.7 +#define BUGGY_CMDLINE verify cmdline length +2 1.8 #define VCPI VCPI 4.0 support (386+) +109 1.9 #define SHUTDOWNDOS shutdown DOS services +29 1.10 1.11 /* some contraints to reduce the code size */ 1.12 //#define FLOPPY_1440K_ONLY 1.44M floppies support only -26 1.13 -#define FLOPPY_HAS_2_SIDES hardcoded heads count to 2 -15 1.14 +//#define FLOPPY_HAS_2_SIDES hardcoded heads count to 2 -15 1.15 //#define NO_CMDLINE_SHRINK remove heading spaces ? -6-21 1.16 //#define NO_CMDLINE_FILE remove @cmdline file support ? -21 1.17 //#define NO_DOTS show progression dots ? -5 1.18 @@ -313,8 +314,8 @@ 1.19 #else 1.20 subw %ax, %bx 1.21 jnc forward 1.22 + //movw $0x8FFF, %ax 1.23 movb $0x90, %ah 1.24 - ;decw %ax 1.25 forward: 1.26 movw %ax, %es 1.27 movw %ax, %di 1.28 @@ -356,7 +357,12 @@ 1.29 lodsb 1.30 cbw 1.31 xchgw %ax, %cx 1.32 +#ifdef BUGGY_CMDLINE 1.33 + test %cl, %cl # C=O=0, set S & Z 1.34 + jng nocmdline # Z == 1 or O != S ? 1.35 +#else 1.36 jcxz nocmdline 1.37 +#endif 1.38 # if defined(BZIMAGE) && BZIMAGE >= 0x202 1.39 movw $INITSEG/16+stacktop/256, EXEADRS(cmd_line_ptr+1) 1.40 # else