modified: 16/cawat/16_mm.c
void MML_SetupEMS (void)\r
{\r
char str[80],str2[10];\r
- unsigned error;\r
+ unsigned err;
+ struct REGS CPURegs;\r
\r
totalEMSpages = freeEMSpages = EMSpageframe = EMSpagesmapped = 0;\r
\r
- __asm {\r
+ __asm
+ {\r
mov ah,EMS_STATUS\r
int EMS_INT // make sure EMS hardware is present\r
or ah,ah\r
mov [EMShandle],dx
jmp End
error:\r
- error = _AH;\r
- strcpy (str,"MML_SetupEMS: EMS error 0x");\r
- itoa(error,str2,16);\r
- strcpy (str,str2);\r
- printf("%s\n",str);
+// err = CPURegs.h.ah;\r
+// strcpy (str,"MML_SetupEMS: EMS error 0x");\r
+// itoa(err,str2,16);\r
+// strcpy (str,str2);\r
+// printf("%s\n",str);
jmp End
noEMS:
End:\r
\r
gotone:\r
mov [base],bx\r
- mov [size],dx\r
+ mov [size],dx
+ done:\r
}\r
MML_UseSpace (base,size);\r
mminfo.XMSmem += size*16;\r
numUMBs++;\r
if (numUMBs < MAXUMBS)\r
goto getmemory;\r
-\r
-done:;\r
}\r
\r
\r