From: sparky4 Date: Tue, 21 Jul 2015 01:16:51 +0000 (-0500) Subject: issues with mapping EMS X-Git-Url: http://4ch.mooo.com/gitweb/?a=commitdiff_plain;h=aade8d75c56e2d11d6a71c5a374183c76671e994;p=16.git issues with mapping EMS modified: exmmtest.exe modified: src/lib/16_mm.c --- diff --git a/exmmtest.exe b/exmmtest.exe index 2a33a98b..79d3846a 100644 Binary files a/exmmtest.exe and b/exmmtest.exe differ diff --git a/src/lib/16_mm.c b/src/lib/16_mm.c index 1e6c33c2..78aa5185 100644 --- a/src/lib/16_mm.c +++ b/src/lib/16_mm.c @@ -302,34 +302,31 @@ unsigned MM_MapEMS(mminfo_t *mm) return 0; } -/* -SUB EMS.MapXPages (PhysicalStart, LogicalStart, NumPages, Handle) +void MM_MapXEMS(mminfo_t *mm) +{ + +//SUB EMS.MapXPages (PhysicalStart, LogicalStart, NumPages, Handle) - 'Maps up to 4 logical EMS pages to physical pages in the page frame, where: - ' - 'PhysicalStart = Physical page first logical page is mapped to - 'LogicalStart = First logical page to map - 'NumPages = Number of pages to map (1 to 4) - 'Handle = EMS handle logical pages are allocated to + //Maps up to 4 logical EMS pages to physical pages in the page frame, where: + //PhysicalStart = Physical page first logical page is mapped to + //LogicalStart = First logical page to map + //NumPages = Number of pages to map (1 to 4) + //Handle = EMS handle logical pages are allocated to - 'Create a buffer containing the page information - FOR x = 0 TO NumPages - 1 - MapInfo$ = MapInfo$ + MKI$(LogicalStart + x) + MKI$(PhysicalStart + x) - NEXT + //Create a buffer containing the page information +// FOR x = 0 TO NumPages - 1 +// MapInfo$ = MapInfo$ + MKI$(LogicalStart + x) + MKI$(PhysicalStart + x) +// NEXT - Regs.ax = &H5000 'Map the pages in the buffer - Regs.cx = NumPages 'to the pageframe - Regs.dx = Handle - Regs.ds = VARSEG(MapInfo$) - Regs.si = SADD(MapInfo$) - InterruptX &H67, Regs, Regs - EMS.Error = (Regs.ax AND &HFF00&) \ &H100 'Store the status code +// Regs.ax = &H5000 //Map the pages in the buffer +// Regs.cx = NumPages //to the pageframe +// Regs.dx = Handle +// Regs.ds = VARSEG(MapInfo$) +// Regs.si = SADD(MapInfo$) +// InterruptX &H67, Regs, Regs +// EMS.Error = (Regs.ax AND &HFF00&) \ &H100 //Store the status code -END SUB -*/ -void MM_MapXEMS(mminfo_t *mm) -{ - +//END SUB } //==========================================================================