BIOS Int 13h Extensions Support
[reactos.git] / freeldr / freeldr / freeldr.h
1 /*
2 * FreeLoader
3 * Copyright (C) 1999, 2000, 2001 Brian Palmer <brianp@sginet.com>
4 *
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 2 of the License, or
8 * (at your option) any later version.
9 *
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14 *
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, write to the Free Software
17 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
18 */
19
20 #ifndef __FREELDR_H
21 #define __FREELDR_H
22
23
24 /* just some stuff */
25 #define VERSION "FreeLoader v0.8"
26 #define COPYRIGHT "Copyright (C) 1999, 2000 Brian Palmer <brianp@sginet.com>"
27
28 #define ROSLDR_MAJOR_VERSION 0
29 #define ROSLDR_MINOR_VERSION 8
30 #define ROSLDR_PATCH_VERSION 0
31
32 #define size_t unsigned int
33 #define BOOL int
34 #define BOOLEAN int
35 #define NULL 0
36 #define TRUE 1
37 #define FALSE 0
38 #define BYTE unsigned char
39 #define WORD unsigned short
40 #define DWORD unsigned long
41 #define CHAR char
42 #define PCHAR char *
43 #define UCHAR unsigned char
44 #define PUCHAR unsigned char *
45 #define WCHAR unsigned short
46 #define PWCHAR unsigned short *
47 #define SHORT short
48 #define USHORT unsigned short
49 #define PUSHORT unsigned short *
50 #define LONG long
51 #define ULONG unsigned long
52 #define PULONG unsigned long *
53 #define PDWORD DWORD *
54 #define PWORD WORD *
55 #define VOID void
56 #define PVOID VOID*
57 #define INT8 char
58 #define UINT8 unsigned char
59 #define INT16 short
60 #define UINT16 unsigned short
61 #define INT32 long
62 #define UINT32 unsigned long
63 #define PUINT32 UINT32 *
64 #define INT64 long long
65 #define UINT64 unsigned long long
66
67 #define ROUND_UP(N, S) ((((N) + (S) - 1) / (S)) * (S))
68
69 #define PACKED __attribute__((packed))
70
71 extern ULONG BootDrive; // BIOS boot drive, 0-A:, 1-B:, 0x80-C:, 0x81-D:, etc.
72 extern ULONG BootPartition; // Boot Partition, 1-4
73 extern BOOL UserInterfaceUp; // Tells us if the user interface is displayed
74
75 extern PUCHAR ScreenBuffer; // Save buffer for screen contents
76 extern ULONG CursorXPos; // Cursor's X Position
77 extern ULONG CursorYPos; // Cursor's Y Position
78
79 void BootMain(void);
80
81 #endif // defined __FREELDR_H