Navigation
Highlights

Release 0.0.5

The latest release, alpha testing, unstable. See "downloads".

2005-06-01

Links
Documentation

DPMI driver services

The DPMI driver lets DPMI applications to be run under FreeDOS-32, providing them the DPMI and DOS Application Programming Interfaces (APIs) they expect. This document is a summary of system calls recognized by the FD32 DPMI driver.

DPMI calls

The following table lists the implemented (tick) and unimplemented (cross) DPMI services. Unless differently stated, each service is called through INT 31h, with the specified value of the AX register. The ver column shows the DPMI compatibility version.

LDT Management Services
AXverdescription
00000.9Allocate LDT Descriptors
00010.9Free LDT Descriptor
00020.9Segment to Descriptor
00030.9Get Selector Increment Value
00060.9Get Segment Base Address
00070.9Set Segment Base Address
00080.9Set Segment Limit
00090.9Set Descriptor Access Rights
000A0.9Create Alias Descriptor
000B0.9Get Descriptor
000C0.9Set Descriptor
000D0.9Allocate Specific LDT Descriptor
000E1.0Get Multiple Descriptors
000F1.0Set Multiple Descriptors
Extended Memory Management Services
AXverdescription
05000.9Get Free Memory Information
05010.9Allocate Memory Block
05020.9Free Memory Block
05030.9Resize Memory Block
05041.0Allocate Linear Memory Block
05051.0Resize Linear Memory Block
05061.0Get Page Attributes
05071.0Set Page Attributes [FAKE]
05081.0Map Device in Memory Block
05091.0Map Conventional Memory in Memory Block
050A1.0Get Memory Block Size and Base
050B1.0Get Memory Information
08000.9Physical Address Mapping
08011.0Free Physical Address Mapping
0D001.0Allocate Shared Memory
0D011.0Free Shared Memory
0D021.0Serialize on Shared Memory
0D031.0Free Serialization on Shared Memory
DOS Memory Management Services
AXverdescription
01000.9Allocate DOS Memory Block
01010.9Free DOS Memory Block
01020.9Resize DOS Memory Block
Interrupt Management Services
AXverdescription
02000.9Get Real Mode Interrupt Vector
02010.9Set Real Mode Interrupt Vector
02020.9Get Processor Exception Handler Vector
02030.9Set Processor Exception Handler Vector
02040.9Get Protected Mode Interrupt Vector
02050.9Set Protected Mode Interrupt Vector
02101.0Get Extended Processor Exception Handler Vector (Protected Mode)
02111.0Get Extended Processor Exception Handler Vector (Real Mode)
02121.0Set Extended Processor Exception Handler Vector (Protected Mode)
02131.0Set Extended Processor Exception Handler Vector (Real Mode)
09000.9Get and Disable Virtual Interrupt State
09010.9Get and Enable Virtual Interrupt State
09020.9Get Virtual Interrupt State
Translation Services
AXverdescription
03000.9Simulate Real Mode Interrupt [HARD-CODED]
03010.9Call Real Mode Procedure With Far Return Frame
03020.9Call Real Mode Procedure With IRET Frame
03030.9Allocate Real Mode Callback Address
03040.9Free Real Mode Callback Address
03050.9Get State Save/Restore Addresses
03060.9Get Raw Mode Switch Addresses
Page Management Services
AXverdescription
06000.9Lock Linear Region [FAKE]
06010.9Unlock Linear Region
06020.9Mark Real Mode Region as Pageable
06030.9Relock Real Mode Region
06040.9Get Page Size
07020.9Mark Page as Demand Paging Candidate
07030.9Discard Page Contents
Debug Support Services
AXverdescription
0B000.9Set Debug Watchpoint
0B010.9Clear Debug Watchpoint
0B020.9Get State of Debug Watchpoint
0B030.9Reset Debug Watchpoint
Miscellaneous Services
AXverdescription
04000.9Get Version
04011.0Get DPMI Capabilities
0A000.9Get Vendor-Specific API Entry Point
0C001.0Install Resident Service Provider Callback
0C011.0Terminate and Stay Resident
0E001.0Get Coprocessor Status
0E011.0Set Coprocessor Emulation

DOS calls

Miscellaneous services

  Int Registers Compatibility Description
21h AH=30h DOS 2+ Get DOS version
21h AX=3306h DOS 5+ Get true version number
21h AH=44h DOS 2+ "IOCTL" - Get device informations [FAKE]
21h AH=4Bh DOS 2+ "EXEC" - Execute program [UNDER CONSTRUCTION]
21h AH=4Ch DOS 2+ "EXIT" - Terminate with return code
21h AH=4Dh DOS 2+ "ERRORLEVEL" - Get DOS return code
21h AH=6Bh DOS 5+ Null function

Character I/O services

  Int Registers Compatibility Description
21h AH=01h DOS 1+ Read character from stdin with echo
21h AH=02h DOS 1+ Write character to stdout
21h AH=03h DOS 1+ Read character from stdaux
21h AH=04h DOS 1+ Write character to stdaux
21h AH=05h DOS 1+ Write character to stdprn
21h AH=06h DOS 1+ Direct console output
21h AH=06h DL=FFh DOS 1+ Direct console input
21h AH=07h DOS 1+ Direct character input with echo
21h AH=08h DOS 1+ Direct character input without echo
21h AH=09h DOS 1+ Write string to stdout
21h AH=0Ah DOS 1+ Buffered input
21h AH=0Bh DOS 1+ Get stdin status
21h AH=0Ch DOS 1+ Flush buffer and read stdin

File Control Block services (superseeded)

  Int Registers Compatibility Description
21h AH=0Fh DOS 1+ Open file using FCB
21h AH=10h DOS 1+ Close file using FCB
21h AH=11h DOS 1+ Find first matching file using FCB
21h AH=12h DOS 1+ Find next matching file using FCB
21h AH=13h DOS 1+ Delete file using FCB
21h AH=14h DOS 1+ Sequential read from file using FCB
21h AH=15h DOS 1+ Sequential write to file using FCB
21h AH=16h DOS 1+ Create or truncate file using FCB
21h AH=17h DOS 1+ Rename file using FCB
21h AH=21h DOS 1+ Read random record from file using FCB
21h AH=22h DOS 1+ Write random record to file using FCB
21h AH=23h DOS 1+ Get file size from FCB
21h AH=24h DOS 1+ Set random record number for FCB
21h AH=27h DOS 1+ Random block read from file using FCB
21h AH=28h DOS 1+ Random block write to file using FCB
21h AH=29h DOS 1+ Parse file name into FCB

File System services

  Int Registers Compatibility Description
21h AH=0Dh DOS 1+ Disk reset
21h AH=0Eh DOS 1+ Set default drive
21h AH=19h DOS 1+ Get default drive
21h AH=1Ah DOS 1+ Set Disk Transfer Area address
21h AH=1Bh DOS 1+ Get allocation information for default drive
21h AH=1Ch DOS 1+ Get allocation information for specific drive
21h AH=1Fh DOS 1+ Get Drive Parameter Block for default drive
21h AH=2Eh DL=00h DOS 1+ Set verify flag
21h AH=2Fh DOS 2+ Get Disk Transfer Area address
21h AH=32h DOS 2+ Get DOS Drive Parameter Block for specific drive
21h AX=3305h DOS 2+ Get boot drive
21h AH=36h DOS 2+ Get free disk space
21hAH=39hDOS 2+"MKDIR" Create subdirectory
21hAH=3AhDOS 2+"RMDIR" - Remove subdirectory
21hAH=3BhDOS 2+"CHDIR" - Set current directory
21hAH=3ChDOS 2+"CREAT" - Create or truncate file
21hAH=3DhDOS 2+"OPEN" - Open existing file
21hAH=3EhDOS 2+"CLOSE" - Close file
21hAH=3FhDOS 2+"READ" - Read from file or device
21hAH=40hDOS 2+"WRITE" - Write to file or device
21hAH=41hDOS 2+"UNLINK" - Delete file
21hAH=42hDOS 2+"LSEEK" - Set current file position
21hAX=4300hDOS 2+Get file attributes
21hAX=4301hDOS 2+"CHMOD" - Set file attributes
21hAX=4302hDOS 7+Get compressed file size
21hAX=43FFh BP=5053hDOS 7.20+Extended-length file name operations
21hAH=45hDOS 2+"DUP" - Duplicate file handle
21hAH=46hDOS 2+"DUP2", "FORCEDUP" - Force duplicate file handle
21hAH=47hDOS 2+"CWD" - Get current directory
21hAH=4EhDOS 2+"FINDFIRST" - Find first matching file
21hAH=4FhDOS 2+"FINDNEXT" - Find next matching file
21hAH=56hDOS 2+"RENAME" - Rename or move file
21hAX=5700hDOS 2+Get file's last modification date and time
21hAX=5701hDOS 2+Set file's last modification date and time
21hAX=5702hDOS 4 onlyGet extended attributes for file
21hAX=5703hDOS 4 onlyGet extended attribute properties
21hAX=5704hDOS 4 onlySet extended attributes
21hAX=5704hDOS 7+Get file's last access date and time
21hAX=5705hDOS 7+Set file's last access date and time
21hAX=5706hDOS 7+Get file's creation date and time
21hAX=5707hDOS 7+Set file's creation date and time
21hAH=5AhDOS 3.0+Create temporary file
21hAH=5BhDOS 3.0+Create new file
21hAH=5ChDOS 3.0+"FLOCK" - Record locking
21hAX=5F07hDOS 5+Enable drive
21hAX=5F08hDOS 5+Disable drive
21hAX=60hDOS 3.0+"TRUENAME" - Canonicalize file name or path
21hAH=67hDOS 3.3+Set file handle count (Job File Table size)
21hAH=68hDOS 3.3+"FFLUSH" - Commit file
21hAH=69hDOS 4.0+Get/set disk serial number
21hAH=6AhDOS 4.0+Commit file
21hAX=6C00hDOS 4.0+Extended open/create file
21hAH=73hDOS 7+Drive locking
21hAX=7302hWin95+"Get_ExtDBP" - Get extended Drive Parameter Block for FAT32 drive
21hAX=7303hWin95+Get free space on FAT32 drive
21hAX=7304hWin95+Set DPB to use for formatting a FAT32 drive

Long File Name services

 IntRegistersCompatibilityDescription
21hAX=710DhWin95+Reset drive
21hAX=7139hWin95+"MKDIR" - Make directory with Long File Names support
21hAX=713AhWin95+"RMDIR" - Remove directory with Long File Names support
21hAX=713BhWin95+"CHDIR" - Set current directory with Long File Names support
21hAX=7141hWin95+"UNLINK" - Delete file with Long File Names support
21hAX=7143hWin95+ "CHMOD" - Extended get/set file attributes
21hAX=7147hWin95+"CWD" - Get current directory with Long File Name support
21hAX=714EhWin95+"FINDFIRST" - Find first matching file with Long File Names support
21hAX=714FhWin95+"FINDNEXT" - Find next matching file with Long File Names support
21hAX=7156hWin95+"RENAME" - Rename or move file with Long File Names support
21hAX=7160h CL=00hWin95+"TRUENAME" - Canonicalize path with Long File Names support
21hAX=7160h CL=01hWin95+"TRUENAME" - Get canonical short (8.3) name for file
21hAX=7160h CL=02hWin95+"TRUENAME" - Get canonical long file name or path
21hAX=716ChWin95+"OPEN" - Create or open file with Long File Names support
21hAX=71A0hWin95+Get volume informations
21hAX=71A1hWin95+"FINDCLOSE" - Terminate directory search
21hAX=71A6hWin95+Get file informations by handle
21hAX=71A7h BL=00hWin95+Convert Windows 64-bit time to DOS time
21hAX=71A7h BL=01hWin95+Convert DOS time to Windows 64-bit time
21hAX=71A8hWin95+Generate short name alias for long file name
21hAX=71A9hWin95+Server create or open file
21hAX=71AAh BH=00hWin95+Create subst
21hAX=71AAh BH=01hWin95+Terminate subst
21hAX=71AAh BH=02hWin95+Query subst
21hAH=72hWin95 beta"FINDCLOSE" - Terminate directory search