[NTVDM]
[reactos.git] / subsystems / ntvdm / io.h
1 /*
2 * COPYRIGHT: GPL - See COPYING in the top level directory
3 * PROJECT: ReactOS Virtual DOS Machine
4 * FILE: io.c
5 * PURPOSE: I/O Port Handlers
6 * PROGRAMMERS: Aleksandar Andrejevic <theflash AT sdf DOT lonestar DOT org>
7 * Hermes Belusca-Maito (hermes.belusca@sfr.fr)
8 */
9
10 #ifndef _IO_H_
11 #define _IO_H_
12
13 /* DEFINES ********************************************************************/
14
15 #define EMULATOR_MAX_IOPORTS_NUM 0x10000
16
17 /* FUNCTIONS ******************************************************************/
18
19 typedef BYTE (WINAPI *EMULATOR_IN_PROC)(ULONG Port);
20 typedef VOID (WINAPI *EMULATOR_OUT_PROC)(ULONG Port, BYTE Data);
21
22 VOID WINAPI RegisterIoPort(ULONG Port,
23 EMULATOR_IN_PROC InHandler,
24 EMULATOR_OUT_PROC OutHandler);
25
26 VOID WINAPI UnregisterIoPort(ULONG Port);
27
28 VOID WINAPI EmulatorReadIo
29 (
30 PFAST486_STATE State,
31 ULONG Port,
32 PVOID Buffer,
33 ULONG DataCount,
34 UCHAR DataSize
35 );
36
37 VOID WINAPI EmulatorWriteIo
38 (
39 PFAST486_STATE State,
40 ULONG Port,
41 PVOID Buffer,
42 ULONG DataCount,
43 UCHAR DataSize
44 );
45
46 #endif // _IO_H_
47
48 /* EOF */