4 # error "This file assumes -mregparm=3 -DREGPARM=3"
11 # Align the stack and make sure the high half is zero
14 # DS, ES points to the PSP at this point
15 pushw %es # Save PSP pointer
29 # Copy the PSP into our own segment
36 # Verify that this is a supportable DOS version
41 cmpw $0x0314,%ax # DOS >= 3.20?
43 movw $bad_dos,%dx # Print error message
49 # Compute argc and argv (assumes REGPARM)
50 pushl %eax # Make space for argv
56 calll __init_memory_arena
63 # Here %eax is the exit code, fall through into exit
70 # Exit code already in %eax
71 movb $0x4c,%ah # Terminate program
77 .section ".rodata","a"
79 .ascii "Unsupported DOS version\r\n$"
80 .size bad_dos,.-bad_dos
89 /* Purely for sanity */