Replace BOOL by BOOLEAN and STDCALL by NTAPI

(Use native types instead of Win32 ones)

svn path=/trunk/; revision=21917
This commit is contained in:
Hervé Poussineau 2006-05-16 23:09:41 +00:00
parent 8a1609a63e
commit 4c27d61b0c
76 changed files with 425 additions and 425 deletions

View file

@ -583,7 +583,7 @@ DetectBiosDisks(FRLDRHKEY SystemKey,
ULONG Size; ULONG Size;
ULONG i; ULONG i;
LONG Error; LONG Error;
BOOL Changed; BOOLEAN Changed;
/* Count the number of visible drives */ /* Count the number of visible drives */
DiskReportError(FALSE); DiskReportError(FALSE);

View file

@ -25,7 +25,7 @@
BOOLEAN AcpiPresent = FALSE; BOOLEAN AcpiPresent = FALSE;
static BOOL static BOOLEAN
FindAcpiBios(VOID) FindAcpiBios(VOID)
{ {
PUCHAR Ptr; PUCHAR Ptr;

View file

@ -23,7 +23,7 @@
#define NDEBUG #define NDEBUG
#include <debug.h> #include <debug.h>
static BOOL static BOOLEAN
FindApmBios(VOID) FindApmBios(VOID)
{ {
REGS RegsIn; REGS RegsIn;

View file

@ -117,7 +117,7 @@ DetectCPU(FRLDRHKEY CpuKey,
ULONG edx = 0; ULONG edx = 0;
ULONG *Ptr; ULONG *Ptr;
LONG Error; LONG Error;
BOOL SupportTSC = FALSE; BOOLEAN SupportTSC = FALSE;
ULONG CpuSpeed; ULONG CpuSpeed;
@ -495,7 +495,7 @@ GetMpConfigurationTable(PMP_FLOATING_POINT_TABLE FpTable)
} }
static BOOL static BOOLEAN
DetectMps(FRLDRHKEY CpuKey, DetectMps(FRLDRHKEY CpuKey,
FRLDRHKEY FpuKey) FRLDRHKEY FpuKey)
{ {

View file

@ -105,7 +105,7 @@ GetPciIrqRoutingTable(VOID)
} }
static BOOL static BOOLEAN
FindPciBios(PCM_PCI_BUS_DATA BusData) FindPciBios(PCM_PCI_BUS_DATA BusData)
{ {
REGS RegsIn; REGS RegsIn;

View file

@ -28,7 +28,7 @@
#ifdef __i386__ #ifdef __i386__
BOOL DiskResetController(ULONG DriveNumber) BOOLEAN DiskResetController(ULONG DriveNumber)
{ {
REGS RegsIn; REGS RegsIn;
REGS RegsOut; REGS RegsOut;
@ -51,7 +51,7 @@ BOOL DiskResetController(ULONG DriveNumber)
return INT386_SUCCESS(RegsOut); return INT386_SUCCESS(RegsOut);
} }
BOOL DiskInt13ExtensionsSupported(ULONG DriveNumber) BOOLEAN DiskInt13ExtensionsSupported(ULONG DriveNumber)
{ {
REGS RegsIn; REGS RegsIn;
REGS RegsOut; REGS RegsOut;
@ -129,7 +129,7 @@ VOID DiskStopFloppyMotor(VOID)
WRITE_PORT_UCHAR((PUCHAR)0x3F2, 0); WRITE_PORT_UCHAR((PUCHAR)0x3F2, 0);
} }
BOOL DiskGetExtendedDriveParameters(ULONG DriveNumber, PVOID Buffer, USHORT BufferSize) BOOLEAN DiskGetExtendedDriveParameters(ULONG DriveNumber, PVOID Buffer, USHORT BufferSize)
{ {
REGS RegsIn; REGS RegsIn;
REGS RegsOut; REGS RegsOut;
@ -200,7 +200,7 @@ BOOL DiskGetExtendedDriveParameters(ULONG DriveNumber, PVOID Buffer, USHORT Buff
return TRUE; return TRUE;
} }
BOOL i386DiskGetBootVolume(PULONG DriveNumber, PULONGLONG StartSector, PULONGLONG SectorCount, int *FsType) BOOLEAN i386DiskGetBootVolume(PULONG DriveNumber, PULONGLONG StartSector, PULONGLONG SectorCount, int *FsType)
{ {
PARTITION_TABLE_ENTRY PartitionTableEntry; PARTITION_TABLE_ENTRY PartitionTableEntry;
UCHAR VolumeType; UCHAR VolumeType;
@ -318,7 +318,7 @@ i386DiskGetBootDevice(PULONG BootDevice)
((char *)BootDevice)[1] = (char)i386BootPartition; ((char *)BootDevice)[1] = (char)i386BootPartition;
} }
BOOL BOOLEAN
i386DiskBootingFromFloppy(VOID) i386DiskBootingFromFloppy(VOID)
{ {
return i386BootDrive < 0x80; return i386BootDrive < 0x80;
@ -338,7 +338,7 @@ i386DiskBootingFromFloppy(VOID)
((P) == PARTITION_EXTENDED || \ ((P) == PARTITION_EXTENDED || \
(P) == PARTITION_XINT13_EXTENDED) (P) == PARTITION_XINT13_EXTENDED)
BOOL i386DiskGetSystemVolume(char *SystemPath, BOOLEAN i386DiskGetSystemVolume(char *SystemPath,
char *RemainingPath, char *RemainingPath,
PULONG Device, PULONG Device,
PULONG DriveNumber, PULONG DriveNumber,
@ -445,7 +445,7 @@ BOOL i386DiskGetSystemVolume(char *SystemPath,
return FALSE; return FALSE;
} }
BOOL BOOLEAN
i386DiskGetBootPath(char *BootPath, unsigned Size) i386DiskGetBootPath(char *BootPath, unsigned Size)
{ {
static char Path[] = "multi(0)disk(0)"; static char Path[] = "multi(0)disk(0)";
@ -463,7 +463,7 @@ i386DiskGetBootPath(char *BootPath, unsigned Size)
return TRUE; return TRUE;
} }
BOOL BOOLEAN
i386DiskNormalizeSystemPath(char *SystemPath, unsigned Size) i386DiskNormalizeSystemPath(char *SystemPath, unsigned Size)
{ {
CHAR BootPath[256]; CHAR BootPath[256];

View file

@ -150,7 +150,7 @@ extern PAGE_DIRECTORY_X64 kpcr_pagetable_pae;
* *
*--*/ *--*/
VOID VOID
STDCALL NTAPI
FrLdrStartup(ULONG Magic) FrLdrStartup(ULONG Magic)
{ {
/* Disable Interrupts */ /* Disable Interrupts */
@ -543,8 +543,8 @@ FrLdrSetupPageDirectory(VOID)
* None. * None.
* *
*--*/ *--*/
BOOL BOOLEAN
STDCALL NTAPI
FrLdrMapKernel(FILE *KernelImage) FrLdrMapKernel(FILE *KernelImage)
{ {
PIMAGE_DOS_HEADER ImageHeader; PIMAGE_DOS_HEADER ImageHeader;
@ -701,7 +701,7 @@ FrLdrMapKernel(FILE *KernelImage)
} }
ULONG_PTR ULONG_PTR
STDCALL NTAPI
FrLdrLoadModule(FILE *ModuleImage, FrLdrLoadModule(FILE *ModuleImage,
LPCSTR ModuleName, LPCSTR ModuleName,
PULONG ModuleSize) PULONG ModuleSize)
@ -753,7 +753,7 @@ FrLdrLoadModule(FILE *ModuleImage,
} }
ULONG_PTR ULONG_PTR
STDCALL NTAPI
FrLdrCreateModule(LPCSTR ModuleName) FrLdrCreateModule(LPCSTR ModuleName)
{ {
PLOADER_MODULE ModuleData; PLOADER_MODULE ModuleData;
@ -778,8 +778,8 @@ FrLdrCreateModule(LPCSTR ModuleName)
return(ModuleData->ModStart); return(ModuleData->ModStart);
} }
BOOL BOOLEAN
STDCALL NTAPI
FrLdrCloseModule(ULONG_PTR ModuleBase, FrLdrCloseModule(ULONG_PTR ModuleBase,
ULONG ModuleSize) ULONG ModuleSize)
{ {

View file

@ -66,7 +66,7 @@ PcConsPutChar(int Ch)
Int386(0x10, &Regs, &Regs); Int386(0x10, &Regs, &Regs);
} }
BOOL BOOLEAN
PcConsKbHit(VOID) PcConsKbHit(VOID)
{ {
REGS Regs; REGS Regs;
@ -91,7 +91,7 @@ int
PcConsGetCh(void) PcConsGetCh(void)
{ {
REGS Regs; REGS Regs;
static BOOL ExtendedKey = FALSE; static BOOLEAN ExtendedKey = FALSE;
static char ExtendedScanCode = 0; static char ExtendedScanCode = 0;
/* If the last time we were called an /* If the last time we were called an

View file

@ -38,7 +38,7 @@ typedef struct
// FUNCTIONS // FUNCTIONS
///////////////////////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////////////////////
static BOOL PcDiskResetController(ULONG DriveNumber) static BOOLEAN PcDiskResetController(ULONG DriveNumber)
{ {
REGS RegsIn; REGS RegsIn;
REGS RegsOut; REGS RegsOut;
@ -61,7 +61,7 @@ static BOOL PcDiskResetController(ULONG DriveNumber)
return INT386_SUCCESS(RegsOut); return INT386_SUCCESS(RegsOut);
} }
static BOOL PcDiskReadLogicalSectorsLBA(ULONG DriveNumber, ULONGLONG SectorNumber, ULONG SectorCount, PVOID Buffer) static BOOLEAN PcDiskReadLogicalSectorsLBA(ULONG DriveNumber, ULONGLONG SectorNumber, ULONG SectorCount, PVOID Buffer)
{ {
REGS RegsIn; REGS RegsIn;
REGS RegsOut; REGS RegsOut;
@ -125,7 +125,7 @@ static BOOL PcDiskReadLogicalSectorsLBA(ULONG DriveNumber, ULONGLONG SectorNumbe
return FALSE; return FALSE;
} }
static BOOL PcDiskReadLogicalSectorsCHS(ULONG DriveNumber, ULONGLONG SectorNumber, ULONG SectorCount, PVOID Buffer) static BOOLEAN PcDiskReadLogicalSectorsCHS(ULONG DriveNumber, ULONGLONG SectorNumber, ULONG SectorCount, PVOID Buffer)
{ {
ULONG PhysicalSector; ULONG PhysicalSector;
ULONG PhysicalHead; ULONG PhysicalHead;
@ -261,10 +261,10 @@ static BOOL PcDiskReadLogicalSectorsCHS(ULONG DriveNumber, ULONGLONG SectorNumbe
return TRUE; return TRUE;
} }
static BOOL PcDiskInt13ExtensionsSupported(ULONG DriveNumber) static BOOLEAN PcDiskInt13ExtensionsSupported(ULONG DriveNumber)
{ {
static ULONG LastDriveNumber = 0xffffffff; static ULONG LastDriveNumber = 0xffffffff;
static BOOL LastSupported; static BOOLEAN LastSupported;
REGS RegsIn; REGS RegsIn;
REGS RegsOut; REGS RegsOut;
@ -350,7 +350,7 @@ static BOOL PcDiskInt13ExtensionsSupported(ULONG DriveNumber)
return TRUE; return TRUE;
} }
BOOL PcDiskReadLogicalSectors(ULONG DriveNumber, ULONGLONG SectorNumber, ULONG SectorCount, PVOID Buffer) BOOLEAN PcDiskReadLogicalSectors(ULONG DriveNumber, ULONGLONG SectorNumber, ULONG SectorCount, PVOID Buffer)
{ {
DbgPrint((DPRINT_DISK, "PcDiskReadLogicalSectors() DriveNumber: 0x%x SectorNumber: %I64d SectorCount: %d Buffer: 0x%x\n", DriveNumber, SectorNumber, SectorCount, Buffer)); DbgPrint((DPRINT_DISK, "PcDiskReadLogicalSectors() DriveNumber: 0x%x SectorNumber: %I64d SectorCount: %d Buffer: 0x%x\n", DriveNumber, SectorNumber, SectorCount, Buffer));
@ -379,14 +379,14 @@ BOOL PcDiskReadLogicalSectors(ULONG DriveNumber, ULONGLONG SectorNumber, ULONG S
return TRUE; return TRUE;
} }
BOOL BOOLEAN
PcDiskGetPartitionEntry(ULONG DriveNumber, ULONG PartitionNumber, PPARTITION_TABLE_ENTRY PartitionTableEntry) PcDiskGetPartitionEntry(ULONG DriveNumber, ULONG PartitionNumber, PPARTITION_TABLE_ENTRY PartitionTableEntry)
{ {
/* Just use the standard routine */ /* Just use the standard routine */
return DiskGetPartitionEntry(DriveNumber, PartitionNumber, PartitionTableEntry); return DiskGetPartitionEntry(DriveNumber, PartitionNumber, PartitionTableEntry);
} }
BOOL BOOLEAN
PcDiskGetDriveGeometry(ULONG DriveNumber, PGEOMETRY Geometry) PcDiskGetDriveGeometry(ULONG DriveNumber, PGEOMETRY Geometry)
{ {
REGS RegsIn; REGS RegsIn;

View file

@ -111,7 +111,7 @@ static ULONG ScreenWidth = 80; /* Screen Width in charact
static ULONG ScreenHeight = 25; /* Screen Height in characters */ static ULONG ScreenHeight = 25; /* Screen Height in characters */
static ULONG BytesPerScanLine = 160; /* Number of bytes per scanline (delta) */ static ULONG BytesPerScanLine = 160; /* Number of bytes per scanline (delta) */
static VIDEODISPLAYMODE DisplayMode = VideoTextMode; /* Current display mode */ static VIDEODISPLAYMODE DisplayMode = VideoTextMode; /* Current display mode */
static BOOL VesaVideoMode = FALSE; /* Are we using a VESA mode? */ static BOOLEAN VesaVideoMode = FALSE; /* Are we using a VESA mode? */
static SVGA_MODE_INFORMATION VesaVideoModeInformation; /* Only valid when in VESA mode */ static SVGA_MODE_INFORMATION VesaVideoModeInformation; /* Only valid when in VESA mode */
static ULONG CurrentMemoryBank = 0; /* Currently selected VESA bank */ static ULONG CurrentMemoryBank = 0; /* Currently selected VESA bank */
@ -437,7 +437,7 @@ PcVideoSetDisplayEnd(VOID)
WRITE_PORT_UCHAR((PUCHAR)CRTC+1, 0xDF); WRITE_PORT_UCHAR((PUCHAR)CRTC+1, 0xDF);
} }
static BOOL static BOOLEAN
PcVideoVesaGetSVGAModeInformation(USHORT Mode, PSVGA_MODE_INFORMATION ModeInformation) PcVideoVesaGetSVGAModeInformation(USHORT Mode, PSVGA_MODE_INFORMATION ModeInformation)
{ {
REGS Regs; REGS Regs;
@ -509,7 +509,7 @@ PcVideoVesaGetSVGAModeInformation(USHORT Mode, PSVGA_MODE_INFORMATION ModeInform
return TRUE; return TRUE;
} }
static BOOL static BOOLEAN
PcVideoSetBiosVesaMode(USHORT Mode) PcVideoSetBiosVesaMode(USHORT Mode)
{ {
REGS Regs; REGS Regs;
@ -581,7 +581,7 @@ PcVideoSetBiosVesaMode(USHORT Mode)
return TRUE; return TRUE;
} }
static BOOL static BOOLEAN
PcVideoSetMode80x25(VOID) PcVideoSetMode80x25(VOID)
{ {
PcVideoSetBiosMode(0x03); PcVideoSetBiosMode(0x03);
@ -591,7 +591,7 @@ PcVideoSetMode80x25(VOID)
return TRUE; return TRUE;
} }
static BOOL static BOOLEAN
PcVideoSetMode80x50_80x43(VOID) PcVideoSetMode80x50_80x43(VOID)
{ {
if (VIDEOCARD_VGA == PcVideoDetectVideoCard()) if (VIDEOCARD_VGA == PcVideoDetectVideoCard())
@ -622,7 +622,7 @@ PcVideoSetMode80x50_80x43(VOID)
return TRUE; return TRUE;
} }
static BOOL static BOOLEAN
PcVideoSetMode80x28(VOID) PcVideoSetMode80x28(VOID)
{ {
/* FIXME: Is this VGA-only? */ /* FIXME: Is this VGA-only? */
@ -635,7 +635,7 @@ PcVideoSetMode80x28(VOID)
return TRUE; return TRUE;
} }
static BOOL static BOOLEAN
PcVideoSetMode80x30(VOID) PcVideoSetMode80x30(VOID)
{ {
/* FIXME: Is this VGA-only? */ /* FIXME: Is this VGA-only? */
@ -647,7 +647,7 @@ PcVideoSetMode80x30(VOID)
return TRUE; return TRUE;
} }
static BOOL static BOOLEAN
PcVideoSetMode80x34(VOID) PcVideoSetMode80x34(VOID)
{ {
/* FIXME: Is this VGA-only? */ /* FIXME: Is this VGA-only? */
@ -662,7 +662,7 @@ PcVideoSetMode80x34(VOID)
return TRUE; return TRUE;
} }
static BOOL static BOOLEAN
PcVideoSetMode80x43(VOID) PcVideoSetMode80x43(VOID)
{ {
/* FIXME: Is this VGA-only? */ /* FIXME: Is this VGA-only? */
@ -678,7 +678,7 @@ PcVideoSetMode80x43(VOID)
return TRUE; return TRUE;
} }
static BOOL static BOOLEAN
PcVideoSetMode80x60(VOID) PcVideoSetMode80x60(VOID)
{ {
/* FIXME: Is this VGA-only? */ /* FIXME: Is this VGA-only? */
@ -695,7 +695,7 @@ PcVideoSetMode80x60(VOID)
return TRUE; return TRUE;
} }
static BOOL static BOOLEAN
PcVideoSetMode(ULONG NewMode) PcVideoSetMode(ULONG NewMode)
{ {
CurrentMemoryBank = 0; CurrentMemoryBank = 0;
@ -804,7 +804,7 @@ PcVideoSetMode(ULONG NewMode)
} }
static VOID static VOID
PcVideoSetBlinkBit(BOOL Enable) PcVideoSetBlinkBit(BOOLEAN Enable)
{ {
REGS Regs; REGS Regs;
@ -867,7 +867,7 @@ PcVideoSetMemoryBank(USHORT BankNumber)
} }
VIDEODISPLAYMODE VIDEODISPLAYMODE
PcVideoSetDisplayMode(char *DisplayModeName, BOOL Init) PcVideoSetDisplayMode(char *DisplayModeName, BOOLEAN Init)
{ {
ULONG VideoMode = VIDEOMODE_NORMAL_TEXT; ULONG VideoMode = VIDEOMODE_NORMAL_TEXT;
@ -981,7 +981,7 @@ PcVideoSetTextCursorPosition(ULONG X, ULONG Y)
} }
VOID VOID
PcVideoHideShowTextCursor(BOOL Show) PcVideoHideShowTextCursor(BOOLEAN Show)
{ {
if (Show) if (Show)
{ {
@ -1058,7 +1058,7 @@ PcVideoPutChar(int Ch, UCHAR Attr, unsigned X, unsigned Y)
*BufPtr = ((USHORT) Attr << 8) | (Ch & 0xff); *BufPtr = ((USHORT) Attr << 8) | (Ch & 0xff);
} }
BOOL BOOLEAN
PcVideoIsPaletteFixed(VOID) PcVideoIsPaletteFixed(VOID)
{ {
return FALSE; return FALSE;

View file

@ -56,7 +56,7 @@ XboxConsPutChar(int c)
} }
} }
BOOL BOOLEAN
XboxConsKbHit(VOID) XboxConsKbHit(VOID)
{ {
/* No keyboard support yet */ /* No keyboard support yet */

View file

@ -258,10 +258,10 @@ typedef struct _IDE_DRIVE_IDENTIFY
* PVOID Buffer Buffer for output data * PVOID Buffer Buffer for output data
* *
* RETURNS: * RETURNS:
* BOOL: TRUE success, FALSE error * BOOLEAN: TRUE success, FALSE error
*/ */
static BOOL static BOOLEAN
XboxDiskPolledRead(ULONG CommandPort, XboxDiskPolledRead(ULONG CommandPort,
ULONG ControlPort, ULONG ControlPort,
UCHAR PreComp, UCHAR PreComp,
@ -275,7 +275,7 @@ XboxDiskPolledRead(ULONG CommandPort,
{ {
ULONG SectorCount = 0; ULONG SectorCount = 0;
ULONG RetryCount; ULONG RetryCount;
BOOL Junk = FALSE; BOOLEAN Junk = FALSE;
UCHAR Status; UCHAR Status;
/* Wait for BUSY to clear */ /* Wait for BUSY to clear */
@ -434,7 +434,7 @@ XboxDiskPolledRead(ULONG CommandPort,
} }
} }
BOOL BOOLEAN
XboxDiskReadLogicalSectors(ULONG DriveNumber, ULONGLONG SectorNumber, ULONG SectorCount, PVOID Buffer) XboxDiskReadLogicalSectors(ULONG DriveNumber, ULONGLONG SectorNumber, ULONG SectorCount, PVOID Buffer)
{ {
ULONG StartSector; ULONG StartSector;
@ -477,7 +477,7 @@ XboxDiskReadLogicalSectors(ULONG DriveNumber, ULONGLONG SectorNumber, ULONG Sect
return TRUE; return TRUE;
} }
BOOL BOOLEAN
XboxDiskGetPartitionEntry(ULONG DriveNumber, ULONG PartitionNumber, PPARTITION_TABLE_ENTRY PartitionTableEntry) XboxDiskGetPartitionEntry(ULONG DriveNumber, ULONG PartitionNumber, PPARTITION_TABLE_ENTRY PartitionTableEntry)
{ {
UCHAR SectorData[IDE_SECTOR_BUF_SZ]; UCHAR SectorData[IDE_SECTOR_BUF_SZ];
@ -502,12 +502,12 @@ XboxDiskGetPartitionEntry(ULONG DriveNumber, ULONG PartitionNumber, PPARTITION_T
return DiskGetPartitionEntry(DriveNumber, PartitionNumber, PartitionTableEntry); return DiskGetPartitionEntry(DriveNumber, PartitionNumber, PartitionTableEntry);
} }
BOOL BOOLEAN
XboxDiskGetDriveGeometry(ULONG DriveNumber, PGEOMETRY Geometry) XboxDiskGetDriveGeometry(ULONG DriveNumber, PGEOMETRY Geometry)
{ {
IDE_DRIVE_IDENTIFY DrvParms; IDE_DRIVE_IDENTIFY DrvParms;
ULONG i; ULONG i;
BOOL Atapi; BOOLEAN Atapi;
Atapi = FALSE; /* FIXME */ Atapi = FALSE; /* FIXME */
/* Get the Drive Identify block from drive or die */ /* Get the Drive Identify block from drive or die */

View file

@ -24,7 +24,7 @@
#define I2C_IO_BASE 0xc000 #define I2C_IO_BASE 0xc000
static BOOL static BOOLEAN
WriteToSMBus(UCHAR Address, UCHAR bRegister, UCHAR Size, ULONG Data_to_smbus) WriteToSMBus(UCHAR Address, UCHAR bRegister, UCHAR Size, ULONG Data_to_smbus)
{ {
int nRetriesToLive=50; int nRetriesToLive=50;
@ -95,7 +95,7 @@ WriteToSMBus(UCHAR Address, UCHAR bRegister, UCHAR Size, ULONG Data_to_smbus)
} }
static BOOL static BOOLEAN
ReadfromSMBus(UCHAR Address, UCHAR bRegister, UCHAR Size, ULONG *Data_to_smbus) ReadfromSMBus(UCHAR Address, UCHAR bRegister, UCHAR Size, ULONG *Data_to_smbus)
{ {
int nRetriesToLive=50; int nRetriesToLive=50;
@ -172,14 +172,14 @@ ReadfromSMBus(UCHAR Address, UCHAR bRegister, UCHAR Size, ULONG *Data_to_smbus)
return FALSE; return FALSE;
} }
BOOL BOOLEAN
I2CTransmitByteGetReturn(UCHAR bPicAddressI2cFormat, UCHAR bDataToWrite, ULONG *Return) I2CTransmitByteGetReturn(UCHAR bPicAddressI2cFormat, UCHAR bDataToWrite, ULONG *Return)
{ {
return ReadfromSMBus(bPicAddressI2cFormat, bDataToWrite, 1, Return); return ReadfromSMBus(bPicAddressI2cFormat, bDataToWrite, 1, Return);
} }
// transmit a word, no returned data from I2C device // transmit a word, no returned data from I2C device
static BOOL static BOOLEAN
I2CTransmitWord(UCHAR bPicAddressI2cFormat, USHORT wDataToWrite) I2CTransmitWord(UCHAR bPicAddressI2cFormat, USHORT wDataToWrite)
{ {
return WriteToSMBus(bPicAddressI2cFormat,(wDataToWrite>>8)&0xff,1,(wDataToWrite&0xff)); return WriteToSMBus(bPicAddressI2cFormat,(wDataToWrite>>8)&0xff,1,(wDataToWrite&0xff));

View file

@ -37,7 +37,7 @@ static ULONG Delta;
#define MAKE_COLOR(Red, Green, Blue) (0xff000000 | (((Red) & 0xff) << 16) | (((Green) & 0xff) << 8) | ((Blue) & 0xff)) #define MAKE_COLOR(Red, Green, Blue) (0xff000000 | (((Red) & 0xff) << 16) | (((Green) & 0xff) << 8) | ((Blue) & 0xff))
BOOL I2CTransmitByteGetReturn(UCHAR bPicAddressI2cFormat, UCHAR bDataToWrite, ULONG *Return); BOOLEAN I2CTransmitByteGetReturn(UCHAR bPicAddressI2cFormat, UCHAR bDataToWrite, ULONG *Return);
static VOID static VOID
XboxVideoOutputChar(UCHAR Char, unsigned X, unsigned Y, ULONG FgColor, ULONG BgColor) XboxVideoOutputChar(UCHAR Char, unsigned X, unsigned Y, ULONG FgColor, ULONG BgColor)
@ -84,7 +84,7 @@ XboxVideoAttrToColors(UCHAR Attr, ULONG *FgColor, ULONG *BgColor)
} }
static VOID static VOID
XboxVideoClearScreenColor(ULONG Color, BOOL FullScreen) XboxVideoClearScreenColor(ULONG Color, BOOLEAN FullScreen)
{ {
ULONG Line, Col; ULONG Line, Col;
PULONG p; PULONG p;
@ -161,7 +161,7 @@ XboxVideoInit(VOID)
} }
VIDEODISPLAYMODE VIDEODISPLAYMODE
XboxVideoSetDisplayMode(char *DisplayMode, BOOL Init) XboxVideoSetDisplayMode(char *DisplayMode, BOOLEAN Init)
{ {
/* We only have one mode, semi-text */ /* We only have one mode, semi-text */
return VideoTextMode; return VideoTextMode;
@ -188,7 +188,7 @@ XboxVideoSetTextCursorPosition(ULONG X, ULONG Y)
} }
VOID VOID
XboxVideoHideShowTextCursor(BOOL Show) XboxVideoHideShowTextCursor(BOOLEAN Show)
{ {
/* We don't have a cursor yet */ /* We don't have a cursor yet */
} }
@ -209,7 +209,7 @@ XboxVideoCopyOffScreenBufferToVRAM(PVOID Buffer)
} }
} }
BOOL BOOLEAN
XboxVideoIsPaletteFixed(VOID) XboxVideoIsPaletteFixed(VOID)
{ {
return FALSE; return FALSE;

View file

@ -175,7 +175,7 @@ int PpcFindDevice( int depth, int parent, char *devname, int *nth ) {
return 0; return 0;
} }
BOOL PpcConsKbHit() { BOOLEAN PpcConsKbHit() {
return TRUE; return TRUE;
} }
@ -189,7 +189,7 @@ void PpcVideoClearScreen( UCHAR Attr ) {
ofw_print_string("ClearScreen\n"); ofw_print_string("ClearScreen\n");
} }
VIDEODISPLAYMODE PpcVideoSetDisplayMode( char *DisplayMode, BOOL Init ) { VIDEODISPLAYMODE PpcVideoSetDisplayMode( char *DisplayMode, BOOLEAN Init ) {
printf( "DisplayMode: %s %s\n", DisplayMode, Init ? "true" : "false" ); printf( "DisplayMode: %s %s\n", DisplayMode, Init ? "true" : "false" );
return VideoGraphicsMode; return VideoGraphicsMode;
} }
@ -213,7 +213,7 @@ VOID PpcVideoSetTextCursorPosition( ULONG X, ULONG Y ) {
printf("SetTextCursorPosition(%d,%d)\n", X,Y); printf("SetTextCursorPosition(%d,%d)\n", X,Y);
} }
VOID PpcVideoHideShowTextCursor( BOOL Show ) { VOID PpcVideoHideShowTextCursor( BOOLEAN Show ) {
printf("HideShowTextCursor(%s)\n", Show ? "true" : "false"); printf("HideShowTextCursor(%s)\n", Show ? "true" : "false");
} }
@ -225,7 +225,7 @@ VOID PpcVideoCopyOffScreenBufferToVRAM( PVOID Buffer ) {
printf( "CopyOffScreenBufferToVRAM(%x)\n", Buffer ); printf( "CopyOffScreenBufferToVRAM(%x)\n", Buffer );
} }
BOOL PpcVideoIsPaletteFixed() { BOOLEAN PpcVideoIsPaletteFixed() {
return FALSE; return FALSE;
} }
@ -273,7 +273,7 @@ ULONG PpcGetMemoryMap( PBIOS_MEMORY_MAP BiosMemoryMap,
* away with grabbing a partition image by tftp in this scenario. * away with grabbing a partition image by tftp in this scenario.
*/ */
BOOL PpcDiskGetBootVolume( PULONG DriveNumber, PULONGLONG StartSector, PULONGLONG SectorCount, int *FsType ) { BOOLEAN PpcDiskGetBootVolume( PULONG DriveNumber, PULONGLONG StartSector, PULONGLONG SectorCount, int *FsType ) {
*DriveNumber = 0; *DriveNumber = 0;
*StartSector = 0; *StartSector = 0;
*SectorCount = 0; *SectorCount = 0;
@ -281,7 +281,7 @@ BOOL PpcDiskGetBootVolume( PULONG DriveNumber, PULONGLONG StartSector, PULONGLON
return TRUE; return TRUE;
} }
BOOL PpcDiskGetSystemVolume( char *SystemPath, BOOLEAN PpcDiskGetSystemVolume( char *SystemPath,
char *RemainingPath, char *RemainingPath,
PULONG Device, PULONG Device,
PULONG DriveNumber, PULONG DriveNumber,
@ -291,7 +291,7 @@ BOOL PpcDiskGetSystemVolume( char *SystemPath,
return FALSE; return FALSE;
} }
BOOL PpcDiskGetBootPath( char *OutBootPath, unsigned Size ) { BOOLEAN PpcDiskGetBootPath( char *OutBootPath, unsigned Size ) {
strncpy( OutBootPath, BootPath, Size ); strncpy( OutBootPath, BootPath, Size );
return TRUE; return TRUE;
} }
@ -300,11 +300,11 @@ VOID PpcDiskGetBootDevice( PULONG BootDevice ) {
BootDevice[0] = BootDevice[1] = 0; BootDevice[0] = BootDevice[1] = 0;
} }
BOOL PpcDiskBootingFromFloppy(VOID) { BOOLEAN PpcDiskBootingFromFloppy(VOID) {
return FALSE; return FALSE;
} }
BOOL PpcDiskReadLogicalSectors( ULONG DriveNumber, ULONGLONG SectorNumber, BOOLEAN PpcDiskReadLogicalSectors( ULONG DriveNumber, ULONGLONG SectorNumber,
ULONG SectorCount, PVOID Buffer ) { ULONG SectorCount, PVOID Buffer ) {
int rlen = 0; int rlen = 0;
@ -330,13 +330,13 @@ BOOL PpcDiskReadLogicalSectors( ULONG DriveNumber, ULONGLONG SectorNumber,
return rlen > 0; return rlen > 0;
} }
BOOL PpcDiskGetPartitionEntry( ULONG DriveNumber, ULONG PartitionNumber, BOOLEAN PpcDiskGetPartitionEntry( ULONG DriveNumber, ULONG PartitionNumber,
PPARTITION_TABLE_ENTRY PartitionTableEntry ) { PPARTITION_TABLE_ENTRY PartitionTableEntry ) {
printf("GetPartitionEntry(%d,%d)\n", DriveNumber, PartitionNumber); printf("GetPartitionEntry(%d,%d)\n", DriveNumber, PartitionNumber);
return FALSE; return FALSE;
} }
BOOL PpcDiskGetDriveGeometry( ULONG DriveNumber, PGEOMETRY DriveGeometry ) { BOOLEAN PpcDiskGetDriveGeometry( ULONG DriveNumber, PGEOMETRY DriveGeometry ) {
printf("GetGeometry(%d)\n", DriveNumber); printf("GetGeometry(%d)\n", DriveNumber);
DriveGeometry->BytesPerSector = 512; DriveGeometry->BytesPerSector = 512;
DriveGeometry->Heads = 16; DriveGeometry->Heads = 16;
@ -463,7 +463,7 @@ void MachInit(const char *CmdLine) {
void beep() { void beep() {
} }
UCHAR STDCALL READ_PORT_UCHAR(PUCHAR Address) { UCHAR NTAPI READ_PORT_UCHAR(PUCHAR Address) {
return 0xff; return 0xff;
} }

View file

@ -89,7 +89,7 @@ ULONG_PTR KernelEntry;
* *
*--*/ *--*/
VOID VOID
STDCALL NTAPI
FrLdrStartup(ULONG Magic) FrLdrStartup(ULONG Magic)
{ {
#if 0 #if 0
@ -377,8 +377,8 @@ FrLdrSetupPageDirectory(VOID)
* None. * None.
* *
*--*/ *--*/
BOOL BOOLEAN
STDCALL NTAPI
FrLdrMapKernel(FILE *KernelImage) FrLdrMapKernel(FILE *KernelImage)
{ {
#if 0 #if 0
@ -540,7 +540,7 @@ FrLdrMapKernel(FILE *KernelImage)
} }
ULONG_PTR ULONG_PTR
STDCALL NTAPI
FrLdrLoadModule(FILE *ModuleImage, FrLdrLoadModule(FILE *ModuleImage,
LPCSTR ModuleName, LPCSTR ModuleName,
PULONG ModuleSize) PULONG ModuleSize)
@ -596,7 +596,7 @@ FrLdrLoadModule(FILE *ModuleImage,
} }
ULONG_PTR ULONG_PTR
STDCALL NTAPI
FrLdrCreateModule(LPCSTR ModuleName) FrLdrCreateModule(LPCSTR ModuleName)
{ {
#if 0 #if 0
@ -625,8 +625,8 @@ FrLdrCreateModule(LPCSTR ModuleName)
#endif #endif
} }
BOOL BOOLEAN
STDCALL NTAPI
FrLdrCloseModule(ULONG_PTR ModuleBase, FrLdrCloseModule(ULONG_PTR ModuleBase,
ULONG ModuleSize) ULONG ModuleSize)
{ {

View file

@ -214,7 +214,7 @@ LONG GetTimeOut(VOID)
return TimeOut; return TimeOut;
} }
BOOL MainBootMenuKeyPressFilter(ULONG KeyPress) BOOLEAN MainBootMenuKeyPressFilter(ULONG KeyPress)
{ {
if (KeyPress == KEY_F8) if (KeyPress == KEY_F8)
{ {

View file

@ -145,7 +145,7 @@ PCACHE_BLOCK CacheInternalAddBlockToCache(PCACHE_DRIVE CacheDrive, ULONG BlockNu
return CacheBlock; return CacheBlock;
} }
BOOL CacheInternalFreeBlock(PCACHE_DRIVE CacheDrive) BOOLEAN CacheInternalFreeBlock(PCACHE_DRIVE CacheDrive)
{ {
PCACHE_BLOCK CacheBlockToFree; PCACHE_BLOCK CacheBlockToFree;

View file

@ -28,13 +28,13 @@
// //
/////////////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////////////
CACHE_DRIVE CacheManagerDrive; CACHE_DRIVE CacheManagerDrive;
BOOL CacheManagerInitialized = FALSE; BOOLEAN CacheManagerInitialized = FALSE;
BOOL CacheManagerDataInvalid = FALSE; BOOLEAN CacheManagerDataInvalid = FALSE;
ULONG CacheBlockCount = 0; ULONG CacheBlockCount = 0;
ULONG CacheSizeLimit = 0; ULONG CacheSizeLimit = 0;
ULONG CacheSizeCurrent = 0; ULONG CacheSizeCurrent = 0;
BOOL CacheInitializeDrive(ULONG DriveNumber) BOOLEAN CacheInitializeDrive(ULONG DriveNumber)
{ {
PCACHE_BLOCK NextCacheBlock; PCACHE_BLOCK NextCacheBlock;
GEOMETRY DriveGeometry; GEOMETRY DriveGeometry;
@ -112,7 +112,7 @@ VOID CacheInvalidateCacheData(VOID)
CacheManagerDataInvalid = TRUE; CacheManagerDataInvalid = TRUE;
} }
BOOL CacheReadDiskSectors(ULONG DiskNumber, ULONG StartSector, ULONG SectorCount, PVOID Buffer) BOOLEAN CacheReadDiskSectors(ULONG DiskNumber, ULONG StartSector, ULONG SectorCount, PVOID Buffer)
{ {
PCACHE_BLOCK CacheBlock; PCACHE_BLOCK CacheBlock;
ULONG StartBlock; ULONG StartBlock;
@ -244,7 +244,7 @@ BOOL CacheReadDiskSectors(ULONG DiskNumber, ULONG StartSector, ULONG SectorCount
return TRUE; return TRUE;
} }
BOOL CacheForceDiskSectorsIntoCache(ULONG DiskNumber, ULONG StartSector, ULONG SectorCount) BOOLEAN CacheForceDiskSectorsIntoCache(ULONG DiskNumber, ULONG StartSector, ULONG SectorCount)
{ {
PCACHE_BLOCK CacheBlock; PCACHE_BLOCK CacheBlock;
ULONG StartBlock; ULONG StartBlock;
@ -290,7 +290,7 @@ BOOL CacheForceDiskSectorsIntoCache(ULONG DiskNumber, ULONG StartSector, ULONG S
return TRUE; return TRUE;
} }
BOOL CacheReleaseMemory(ULONG MinimumAmountToRelease) BOOLEAN CacheReleaseMemory(ULONG MinimumAmountToRelease)
{ {
ULONG AmountReleased; ULONG AmountReleased;

View file

@ -69,7 +69,7 @@ static BOOLEAN PortInitialized = FALSE;
/* STATIC FUNCTIONS *********************************************************/ /* STATIC FUNCTIONS *********************************************************/
static BOOL Rs232DoesComPortExist(PUCHAR BaseAddress) static BOOLEAN Rs232DoesComPortExist(PUCHAR BaseAddress)
{ {
BOOLEAN found; BOOLEAN found;
UCHAR mcr; UCHAR mcr;
@ -117,7 +117,7 @@ static BOOL Rs232DoesComPortExist(PUCHAR BaseAddress)
/* FUNCTIONS *********************************************************/ /* FUNCTIONS *********************************************************/
BOOL Rs232PortInitialize(ULONG ComPort, ULONG BaudRate) BOOLEAN Rs232PortInitialize(ULONG ComPort, ULONG BaudRate)
{ {
ULONG BaseArray[5] = {0, 0x3F8, 0x2F8, 0x3E8, 0x2E8}; ULONG BaseArray[5] = {0, 0x3F8, 0x2F8, 0x3E8, 0x2E8};
//char buffer[80]; //char buffer[80];
@ -237,7 +237,7 @@ BOOL Rs232PortInitialize(ULONG ComPort, ULONG BaudRate)
return TRUE; return TRUE;
} }
BOOL Rs232PortGetByte(PUCHAR ByteRecieved) BOOLEAN Rs232PortGetByte(PUCHAR ByteRecieved)
{ {
if (PortInitialized == FALSE) if (PortInitialized == FALSE)
return FALSE; return FALSE;
@ -251,7 +251,7 @@ BOOL Rs232PortGetByte(PUCHAR ByteRecieved)
return FALSE; return FALSE;
} }
BOOL Rs232PortPollByte(PUCHAR ByteRecieved) BOOLEAN Rs232PortPollByte(PUCHAR ByteRecieved)
{ {
if (PortInitialized == FALSE) if (PortInitialized == FALSE)
return FALSE; return FALSE;
@ -277,7 +277,7 @@ VOID Rs232PortPutByte(UCHAR ByteToSend)
#endif #endif
BOOL Rs232PortInUse(ULONG Base) BOOLEAN Rs232PortInUse(ULONG Base)
{ {
#ifdef DEBUG #ifdef DEBUG
return PortInitialized && Rs232PortBase == (PUCHAR)Base ? TRUE : FALSE; return PortInitialized && Rs232PortBase == (PUCHAR)Base ? TRUE : FALSE;

View file

@ -62,7 +62,7 @@ ULONG ComPort = COM1;
//ULONG BaudRate = 19200; //ULONG BaudRate = 19200;
ULONG BaudRate = 115200; ULONG BaudRate = 115200;
BOOL DebugStartOfLine = TRUE; BOOLEAN DebugStartOfLine = TRUE;
VOID DebugInit(VOID) VOID DebugInit(VOID)
{ {

View file

@ -25,13 +25,13 @@
#undef UNIMPLEMENTED #undef UNIMPLEMENTED
#define UNIMPLEMENTED BugCheck((DPRINT_WARNING, "Unimplemented\n")); #define UNIMPLEMENTED BugCheck((DPRINT_WARNING, "Unimplemented\n"));
static BOOL bReportError = TRUE; static BOOLEAN bReportError = TRUE;
///////////////////////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////////////////////
// FUNCTIONS // FUNCTIONS
///////////////////////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////////////////////
VOID DiskReportError (BOOL bError) VOID DiskReportError (BOOLEAN bError)
{ {
bReportError = bError; bReportError = bError;
} }
@ -86,9 +86,9 @@ PCSTR DiskGetErrorCodeString(ULONG ErrorCode)
} }
// This function is in arch/i386/i386disk.c // This function is in arch/i386/i386disk.c
//BOOL DiskReadLogicalSectors(ULONG DriveNumber, U64 SectorNumber, ULONG SectorCount, PVOID Buffer) //BOOLEAN DiskReadLogicalSectors(ULONG DriveNumber, U64 SectorNumber, ULONG SectorCount, PVOID Buffer)
BOOL DiskIsDriveRemovable(ULONG DriveNumber) BOOLEAN DiskIsDriveRemovable(ULONG DriveNumber)
{ {
// Hard disks use drive numbers >= 0x80 // Hard disks use drive numbers >= 0x80
// So if the drive number indicates a hard disk // So if the drive number indicates a hard disk

View file

@ -22,7 +22,7 @@
#define NDEBUG #define NDEBUG
#include <debug.h> #include <debug.h>
BOOL DiskGetActivePartitionEntry(ULONG DriveNumber, BOOLEAN DiskGetActivePartitionEntry(ULONG DriveNumber,
PPARTITION_TABLE_ENTRY PartitionTableEntry, PPARTITION_TABLE_ENTRY PartitionTableEntry,
ULONG *ActivePartition) ULONG *ActivePartition)
{ {
@ -78,7 +78,7 @@ BOOL DiskGetActivePartitionEntry(ULONG DriveNumber,
return TRUE; return TRUE;
} }
BOOL DiskGetPartitionEntry(ULONG DriveNumber, ULONG PartitionNumber, PPARTITION_TABLE_ENTRY PartitionTableEntry) BOOLEAN DiskGetPartitionEntry(ULONG DriveNumber, ULONG PartitionNumber, PPARTITION_TABLE_ENTRY PartitionTableEntry)
{ {
MASTER_BOOT_RECORD MasterBootRecord; MASTER_BOOT_RECORD MasterBootRecord;
PARTITION_TABLE_ENTRY ExtendedPartitionTableEntry; PARTITION_TABLE_ENTRY ExtendedPartitionTableEntry;
@ -156,7 +156,7 @@ BOOL DiskGetPartitionEntry(ULONG DriveNumber, ULONG PartitionNumber, PPARTITION_
} }
BOOL DiskGetFirstPartitionEntry(PMASTER_BOOT_RECORD MasterBootRecord, PPARTITION_TABLE_ENTRY PartitionTableEntry) BOOLEAN DiskGetFirstPartitionEntry(PMASTER_BOOT_RECORD MasterBootRecord, PPARTITION_TABLE_ENTRY PartitionTableEntry)
{ {
ULONG Index; ULONG Index;
@ -177,7 +177,7 @@ BOOL DiskGetFirstPartitionEntry(PMASTER_BOOT_RECORD MasterBootRecord, PPARTITION
return FALSE; return FALSE;
} }
BOOL DiskGetFirstExtendedPartitionEntry(PMASTER_BOOT_RECORD MasterBootRecord, PPARTITION_TABLE_ENTRY PartitionTableEntry) BOOLEAN DiskGetFirstExtendedPartitionEntry(PMASTER_BOOT_RECORD MasterBootRecord, PPARTITION_TABLE_ENTRY PartitionTableEntry)
{ {
ULONG Index; ULONG Index;
@ -196,7 +196,7 @@ BOOL DiskGetFirstExtendedPartitionEntry(PMASTER_BOOT_RECORD MasterBootRecord, PP
return FALSE; return FALSE;
} }
BOOL DiskReadBootRecord(ULONG DriveNumber, ULONGLONG LogicalSectorNumber, PMASTER_BOOT_RECORD BootRecord) BOOLEAN DiskReadBootRecord(ULONG DriveNumber, ULONGLONG LogicalSectorNumber, PMASTER_BOOT_RECORD BootRecord)
{ {
char ErrMsg[64]; char ErrMsg[64];
#ifdef DEBUG #ifdef DEBUG

View file

@ -22,7 +22,7 @@
#define NDEBUG #define NDEBUG
#include <debug.h> #include <debug.h>
BOOL DriveMapInstalled = FALSE; // Tells us if we have already installed our drive map int 13h handler code BOOLEAN DriveMapInstalled = FALSE; // Tells us if we have already installed our drive map int 13h handler code
ULONG OldInt13HandlerAddress = 0; // Address of BIOS int 13h handler ULONG OldInt13HandlerAddress = 0; // Address of BIOS int 13h handler
ULONG DriveMapHandlerAddress = 0; // Linear address of our drive map handler ULONG DriveMapHandlerAddress = 0; // Linear address of our drive map handler
ULONG DriveMapHandlerSegOff = 0; // Segment:offset style address of our drive map handler ULONG DriveMapHandlerSegOff = 0; // Segment:offset style address of our drive map handler
@ -114,7 +114,7 @@ VOID DriveMapMapDrivesInSection(PCSTR SectionName)
} }
} }
BOOL DriveMapIsValidDriveString(PCSTR DriveString) BOOLEAN DriveMapIsValidDriveString(PCSTR DriveString)
{ {
ULONG Index; ULONG Index;

View file

@ -37,7 +37,7 @@ ULONG Ext2GroupCount = 0; // Number of groups in this file system
ULONG Ext2InodesPerBlock = 0; // Number of inodes in one block ULONG Ext2InodesPerBlock = 0; // Number of inodes in one block
ULONG Ext2GroupDescPerBlock = 0; // Number of group descriptors in one block ULONG Ext2GroupDescPerBlock = 0; // Number of group descriptors in one block
BOOL Ext2OpenVolume(UCHAR DriveNumber, ULONGLONG VolumeStartSector) BOOLEAN Ext2OpenVolume(UCHAR DriveNumber, ULONGLONG VolumeStartSector)
{ {
DbgPrint((DPRINT_FILESYSTEM, "Ext2OpenVolume() DriveNumber = 0x%x VolumeStartSector = %d\n", DriveNumber, VolumeStartSector)); DbgPrint((DPRINT_FILESYSTEM, "Ext2OpenVolume() DriveNumber = 0x%x VolumeStartSector = %d\n", DriveNumber, VolumeStartSector));
@ -182,7 +182,7 @@ FILE* Ext2OpenFile(PCSTR FileName)
* with info describing the file, etc. returns true * with info describing the file, etc. returns true
* if the file exists or false otherwise * if the file exists or false otherwise
*/ */
BOOL Ext2LookupFile(PCSTR FileName, PEXT2_FILE_INFO Ext2FileInfoPointer) BOOLEAN Ext2LookupFile(PCSTR FileName, PEXT2_FILE_INFO Ext2FileInfoPointer)
{ {
UINT i; UINT i;
ULONG NumberOfPathParts; ULONG NumberOfPathParts;
@ -281,7 +281,7 @@ BOOL Ext2LookupFile(PCSTR FileName, PEXT2_FILE_INFO Ext2FileInfoPointer)
return TRUE; return TRUE;
} }
BOOL Ext2SearchDirectoryBufferForFile(PVOID DirectoryBuffer, ULONG DirectorySize, PCHAR FileName, PEXT2_DIR_ENTRY DirectoryEntry) BOOLEAN Ext2SearchDirectoryBufferForFile(PVOID DirectoryBuffer, ULONG DirectorySize, PCHAR FileName, PEXT2_DIR_ENTRY DirectoryEntry)
{ {
ULONG CurrentOffset; ULONG CurrentOffset;
PEXT2_DIR_ENTRY CurrentDirectoryEntry; PEXT2_DIR_ENTRY CurrentDirectoryEntry;
@ -337,7 +337,7 @@ BOOL Ext2SearchDirectoryBufferForFile(PVOID DirectoryBuffer, ULONG DirectorySize
* Reads BytesToRead from open file and * Reads BytesToRead from open file and
* returns the number of bytes read in BytesRead * returns the number of bytes read in BytesRead
*/ */
BOOL Ext2ReadFile(FILE *FileHandle, ULONGLONG BytesToRead, ULONGLONG* BytesRead, PVOID Buffer) BOOLEAN Ext2ReadFile(FILE *FileHandle, ULONGLONG BytesToRead, ULONGLONG* BytesRead, PVOID Buffer)
{ {
PEXT2_FILE_INFO Ext2FileInfo = (PEXT2_FILE_INFO)FileHandle; PEXT2_FILE_INFO Ext2FileInfo = (PEXT2_FILE_INFO)FileHandle;
ULONG BlockNumber; ULONG BlockNumber;
@ -548,10 +548,10 @@ ULONGLONG Ext2GetFilePointer(FILE *FileHandle)
return Ext2FileHandle->FilePointer; return Ext2FileHandle->FilePointer;
} }
BOOL Ext2ReadVolumeSectors(UCHAR DriveNumber, ULONGLONG SectorNumber, ULONGLONG SectorCount, PVOID Buffer) BOOLEAN Ext2ReadVolumeSectors(UCHAR DriveNumber, ULONGLONG SectorNumber, ULONGLONG SectorCount, PVOID Buffer)
{ {
//GEOMETRY DiskGeometry; //GEOMETRY DiskGeometry;
//BOOL ReturnValue; //BOOLEAN ReturnValue;
//if (!DiskGetDriveGeometry(DriveNumber, &DiskGeometry)) //if (!DiskGetDriveGeometry(DriveNumber, &DiskGeometry))
//{ //{
// return FALSE; // return FALSE;
@ -563,7 +563,7 @@ BOOL Ext2ReadVolumeSectors(UCHAR DriveNumber, ULONGLONG SectorNumber, ULONGLONG
return CacheReadDiskSectors(DriveNumber, SectorNumber + Ext2VolumeStartSector, SectorCount, Buffer); return CacheReadDiskSectors(DriveNumber, SectorNumber + Ext2VolumeStartSector, SectorCount, Buffer);
} }
BOOL Ext2ReadSuperBlock(VOID) BOOLEAN Ext2ReadSuperBlock(VOID)
{ {
DbgPrint((DPRINT_FILESYSTEM, "Ext2ReadSuperBlock()\n")); DbgPrint((DPRINT_FILESYSTEM, "Ext2ReadSuperBlock()\n"));
@ -724,7 +724,7 @@ BOOL Ext2ReadSuperBlock(VOID)
return TRUE; return TRUE;
} }
BOOL Ext2ReadGroupDescriptors(VOID) BOOLEAN Ext2ReadGroupDescriptors(VOID)
{ {
ULONG GroupDescBlockCount; ULONG GroupDescBlockCount;
ULONG CurrentGroupDescBlock; ULONG CurrentGroupDescBlock;
@ -770,7 +770,7 @@ BOOL Ext2ReadGroupDescriptors(VOID)
return TRUE; return TRUE;
} }
BOOL Ext2ReadDirectory(ULONG Inode, PVOID* DirectoryBuffer, PEXT2_INODE InodePointer) BOOLEAN Ext2ReadDirectory(ULONG Inode, PVOID* DirectoryBuffer, PEXT2_INODE InodePointer)
{ {
EXT2_FILE_INFO DirectoryFileInfo; EXT2_FILE_INFO DirectoryFileInfo;
@ -829,7 +829,7 @@ BOOL Ext2ReadDirectory(ULONG Inode, PVOID* DirectoryBuffer, PEXT2_INODE InodePoi
return TRUE; return TRUE;
} }
BOOL Ext2ReadBlock(ULONG BlockNumber, PVOID Buffer) BOOLEAN Ext2ReadBlock(ULONG BlockNumber, PVOID Buffer)
{ {
CHAR ErrorString[80]; CHAR ErrorString[80];
@ -860,7 +860,7 @@ BOOL Ext2ReadBlock(ULONG BlockNumber, PVOID Buffer)
* Ext2ReadPartialBlock() * Ext2ReadPartialBlock()
* Reads part of a block into memory * Reads part of a block into memory
*/ */
BOOL Ext2ReadPartialBlock(ULONG BlockNumber, ULONG StartingOffset, ULONG Length, PVOID Buffer) BOOLEAN Ext2ReadPartialBlock(ULONG BlockNumber, ULONG StartingOffset, ULONG Length, PVOID Buffer)
{ {
DbgPrint((DPRINT_FILESYSTEM, "Ext2ReadPartialBlock() BlockNumber = %d StartingOffset = %d Length = %d Buffer = 0x%x\n", BlockNumber, StartingOffset, Length, Buffer)); DbgPrint((DPRINT_FILESYSTEM, "Ext2ReadPartialBlock() BlockNumber = %d StartingOffset = %d Length = %d Buffer = 0x%x\n", BlockNumber, StartingOffset, Length, Buffer));
@ -900,7 +900,7 @@ ULONG Ext2GetInodeOffsetInBlock(ULONG Inode)
return (((Inode - 1) % Ext2SuperBlock->s_inodes_per_group) % Ext2InodesPerBlock); return (((Inode - 1) % Ext2SuperBlock->s_inodes_per_group) % Ext2InodesPerBlock);
} }
BOOL Ext2ReadInode(ULONG Inode, PEXT2_INODE InodeBuffer) BOOLEAN Ext2ReadInode(ULONG Inode, PEXT2_INODE InodeBuffer)
{ {
ULONG InodeGroupNumber; ULONG InodeGroupNumber;
ULONG InodeBlockNumber; ULONG InodeBlockNumber;
@ -970,7 +970,7 @@ BOOL Ext2ReadInode(ULONG Inode, PEXT2_INODE InodeBuffer)
return TRUE; return TRUE;
} }
BOOL Ext2ReadGroupDescriptor(ULONG Group, PEXT2_GROUP_DESC GroupBuffer) BOOLEAN Ext2ReadGroupDescriptor(ULONG Group, PEXT2_GROUP_DESC GroupBuffer)
{ {
DbgPrint((DPRINT_FILESYSTEM, "Ext2ReadGroupDescriptor()\n")); DbgPrint((DPRINT_FILESYSTEM, "Ext2ReadGroupDescriptor()\n"));
@ -1076,7 +1076,7 @@ ULONGLONG Ext2GetInodeFileSize(PEXT2_INODE Inode)
} }
} }
BOOL Ext2CopyIndirectBlockPointers(ULONG* BlockList, ULONG* CurrentBlockInList, ULONG BlockCount, ULONG IndirectBlock) BOOLEAN Ext2CopyIndirectBlockPointers(ULONG* BlockList, ULONG* CurrentBlockInList, ULONG BlockCount, ULONG IndirectBlock)
{ {
ULONG* BlockBuffer = (ULONG*)FILESYSBUFFER; ULONG* BlockBuffer = (ULONG*)FILESYSBUFFER;
ULONG CurrentBlock; ULONG CurrentBlock;
@ -1100,7 +1100,7 @@ BOOL Ext2CopyIndirectBlockPointers(ULONG* BlockList, ULONG* CurrentBlockInList,
return TRUE; return TRUE;
} }
BOOL Ext2CopyDoubleIndirectBlockPointers(ULONG* BlockList, ULONG* CurrentBlockInList, ULONG BlockCount, ULONG DoubleIndirectBlock) BOOLEAN Ext2CopyDoubleIndirectBlockPointers(ULONG* BlockList, ULONG* CurrentBlockInList, ULONG BlockCount, ULONG DoubleIndirectBlock)
{ {
ULONG* BlockBuffer; ULONG* BlockBuffer;
ULONG CurrentBlock; ULONG CurrentBlock;
@ -1135,7 +1135,7 @@ BOOL Ext2CopyDoubleIndirectBlockPointers(ULONG* BlockList, ULONG* CurrentBlockIn
return TRUE; return TRUE;
} }
BOOL Ext2CopyTripleIndirectBlockPointers(ULONG* BlockList, ULONG* CurrentBlockInList, ULONG BlockCount, ULONG TripleIndirectBlock) BOOLEAN Ext2CopyTripleIndirectBlockPointers(ULONG* BlockList, ULONG* CurrentBlockInList, ULONG BlockCount, ULONG TripleIndirectBlock)
{ {
ULONG* BlockBuffer; ULONG* BlockBuffer;
ULONG CurrentBlock; ULONG CurrentBlock;

View file

@ -37,7 +37,7 @@ ULONG DataSectorStart; /* Starting sector of the data area */
ULONG FatType = 0; /* FAT12, FAT16, FAT32, FATX16 or FATX32 */ ULONG FatType = 0; /* FAT12, FAT16, FAT32, FATX16 or FATX32 */
ULONG FatDriveNumber = 0; ULONG FatDriveNumber = 0;
BOOL FatOpenVolume(ULONG DriveNumber, ULONG VolumeStartSector, ULONG PartitionSectorCount) BOOLEAN FatOpenVolume(ULONG DriveNumber, ULONG VolumeStartSector, ULONG PartitionSectorCount)
{ {
char ErrMsg[80]; char ErrMsg[80];
ULONG FatSize; ULONG FatSize;
@ -336,7 +336,7 @@ ULONG FatDetermineFatType(PFAT_BOOTSECTOR FatBootSector, ULONG PartitionSectorCo
} }
} }
PVOID FatBufferDirectory(ULONG DirectoryStartCluster, ULONG *DirectorySize, BOOL RootDirectory) PVOID FatBufferDirectory(ULONG DirectoryStartCluster, ULONG *DirectorySize, BOOLEAN RootDirectory)
{ {
PVOID DirectoryBuffer; PVOID DirectoryBuffer;
@ -398,7 +398,7 @@ PVOID FatBufferDirectory(ULONG DirectoryStartCluster, ULONG *DirectorySize, BOOL
return DirectoryBuffer; return DirectoryBuffer;
} }
BOOL FatSearchDirectoryBufferForFile(PVOID DirectoryBuffer, ULONG DirectorySize, PCHAR FileName, PFAT_FILE_INFO FatFileInfoPointer) BOOLEAN FatSearchDirectoryBufferForFile(PVOID DirectoryBuffer, ULONG DirectorySize, PCHAR FileName, PFAT_FILE_INFO FatFileInfoPointer)
{ {
ULONG EntryCount; ULONG EntryCount;
ULONG CurrentEntry; ULONG CurrentEntry;
@ -609,7 +609,7 @@ BOOL FatSearchDirectoryBufferForFile(PVOID DirectoryBuffer, ULONG DirectorySize,
return FALSE; return FALSE;
} }
static BOOL FatXSearchDirectoryBufferForFile(PVOID DirectoryBuffer, ULONG DirectorySize, PCHAR FileName, PFAT_FILE_INFO FatFileInfoPointer) static BOOLEAN FatXSearchDirectoryBufferForFile(PVOID DirectoryBuffer, ULONG DirectorySize, PCHAR FileName, PFAT_FILE_INFO FatFileInfoPointer)
{ {
ULONG EntryCount; ULONG EntryCount;
ULONG CurrentEntry; ULONG CurrentEntry;
@ -680,7 +680,7 @@ static BOOL FatXSearchDirectoryBufferForFile(PVOID DirectoryBuffer, ULONG Direct
* with info describing the file, etc. returns true * with info describing the file, etc. returns true
* if the file exists or false otherwise * if the file exists or false otherwise
*/ */
BOOL FatLookupFile(PCSTR FileName, PFAT_FILE_INFO FatFileInfoPointer) BOOLEAN FatLookupFile(PCSTR FileName, PFAT_FILE_INFO FatFileInfoPointer)
{ {
UINT i; UINT i;
ULONG NumberOfPathParts; ULONG NumberOfPathParts;
@ -817,7 +817,7 @@ void FatParseShortFileName(PCHAR Buffer, PDIRENTRY DirEntry)
* FatGetFatEntry() * FatGetFatEntry()
* returns the Fat entry for a given cluster number * returns the Fat entry for a given cluster number
*/ */
BOOL FatGetFatEntry(ULONG Cluster, ULONG* ClusterPointer) BOOLEAN FatGetFatEntry(ULONG Cluster, ULONG* ClusterPointer)
{ {
ULONG fat = 0; ULONG fat = 0;
UINT FatOffset; UINT FatOffset;
@ -1029,7 +1029,7 @@ ULONG* FatGetClusterChainArray(ULONG StartCluster)
* FatReadCluster() * FatReadCluster()
* Reads the specified cluster into memory * Reads the specified cluster into memory
*/ */
BOOL FatReadCluster(ULONG ClusterNumber, PVOID Buffer) BOOLEAN FatReadCluster(ULONG ClusterNumber, PVOID Buffer)
{ {
ULONG ClusterStartSector; ULONG ClusterStartSector;
@ -1051,7 +1051,7 @@ BOOL FatReadCluster(ULONG ClusterNumber, PVOID Buffer)
* FatReadClusterChain() * FatReadClusterChain()
* Reads the specified clusters into memory * Reads the specified clusters into memory
*/ */
BOOL FatReadClusterChain(ULONG StartClusterNumber, ULONG NumberOfClusters, PVOID Buffer) BOOLEAN FatReadClusterChain(ULONG StartClusterNumber, ULONG NumberOfClusters, PVOID Buffer)
{ {
ULONG ClusterStartSector; ULONG ClusterStartSector;
@ -1112,7 +1112,7 @@ BOOL FatReadClusterChain(ULONG StartClusterNumber, ULONG NumberOfClusters, PVOID
* FatReadPartialCluster() * FatReadPartialCluster()
* Reads part of a cluster into memory * Reads part of a cluster into memory
*/ */
BOOL FatReadPartialCluster(ULONG ClusterNumber, ULONG StartingOffset, ULONG Length, PVOID Buffer) BOOLEAN FatReadPartialCluster(ULONG ClusterNumber, ULONG StartingOffset, ULONG Length, PVOID Buffer)
{ {
ULONG ClusterStartSector; ULONG ClusterStartSector;
@ -1135,7 +1135,7 @@ BOOL FatReadPartialCluster(ULONG ClusterNumber, ULONG StartingOffset, ULONG Leng
* Reads BytesToRead from open file and * Reads BytesToRead from open file and
* returns the number of bytes read in BytesRead * returns the number of bytes read in BytesRead
*/ */
BOOL FatReadFile(FILE *FileHandle, ULONG BytesToRead, ULONG* BytesRead, PVOID Buffer) BOOLEAN FatReadFile(FILE *FileHandle, ULONG BytesToRead, ULONG* BytesRead, PVOID Buffer)
{ {
PFAT_FILE_INFO FatFileInfo = (PFAT_FILE_INFO)FileHandle; PFAT_FILE_INFO FatFileInfo = (PFAT_FILE_INFO)FileHandle;
ULONG ClusterNumber; ULONG ClusterNumber;
@ -1316,7 +1316,7 @@ ULONG FatGetFilePointer(FILE *FileHandle)
return FatFileHandle->FilePointer; return FatFileHandle->FilePointer;
} }
BOOL FatReadVolumeSectors(ULONG DriveNumber, ULONG SectorNumber, ULONG SectorCount, PVOID Buffer) BOOLEAN FatReadVolumeSectors(ULONG DriveNumber, ULONG SectorNumber, ULONG SectorCount, PVOID Buffer)
{ {
return CacheReadDiskSectors(DriveNumber, SectorNumber + FatVolumeStartSector, SectorCount, Buffer); return CacheReadDiskSectors(DriveNumber, SectorNumber + FatVolumeStartSector, SectorCount, Buffer);
} }

View file

@ -41,13 +41,13 @@ VOID FileSystemError(PCSTR ErrorString)
/* /*
* *
* BOOL FsOpenVolume(ULONG DriveNumber, ULONGLONG StartSector, ULONGLONG SectorCount, int Type); * BOOLEAN FsOpenVolume(ULONG DriveNumber, ULONGLONG StartSector, ULONGLONG SectorCount, int Type);
* *
* This function is called to open a disk volume for file access. * This function is called to open a disk volume for file access.
* It must be called before any of the file functions will work. * It must be called before any of the file functions will work.
* *
*/ */
static BOOL FsOpenVolume(ULONG DriveNumber, ULONGLONG StartSector, ULONGLONG SectorCount, int Type) static BOOLEAN FsOpenVolume(ULONG DriveNumber, ULONGLONG StartSector, ULONGLONG SectorCount, int Type)
{ {
CHAR ErrorText[80]; CHAR ErrorText[80];
@ -73,12 +73,12 @@ static BOOL FsOpenVolume(ULONG DriveNumber, ULONGLONG StartSector, ULONGLONG Sec
} }
/* /*
* *
* BOOL FsOpenBootVolume() * BOOLEAN FsOpenBootVolume()
* *
* This function is called to open the boot disk volume for file access. * This function is called to open the boot disk volume for file access.
* It must be called before any of the file functions will work. * It must be called before any of the file functions will work.
*/ */
BOOL FsOpenBootVolume() BOOLEAN FsOpenBootVolume()
{ {
ULONG DriveNumber; ULONG DriveNumber;
ULONGLONG StartSector; ULONGLONG StartSector;
@ -94,7 +94,7 @@ BOOL FsOpenBootVolume()
return FsOpenVolume(DriveNumber, StartSector, SectorCount, Type); return FsOpenVolume(DriveNumber, StartSector, SectorCount, Type);
} }
BOOL FsOpenSystemVolume(char *SystemPath, char *RemainingPath, PULONG Device) BOOLEAN FsOpenSystemVolume(char *SystemPath, char *RemainingPath, PULONG Device)
{ {
ULONG DriveNumber; ULONG DriveNumber;
ULONGLONG StartSector; ULONGLONG StartSector;
@ -177,10 +177,10 @@ VOID FsCloseFile(PFILE FileHandle)
* ReadFile() * ReadFile()
* returns number of bytes read or EOF * returns number of bytes read or EOF
*/ */
BOOL FsReadFile(PFILE FileHandle, ULONG BytesToRead, ULONG* BytesRead, PVOID Buffer) BOOLEAN FsReadFile(PFILE FileHandle, ULONG BytesToRead, ULONG* BytesRead, PVOID Buffer)
{ {
ULONGLONG BytesReadBig; ULONGLONG BytesReadBig;
BOOL Success; BOOLEAN Success;
// //
// Set the number of bytes read equal to zero // Set the number of bytes read equal to zero
@ -310,7 +310,7 @@ ULONG FsGetFilePointer(PFILE FileHandle)
return 0; return 0;
} }
BOOL FsIsEndOfFile(PFILE FileHandle) BOOLEAN FsIsEndOfFile(PFILE FileHandle)
{ {
if (FsGetFilePointer(FileHandle) >= FsGetFileSize(FileHandle)) if (FsGetFilePointer(FileHandle) >= FsGetFileSize(FileHandle))
{ {

View file

@ -28,10 +28,10 @@
/* /*
* *
* BOOL FsRecognizeVolume(ULONG DriveNumber, ULONG VolumeStartSector, UCHAR* VolumeType); * BOOLEAN FsRecognizeVolume(ULONG DriveNumber, ULONG VolumeStartSector, UCHAR* VolumeType);
* *
*/ */
BOOL FsRecognizeVolume(ULONG DriveNumber, ULONG VolumeStartSector, UCHAR* VolumeType) BOOLEAN FsRecognizeVolume(ULONG DriveNumber, ULONG VolumeStartSector, UCHAR* VolumeType)
{ {
DbgPrint((DPRINT_FILESYSTEM, "FsRecognizeVolume() DriveNumber: 0x%x VolumeStartSector: %d\n", DriveNumber, VolumeStartSector)); DbgPrint((DPRINT_FILESYSTEM, "FsRecognizeVolume() DriveNumber: 0x%x VolumeStartSector: %d\n", DriveNumber, VolumeStartSector));
@ -55,7 +55,7 @@ BOOL FsRecognizeVolume(ULONG DriveNumber, ULONG VolumeStartSector, UCHAR* Volume
return FALSE; return FALSE;
} }
BOOL FsRecIsIso9660(ULONG DriveNumber) BOOLEAN FsRecIsIso9660(ULONG DriveNumber)
{ {
PUCHAR Sector = (PUCHAR)DISKREADBUFFER; PUCHAR Sector = (PUCHAR)DISKREADBUFFER;
@ -73,7 +73,7 @@ BOOL FsRecIsIso9660(ULONG DriveNumber)
Sector[5] == '1'); Sector[5] == '1');
} }
BOOL FsRecIsExt2(ULONG DriveNumber, ULONG VolumeStartSector) BOOLEAN FsRecIsExt2(ULONG DriveNumber, ULONG VolumeStartSector)
{ {
PEXT2_SUPER_BLOCK SuperBlock = (PEXT2_SUPER_BLOCK)DISKREADBUFFER; PEXT2_SUPER_BLOCK SuperBlock = (PEXT2_SUPER_BLOCK)DISKREADBUFFER;
@ -91,7 +91,7 @@ BOOL FsRecIsExt2(ULONG DriveNumber, ULONG VolumeStartSector)
return FALSE; return FALSE;
} }
BOOL FsRecIsFat(ULONG DriveNumber, ULONG VolumeStartSector) BOOLEAN FsRecIsFat(ULONG DriveNumber, ULONG VolumeStartSector)
{ {
PFAT_BOOTSECTOR BootSector = (PFAT_BOOTSECTOR)DISKREADBUFFER; PFAT_BOOTSECTOR BootSector = (PFAT_BOOTSECTOR)DISKREADBUFFER;
PFAT32_BOOTSECTOR BootSector32 = (PFAT32_BOOTSECTOR)DISKREADBUFFER; PFAT32_BOOTSECTOR BootSector32 = (PFAT32_BOOTSECTOR)DISKREADBUFFER;
@ -113,7 +113,7 @@ BOOL FsRecIsFat(ULONG DriveNumber, ULONG VolumeStartSector)
return FALSE; return FALSE;
} }
BOOL FsRecIsNtfs(ULONG DriveNumber, ULONG VolumeStartSector) BOOLEAN FsRecIsNtfs(ULONG DriveNumber, ULONG VolumeStartSector)
{ {
PNTFS_BOOTSECTOR BootSector = (PNTFS_BOOTSECTOR)DISKREADBUFFER; PNTFS_BOOTSECTOR BootSector = (PNTFS_BOOTSECTOR)DISKREADBUFFER;
if (!MachDiskReadLogicalSectors(DriveNumber, VolumeStartSector, 1, BootSector)) if (!MachDiskReadLogicalSectors(DriveNumber, VolumeStartSector, 1, BootSector))

View file

@ -30,7 +30,7 @@ static ULONG IsoRootLength; // Length of the root directory
ULONG IsoDriveNumber = 0; ULONG IsoDriveNumber = 0;
BOOL IsoOpenVolume(ULONG DriveNumber) BOOLEAN IsoOpenVolume(ULONG DriveNumber)
{ {
PPVD Pvd = (PPVD)DISKREADBUFFER; PPVD Pvd = (PPVD)DISKREADBUFFER;
@ -57,7 +57,7 @@ BOOL IsoOpenVolume(ULONG DriveNumber)
} }
static BOOL IsoSearchDirectoryBufferForFile(PVOID DirectoryBuffer, ULONG DirectoryLength, PCHAR FileName, PISO_FILE_INFO IsoFileInfoPointer) static BOOLEAN IsoSearchDirectoryBufferForFile(PVOID DirectoryBuffer, ULONG DirectoryLength, PCHAR FileName, PISO_FILE_INFO IsoFileInfoPointer)
{ {
PDIR_RECORD Record; PDIR_RECORD Record;
ULONG Offset; ULONG Offset;
@ -172,7 +172,7 @@ static PVOID IsoBufferDirectory(ULONG DirectoryStartSector, ULONG DirectoryLengt
* with info describing the file, etc. returns true * with info describing the file, etc. returns true
* if the file exists or false otherwise * if the file exists or false otherwise
*/ */
static BOOL IsoLookupFile(PCSTR FileName, PISO_FILE_INFO IsoFileInfoPointer) static BOOLEAN IsoLookupFile(PCSTR FileName, PISO_FILE_INFO IsoFileInfoPointer)
{ {
UINT i; UINT i;
ULONG NumberOfPathParts; ULONG NumberOfPathParts;
@ -285,7 +285,7 @@ FILE* IsoOpenFile(PCSTR FileName)
* Reads BytesToRead from open file and * Reads BytesToRead from open file and
* returns the number of bytes read in BytesRead * returns the number of bytes read in BytesRead
*/ */
BOOL IsoReadFile(FILE *FileHandle, ULONG BytesToRead, ULONG* BytesRead, PVOID Buffer) BOOLEAN IsoReadFile(FILE *FileHandle, ULONG BytesToRead, ULONG* BytesRead, PVOID Buffer)
{ {
PISO_FILE_INFO IsoFileInfo = (PISO_FILE_INFO)FileHandle; PISO_FILE_INFO IsoFileInfo = (PISO_FILE_INFO)FileHandle;
ULONG SectorNumber; ULONG SectorNumber;

View file

@ -80,7 +80,7 @@ static PUCHAR NtfsDecodeRun(PUCHAR DataRun, LONGLONG *DataRunOffset, ULONGLONG *
} }
/* FIXME: Add support for attribute lists! */ /* FIXME: Add support for attribute lists! */
static BOOL NtfsFindAttribute(PNTFS_ATTR_CONTEXT Context, PNTFS_MFT_RECORD MftRecord, ULONG Type, const WCHAR *Name) static BOOLEAN NtfsFindAttribute(PNTFS_ATTR_CONTEXT Context, PNTFS_MFT_RECORD MftRecord, ULONG Type, const WCHAR *Name)
{ {
PNTFS_ATTR_RECORD AttrRecord; PNTFS_ATTR_RECORD AttrRecord;
PNTFS_ATTR_RECORD AttrRecordEnd; PNTFS_ATTR_RECORD AttrRecordEnd;
@ -141,7 +141,7 @@ static BOOL NtfsFindAttribute(PNTFS_ATTR_CONTEXT Context, PNTFS_MFT_RECORD MftRe
} }
/* FIXME: Optimize for multisector reads. */ /* FIXME: Optimize for multisector reads. */
static BOOL NtfsDiskRead(ULONGLONG Offset, ULONGLONG Length, PCHAR Buffer) static BOOLEAN NtfsDiskRead(ULONGLONG Offset, ULONGLONG Length, PCHAR Buffer)
{ {
USHORT ReadLength; USHORT ReadLength;
@ -307,7 +307,7 @@ static ULONGLONG NtfsReadAttribute(PNTFS_ATTR_CONTEXT Context, ULONGLONG Offset,
return AlreadyRead; return AlreadyRead;
} }
static BOOL NtfsFixupRecord(PNTFS_RECORD Record) static BOOLEAN NtfsFixupRecord(PNTFS_RECORD Record)
{ {
USHORT *USA; USHORT *USA;
USHORT USANumber; USHORT USANumber;
@ -331,7 +331,7 @@ static BOOL NtfsFixupRecord(PNTFS_RECORD Record)
return TRUE; return TRUE;
} }
static BOOL NtfsReadMftRecord(ULONG MFTIndex, PNTFS_MFT_RECORD Buffer) static BOOLEAN NtfsReadMftRecord(ULONG MFTIndex, PNTFS_MFT_RECORD Buffer)
{ {
ULONGLONG BytesRead; ULONGLONG BytesRead;
@ -362,7 +362,7 @@ VOID NtfsPrintFile(PNTFS_INDEX_ENTRY IndexEntry)
} }
#endif #endif
static BOOL NtfsCompareFileName(PCHAR FileName, PNTFS_INDEX_ENTRY IndexEntry) static BOOLEAN NtfsCompareFileName(PCHAR FileName, PNTFS_INDEX_ENTRY IndexEntry)
{ {
PWCHAR EntryFileName; PWCHAR EntryFileName;
UCHAR EntryFileNameLength; UCHAR EntryFileNameLength;
@ -395,7 +395,7 @@ static BOOL NtfsCompareFileName(PCHAR FileName, PNTFS_INDEX_ENTRY IndexEntry)
return TRUE; return TRUE;
} }
static BOOL NtfsFindMftRecord(ULONG MFTIndex, PCHAR FileName, ULONG *OutMFTIndex) static BOOLEAN NtfsFindMftRecord(ULONG MFTIndex, PCHAR FileName, ULONG *OutMFTIndex)
{ {
PNTFS_MFT_RECORD MftRecord; PNTFS_MFT_RECORD MftRecord;
ULONG Magic; ULONG Magic;
@ -556,7 +556,7 @@ static BOOL NtfsFindMftRecord(ULONG MFTIndex, PCHAR FileName, ULONG *OutMFTIndex
return FALSE; return FALSE;
} }
static BOOL NtfsLookupFile(PCSTR FileName, PNTFS_MFT_RECORD MftRecord, PNTFS_ATTR_CONTEXT DataContext) static BOOLEAN NtfsLookupFile(PCSTR FileName, PNTFS_MFT_RECORD MftRecord, PNTFS_ATTR_CONTEXT DataContext)
{ {
ULONG NumberOfPathParts; ULONG NumberOfPathParts;
CHAR PathPart[261]; CHAR PathPart[261];
@ -599,7 +599,7 @@ static BOOL NtfsLookupFile(PCSTR FileName, PNTFS_MFT_RECORD MftRecord, PNTFS_ATT
return TRUE; return TRUE;
} }
BOOL NtfsOpenVolume(ULONG DriveNumber, ULONG VolumeStartSector) BOOLEAN NtfsOpenVolume(ULONG DriveNumber, ULONG VolumeStartSector)
{ {
NtfsBootSector = (PNTFS_BOOTSECTOR)DISKREADBUFFER; NtfsBootSector = (PNTFS_BOOTSECTOR)DISKREADBUFFER;
@ -696,7 +696,7 @@ FILE* NtfsOpenFile(PCSTR FileName)
return (FILE*)FileHandle; return (FILE*)FileHandle;
} }
BOOL NtfsReadFile(FILE *File, ULONG BytesToRead, ULONG* BytesRead, PVOID Buffer) BOOLEAN NtfsReadFile(FILE *File, ULONG BytesToRead, ULONG* BytesRead, PVOID Buffer)
{ {
PNTFS_FILE_HANDLE FileHandle = (PNTFS_FILE_HANDLE)File; PNTFS_FILE_HANDLE FileHandle = (PNTFS_FILE_HANDLE)File;
ULONGLONG BytesRead64; ULONGLONG BytesRead64;

View file

@ -25,16 +25,16 @@
extern ULONG i386BootDrive; extern ULONG i386BootDrive;
extern ULONG i386BootPartition; extern ULONG i386BootPartition;
extern BOOL i386DiskGetBootVolume(PULONG DriveNumber, PULONGLONG StartSector, extern BOOLEAN i386DiskGetBootVolume(PULONG DriveNumber, PULONGLONG StartSector,
PULONGLONG SectorCount, int *FsType); PULONGLONG SectorCount, int *FsType);
extern BOOL i386DiskGetSystemVolume(char *SystemPath, char *RemainingPath, extern BOOLEAN i386DiskGetSystemVolume(char *SystemPath, char *RemainingPath,
PULONG Device, PULONG DriveNumber, PULONG Device, PULONG DriveNumber,
PULONGLONG StartSector, PULONGLONG StartSector,
PULONGLONG SectorCount, int *FsType); PULONGLONG SectorCount, int *FsType);
extern BOOL i386DiskGetBootPath(char *BootPath, unsigned Size); extern BOOLEAN i386DiskGetBootPath(char *BootPath, unsigned Size);
extern VOID i386DiskGetBootDevice(PULONG BootDevice); extern VOID i386DiskGetBootDevice(PULONG BootDevice);
extern BOOL i386DiskBootingFromFloppy(VOID); extern BOOLEAN i386DiskBootingFromFloppy(VOID);
extern BOOL i386DiskNormalizeSystemPath(char *SystemPath, unsigned Size); extern BOOLEAN i386DiskNormalizeSystemPath(char *SystemPath, unsigned Size);
#endif /* __I386_I386_H_ */ #endif /* __I386_I386_H_ */

View file

@ -29,18 +29,18 @@
VOID PcMachInit(const char *CmdLine); VOID PcMachInit(const char *CmdLine);
VOID PcConsPutChar(int Ch); VOID PcConsPutChar(int Ch);
BOOL PcConsKbHit(); BOOLEAN PcConsKbHit();
int PcConsGetCh(); int PcConsGetCh();
VOID PcVideoClearScreen(UCHAR Attr); VOID PcVideoClearScreen(UCHAR Attr);
VIDEODISPLAYMODE PcVideoSetDisplayMode(char *DisplayMode, BOOL Init); VIDEODISPLAYMODE PcVideoSetDisplayMode(char *DisplayMode, BOOLEAN Init);
VOID PcVideoGetDisplaySize(PULONG Width, PULONG Height, PULONG Depth); VOID PcVideoGetDisplaySize(PULONG Width, PULONG Height, PULONG Depth);
ULONG PcVideoGetBufferSize(VOID); ULONG PcVideoGetBufferSize(VOID);
VOID PcVideoSetTextCursorPosition(ULONG X, ULONG Y); VOID PcVideoSetTextCursorPosition(ULONG X, ULONG Y);
VOID PcVideoHideShowTextCursor(BOOL Show); VOID PcVideoHideShowTextCursor(BOOLEAN Show);
VOID PcVideoPutChar(int Ch, UCHAR Attr, unsigned X, unsigned Y); VOID PcVideoPutChar(int Ch, UCHAR Attr, unsigned X, unsigned Y);
VOID PcVideoCopyOffScreenBufferToVRAM(PVOID Buffer); VOID PcVideoCopyOffScreenBufferToVRAM(PVOID Buffer);
BOOL PcVideoIsPaletteFixed(VOID); BOOLEAN PcVideoIsPaletteFixed(VOID);
VOID PcVideoSetPaletteColor(UCHAR Color, UCHAR Red, UCHAR Green, UCHAR Blue); VOID PcVideoSetPaletteColor(UCHAR Color, UCHAR Red, UCHAR Green, UCHAR Blue);
VOID PcVideoGetPaletteColor(UCHAR Color, UCHAR* Red, UCHAR* Green, UCHAR* Blue); VOID PcVideoGetPaletteColor(UCHAR Color, UCHAR* Red, UCHAR* Green, UCHAR* Blue);
VOID PcVideoSync(VOID); VOID PcVideoSync(VOID);
@ -48,9 +48,9 @@ VOID PcVideoPrepareForReactOS(VOID);
ULONG PcMemGetMemoryMap(PBIOS_MEMORY_MAP BiosMemoryMap, ULONG MaxMemoryMapSize); ULONG PcMemGetMemoryMap(PBIOS_MEMORY_MAP BiosMemoryMap, ULONG MaxMemoryMapSize);
BOOL PcDiskReadLogicalSectors(ULONG DriveNumber, ULONGLONG SectorNumber, ULONG SectorCount, PVOID Buffer); BOOLEAN PcDiskReadLogicalSectors(ULONG DriveNumber, ULONGLONG SectorNumber, ULONG SectorCount, PVOID Buffer);
BOOL PcDiskGetPartitionEntry(ULONG DriveNumber, ULONG PartitionNumber, PPARTITION_TABLE_ENTRY PartitionTableEntry); BOOLEAN PcDiskGetPartitionEntry(ULONG DriveNumber, ULONG PartitionNumber, PPARTITION_TABLE_ENTRY PartitionTableEntry);
BOOL PcDiskGetDriveGeometry(ULONG DriveNumber, PGEOMETRY DriveGeometry); BOOLEAN PcDiskGetDriveGeometry(ULONG DriveNumber, PGEOMETRY DriveGeometry);
ULONG PcDiskGetCacheableBlockCount(ULONG DriveNumber); ULONG PcDiskGetCacheableBlockCount(ULONG DriveNumber);
VOID PcRTCGetCurrentDateTime(PULONG Year, PULONG Month, PULONG Day, PULONG Hour, PULONG Minute, PULONG Second); VOID PcRTCGetCurrentDateTime(PULONG Year, PULONG Month, PULONG Day, PULONG Hour, PULONG Minute, PULONG Second);

View file

@ -29,19 +29,19 @@ UCHAR XboxFont8x16[256 * 16];
VOID XboxMachInit(const char *CmdLine); VOID XboxMachInit(const char *CmdLine);
VOID XboxConsPutChar(int Ch); VOID XboxConsPutChar(int Ch);
BOOL XboxConsKbHit(); BOOLEAN XboxConsKbHit();
int XboxConsGetCh(); int XboxConsGetCh();
VOID XboxVideoInit(VOID); VOID XboxVideoInit(VOID);
VOID XboxVideoClearScreen(UCHAR Attr); VOID XboxVideoClearScreen(UCHAR Attr);
VIDEODISPLAYMODE XboxVideoSetDisplayMode(char *DisplayModem, BOOL Init); VIDEODISPLAYMODE XboxVideoSetDisplayMode(char *DisplayModem, BOOLEAN Init);
VOID XboxVideoGetDisplaySize(PULONG Width, PULONG Height, PULONG Depth); VOID XboxVideoGetDisplaySize(PULONG Width, PULONG Height, PULONG Depth);
ULONG XboxVideoGetBufferSize(VOID); ULONG XboxVideoGetBufferSize(VOID);
VOID XboxVideoSetTextCursorPosition(ULONG X, ULONG Y); VOID XboxVideoSetTextCursorPosition(ULONG X, ULONG Y);
VOID XboxVideoHideShowTextCursor(BOOL Show); VOID XboxVideoHideShowTextCursor(BOOLEAN Show);
VOID XboxVideoPutChar(int Ch, UCHAR Attr, unsigned X, unsigned Y); VOID XboxVideoPutChar(int Ch, UCHAR Attr, unsigned X, unsigned Y);
VOID XboxVideoCopyOffScreenBufferToVRAM(PVOID Buffer); VOID XboxVideoCopyOffScreenBufferToVRAM(PVOID Buffer);
BOOL XboxVideoIsPaletteFixed(VOID); BOOLEAN XboxVideoIsPaletteFixed(VOID);
VOID XboxVideoSetPaletteColor(UCHAR Color, UCHAR Red, UCHAR Green, UCHAR Blue); VOID XboxVideoSetPaletteColor(UCHAR Color, UCHAR Red, UCHAR Green, UCHAR Blue);
VOID XboxVideoGetPaletteColor(UCHAR Color, UCHAR* Red, UCHAR* Green, UCHAR* Blue); VOID XboxVideoGetPaletteColor(UCHAR Color, UCHAR* Red, UCHAR* Green, UCHAR* Blue);
VOID XboxVideoSync(VOID); VOID XboxVideoSync(VOID);
@ -51,9 +51,9 @@ VOID XboxMemInit(VOID);
PVOID XboxMemReserveMemory(ULONG MbToReserve); PVOID XboxMemReserveMemory(ULONG MbToReserve);
ULONG XboxMemGetMemoryMap(PBIOS_MEMORY_MAP BiosMemoryMap, ULONG MaxMemoryMapSize); ULONG XboxMemGetMemoryMap(PBIOS_MEMORY_MAP BiosMemoryMap, ULONG MaxMemoryMapSize);
BOOL XboxDiskReadLogicalSectors(ULONG DriveNumber, ULONGLONG SectorNumber, ULONG SectorCount, PVOID Buffer); BOOLEAN XboxDiskReadLogicalSectors(ULONG DriveNumber, ULONGLONG SectorNumber, ULONG SectorCount, PVOID Buffer);
BOOL XboxDiskGetPartitionEntry(ULONG DriveNumber, ULONG PartitionNumber, PPARTITION_TABLE_ENTRY PartitionTableEntry); BOOLEAN XboxDiskGetPartitionEntry(ULONG DriveNumber, ULONG PartitionNumber, PPARTITION_TABLE_ENTRY PartitionTableEntry);
BOOL XboxDiskGetDriveGeometry(ULONG DriveNumber, PGEOMETRY DriveGeometry); BOOLEAN XboxDiskGetDriveGeometry(ULONG DriveNumber, PGEOMETRY DriveGeometry);
ULONG XboxDiskGetCacheableBlockCount(ULONG DriveNumber); ULONG XboxDiskGetCacheableBlockCount(ULONG DriveNumber);
VOID XboxRTCGetCurrentDateTime(PULONG Year, PULONG Month, PULONG Day, PULONG Hour, PULONG Minute, PULONG Second); VOID XboxRTCGetCurrentDateTime(PULONG Year, PULONG Month, PULONG Day, PULONG Hour, PULONG Minute, PULONG Second);

View file

@ -23,7 +23,7 @@
ULONG GetDefaultOperatingSystem(PCSTR OperatingSystemList[], ULONG OperatingSystemCount); ULONG GetDefaultOperatingSystem(PCSTR OperatingSystemList[], ULONG OperatingSystemCount);
LONG GetTimeOut(VOID); LONG GetTimeOut(VOID);
BOOL MainBootMenuKeyPressFilter(ULONG KeyPress); BOOLEAN MainBootMenuKeyPressFilter(ULONG KeyPress);
#endif // #defined __BOOTMGR_H #endif // #defined __BOOTMGR_H

View file

@ -35,7 +35,7 @@ typedef struct
LIST_ITEM ListEntry; // Doubly linked list synchronization member LIST_ITEM ListEntry; // Doubly linked list synchronization member
ULONG BlockNumber; // Track index for CHS, 64k block index for LBA ULONG BlockNumber; // Track index for CHS, 64k block index for LBA
BOOL LockedInCache; // Indicates that this block is locked in cache memory BOOLEAN LockedInCache; // Indicates that this block is locked in cache memory
ULONG AccessCount; // Access count for this block ULONG AccessCount; // Access count for this block
PVOID BlockData; // Pointer to block data PVOID BlockData; // Pointer to block data
@ -66,7 +66,7 @@ typedef struct
// //
/////////////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////////////
extern CACHE_DRIVE CacheManagerDrive; extern CACHE_DRIVE CacheManagerDrive;
extern BOOL CacheManagerInitialized; extern BOOLEAN CacheManagerInitialized;
extern ULONG CacheBlockCount; extern ULONG CacheBlockCount;
extern ULONG CacheSizeLimit; extern ULONG CacheSizeLimit;
extern ULONG CacheSizeCurrent; extern ULONG CacheSizeCurrent;
@ -79,16 +79,16 @@ extern ULONG CacheSizeCurrent;
PCACHE_BLOCK CacheInternalGetBlockPointer(PCACHE_DRIVE CacheDrive, ULONG BlockNumber); // Returns a pointer to a CACHE_BLOCK structure given a block number PCACHE_BLOCK CacheInternalGetBlockPointer(PCACHE_DRIVE CacheDrive, ULONG BlockNumber); // Returns a pointer to a CACHE_BLOCK structure given a block number
PCACHE_BLOCK CacheInternalFindBlock(PCACHE_DRIVE CacheDrive, ULONG BlockNumber); // Searches the block list for a particular block PCACHE_BLOCK CacheInternalFindBlock(PCACHE_DRIVE CacheDrive, ULONG BlockNumber); // Searches the block list for a particular block
PCACHE_BLOCK CacheInternalAddBlockToCache(PCACHE_DRIVE CacheDrive, ULONG BlockNumber); // Adds a block to the cache's block list PCACHE_BLOCK CacheInternalAddBlockToCache(PCACHE_DRIVE CacheDrive, ULONG BlockNumber); // Adds a block to the cache's block list
BOOL CacheInternalFreeBlock(PCACHE_DRIVE CacheDrive); // Removes a block from the cache's block list & frees the memory BOOLEAN CacheInternalFreeBlock(PCACHE_DRIVE CacheDrive); // Removes a block from the cache's block list & frees the memory
VOID CacheInternalCheckCacheSizeLimits(PCACHE_DRIVE CacheDrive); // Checks the cache size limits to see if we can add a new block, if not calls CacheInternalFreeBlock() VOID CacheInternalCheckCacheSizeLimits(PCACHE_DRIVE CacheDrive); // Checks the cache size limits to see if we can add a new block, if not calls CacheInternalFreeBlock()
VOID CacheInternalDumpBlockList(PCACHE_DRIVE CacheDrive); // Dumps the list of cached blocks to the debug output port VOID CacheInternalDumpBlockList(PCACHE_DRIVE CacheDrive); // Dumps the list of cached blocks to the debug output port
VOID CacheInternalOptimizeBlockList(PCACHE_DRIVE CacheDrive, PCACHE_BLOCK CacheBlock); // Moves the specified block to the head of the list VOID CacheInternalOptimizeBlockList(PCACHE_DRIVE CacheDrive, PCACHE_BLOCK CacheBlock); // Moves the specified block to the head of the list
BOOL CacheInitializeDrive(ULONG DriveNumber); BOOLEAN CacheInitializeDrive(ULONG DriveNumber);
VOID CacheInvalidateCacheData(VOID); VOID CacheInvalidateCacheData(VOID);
BOOL CacheReadDiskSectors(ULONG DiskNumber, ULONG StartSector, ULONG SectorCount, PVOID Buffer); BOOLEAN CacheReadDiskSectors(ULONG DiskNumber, ULONG StartSector, ULONG SectorCount, PVOID Buffer);
BOOL CacheForceDiskSectorsIntoCache(ULONG DiskNumber, ULONG StartSector, ULONG SectorCount); BOOLEAN CacheForceDiskSectorsIntoCache(ULONG DiskNumber, ULONG StartSector, ULONG SectorCount);
BOOL CacheReleaseMemory(ULONG MinimumAmountToRelease); BOOLEAN CacheReleaseMemory(ULONG MinimumAmountToRelease);
#endif // defined __CACHE_H #endif // defined __CACHE_H

View file

@ -22,11 +22,11 @@
#ifndef __RS232_H #ifndef __RS232_H
#define __RS232_H #define __RS232_H
BOOL Rs232PortInitialize(ULONG ComPort, ULONG BaudRate); BOOLEAN Rs232PortInitialize(ULONG ComPort, ULONG BaudRate);
BOOL Rs232PortGetByte(PUCHAR ByteRecieved); BOOLEAN Rs232PortGetByte(PUCHAR ByteRecieved);
BOOL Rs232PortPollByte(PUCHAR ByteRecieved); BOOLEAN Rs232PortPollByte(PUCHAR ByteRecieved);
VOID Rs232PortPutByte(UCHAR ByteToSend); VOID Rs232PortPutByte(UCHAR ByteToSend);
BOOL Rs232PortInUse(ULONG Base); BOOLEAN Rs232PortInUse(ULONG Base);
#endif // defined __RS232_H #endif // defined __RS232_H

View file

@ -106,10 +106,10 @@ typedef struct _MASTER_BOOT_RECORD
/////////////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////////////
#ifdef __i386__ #ifdef __i386__
BOOL DiskResetController(ULONG DriveNumber); BOOLEAN DiskResetController(ULONG DriveNumber);
BOOL DiskInt13ExtensionsSupported(ULONG DriveNumber); BOOLEAN DiskInt13ExtensionsSupported(ULONG DriveNumber);
//VOID DiskStopFloppyMotor(VOID); //VOID DiskStopFloppyMotor(VOID);
BOOL DiskGetExtendedDriveParameters(ULONG DriveNumber, PVOID Buffer, USHORT BufferSize); BOOLEAN DiskGetExtendedDriveParameters(ULONG DriveNumber, PVOID Buffer, USHORT BufferSize);
#endif // defined __i386__ #endif // defined __i386__
@ -118,11 +118,11 @@ BOOL DiskGetExtendedDriveParameters(ULONG DriveNumber, PVOID Buffer, USHORT Buff
// FreeLoader Disk Functions // FreeLoader Disk Functions
// //
/////////////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////////////
VOID DiskReportError (BOOL bError); VOID DiskReportError (BOOLEAN bError);
VOID DiskError(PCSTR ErrorString, ULONG ErrorCode); VOID DiskError(PCSTR ErrorString, ULONG ErrorCode);
PCSTR DiskGetErrorCodeString(ULONG ErrorCode); PCSTR DiskGetErrorCodeString(ULONG ErrorCode);
BOOL DiskReadLogicalSectors(ULONG DriveNumber, ULONGLONG SectorNumber, ULONG SectorCount, PVOID Buffer); // Implemented in i386disk.c BOOLEAN DiskReadLogicalSectors(ULONG DriveNumber, ULONGLONG SectorNumber, ULONG SectorCount, PVOID Buffer); // Implemented in i386disk.c
BOOL DiskIsDriveRemovable(ULONG DriveNumber); BOOLEAN DiskIsDriveRemovable(ULONG DriveNumber);
VOID DiskStopFloppyMotor(VOID); // Implemented in i386disk.c VOID DiskStopFloppyMotor(VOID); // Implemented in i386disk.c
/////////////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////////////
@ -130,10 +130,10 @@ VOID DiskStopFloppyMotor(VOID); // Implemented in i386disk.c
// Fixed Disk Partition Management Functions // Fixed Disk Partition Management Functions
// //
/////////////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////////////
BOOL DiskGetActivePartitionEntry(ULONG DriveNumber, PPARTITION_TABLE_ENTRY PartitionTableEntry, ULONG *ActivePartition); BOOLEAN DiskGetActivePartitionEntry(ULONG DriveNumber, PPARTITION_TABLE_ENTRY PartitionTableEntry, ULONG *ActivePartition);
BOOL DiskGetPartitionEntry(ULONG DriveNumber, ULONG PartitionNumber, PPARTITION_TABLE_ENTRY PartitionTableEntry); BOOLEAN DiskGetPartitionEntry(ULONG DriveNumber, ULONG PartitionNumber, PPARTITION_TABLE_ENTRY PartitionTableEntry);
BOOL DiskGetFirstPartitionEntry(PMASTER_BOOT_RECORD MasterBootRecord, PPARTITION_TABLE_ENTRY PartitionTableEntry); BOOLEAN DiskGetFirstPartitionEntry(PMASTER_BOOT_RECORD MasterBootRecord, PPARTITION_TABLE_ENTRY PartitionTableEntry);
BOOL DiskGetFirstExtendedPartitionEntry(PMASTER_BOOT_RECORD MasterBootRecord, PPARTITION_TABLE_ENTRY PartitionTableEntry); BOOLEAN DiskGetFirstExtendedPartitionEntry(PMASTER_BOOT_RECORD MasterBootRecord, PPARTITION_TABLE_ENTRY PartitionTableEntry);
BOOL DiskReadBootRecord(ULONG DriveNumber, ULONGLONG LogicalSectorNumber, PMASTER_BOOT_RECORD BootRecord); BOOLEAN DiskReadBootRecord(ULONG DriveNumber, ULONGLONG LogicalSectorNumber, PMASTER_BOOT_RECORD BootRecord);
#endif // defined __DISK_H #endif // defined __DISK_H

View file

@ -30,7 +30,7 @@ typedef struct
} PACKED DRIVE_MAP_LIST, *PDRIVE_MAP_LIST; } PACKED DRIVE_MAP_LIST, *PDRIVE_MAP_LIST;
VOID DriveMapMapDrivesInSection(PCSTR SectionName); VOID DriveMapMapDrivesInSection(PCSTR SectionName);
BOOL DriveMapIsValidDriveString(PCSTR DriveString); // Checks the drive string ("hd0") for validity BOOLEAN DriveMapIsValidDriveString(PCSTR DriveString); // Checks the drive string ("hd0") for validity
ULONG DriveMapGetBiosDriveNumber(PCSTR DeviceName); // Returns a BIOS drive number for any given device name (e.g. 0x80 for 'hd0') ULONG DriveMapGetBiosDriveNumber(PCSTR DeviceName); // Returns a BIOS drive number for any given device name (e.g. 0x80 for 'hd0')
VOID DriveMapInstallInt13Handler(PDRIVE_MAP_LIST DriveMap); // Installs the int 13h handler for the drive mapper VOID DriveMapInstallInt13Handler(PDRIVE_MAP_LIST DriveMap); // Installs the int 13h handler for the drive mapper
VOID DriveMapRemoveInt13Handler(VOID); // Removes a previously installed int 13h drive map handler VOID DriveMapRemoveInt13Handler(VOID); // Removes a previously installed int 13h drive map handler

View file

@ -82,7 +82,7 @@
#define Ke386EraseFlags(x) __asm__ __volatile__("pushl $0 ; popfl\n") #define Ke386EraseFlags(x) __asm__ __volatile__("pushl $0 ; popfl\n")
extern BOOL UserInterfaceUp; /* Tells us if the user interface is displayed */ extern BOOLEAN UserInterfaceUp; /* Tells us if the user interface is displayed */
VOID BootMain(LPSTR CmdLine); VOID BootMain(LPSTR CmdLine);
VOID RunLoader(VOID); VOID RunLoader(VOID);

View file

@ -33,15 +33,15 @@
#define PFILE FILE * #define PFILE FILE *
VOID FileSystemError(PCSTR ErrorString); VOID FileSystemError(PCSTR ErrorString);
BOOL FsOpenBootVolume(); BOOLEAN FsOpenBootVolume();
BOOL FsOpenSystemVolume(PCHAR SystemPath, PCHAR RemainingPath, PULONG BootDevice); BOOLEAN FsOpenSystemVolume(PCHAR SystemPath, PCHAR RemainingPath, PULONG BootDevice);
PFILE FsOpenFile(PCSTR FileName); PFILE FsOpenFile(PCSTR FileName);
VOID FsCloseFile(PFILE FileHandle); VOID FsCloseFile(PFILE FileHandle);
BOOL FsReadFile(PFILE FileHandle, ULONG BytesToRead, ULONG* BytesRead, PVOID Buffer); BOOLEAN FsReadFile(PFILE FileHandle, ULONG BytesToRead, ULONG* BytesRead, PVOID Buffer);
ULONG FsGetFileSize(PFILE FileHandle); ULONG FsGetFileSize(PFILE FileHandle);
VOID FsSetFilePointer(PFILE FileHandle, ULONG NewFilePointer); VOID FsSetFilePointer(PFILE FileHandle, ULONG NewFilePointer);
ULONG FsGetFilePointer(PFILE FileHandle); ULONG FsGetFilePointer(PFILE FileHandle);
BOOL FsIsEndOfFile(PFILE FileHandle); BOOLEAN FsIsEndOfFile(PFILE FileHandle);
ULONG FsGetNumPathParts(PCSTR Path); ULONG FsGetNumPathParts(PCSTR Path);
VOID FsGetFirstNameFromPath(PCHAR Buffer, PCSTR Path); VOID FsGetFirstNameFromPath(PCHAR Buffer, PCSTR Path);

View file

@ -666,32 +666,32 @@ typedef struct
BOOL Ext2OpenVolume(UCHAR DriveNumber, ULONGLONG VolumeStartSector); BOOLEAN Ext2OpenVolume(UCHAR DriveNumber, ULONGLONG VolumeStartSector);
FILE* Ext2OpenFile(PCSTR FileName); FILE* Ext2OpenFile(PCSTR FileName);
BOOL Ext2LookupFile(PCSTR FileName, PEXT2_FILE_INFO Ext2FileInfoPointer); BOOLEAN Ext2LookupFile(PCSTR FileName, PEXT2_FILE_INFO Ext2FileInfoPointer);
BOOL Ext2SearchDirectoryBufferForFile(PVOID DirectoryBuffer, ULONG DirectorySize, PCHAR FileName, PEXT2_DIR_ENTRY DirectoryEntry); BOOLEAN Ext2SearchDirectoryBufferForFile(PVOID DirectoryBuffer, ULONG DirectorySize, PCHAR FileName, PEXT2_DIR_ENTRY DirectoryEntry);
BOOL Ext2ReadFile(FILE *FileHandle, ULONGLONG BytesToRead, ULONGLONG* BytesRead, PVOID Buffer); BOOLEAN Ext2ReadFile(FILE *FileHandle, ULONGLONG BytesToRead, ULONGLONG* BytesRead, PVOID Buffer);
ULONGLONG Ext2GetFileSize(FILE *FileHandle); ULONGLONG Ext2GetFileSize(FILE *FileHandle);
VOID Ext2SetFilePointer(FILE *FileHandle, ULONGLONG NewFilePointer); VOID Ext2SetFilePointer(FILE *FileHandle, ULONGLONG NewFilePointer);
ULONGLONG Ext2GetFilePointer(FILE *FileHandle); ULONGLONG Ext2GetFilePointer(FILE *FileHandle);
BOOL Ext2ReadVolumeSectors(UCHAR DriveNumber, ULONGLONG SectorNumber, ULONGLONG SectorCount, PVOID Buffer); BOOLEAN Ext2ReadVolumeSectors(UCHAR DriveNumber, ULONGLONG SectorNumber, ULONGLONG SectorCount, PVOID Buffer);
BOOL Ext2ReadSuperBlock(VOID); BOOLEAN Ext2ReadSuperBlock(VOID);
BOOL Ext2ReadGroupDescriptors(VOID); BOOLEAN Ext2ReadGroupDescriptors(VOID);
BOOL Ext2ReadDirectory(ULONG Inode, PVOID* DirectoryBuffer, PEXT2_INODE InodePointer); BOOLEAN Ext2ReadDirectory(ULONG Inode, PVOID* DirectoryBuffer, PEXT2_INODE InodePointer);
BOOL Ext2ReadBlock(ULONG BlockNumber, PVOID Buffer); BOOLEAN Ext2ReadBlock(ULONG BlockNumber, PVOID Buffer);
BOOL Ext2ReadPartialBlock(ULONG BlockNumber, ULONG StartingOffset, ULONG Length, PVOID Buffer); BOOLEAN Ext2ReadPartialBlock(ULONG BlockNumber, ULONG StartingOffset, ULONG Length, PVOID Buffer);
ULONG Ext2GetGroupDescBlockNumber(ULONG Group); ULONG Ext2GetGroupDescBlockNumber(ULONG Group);
ULONG Ext2GetGroupDescOffsetInBlock(ULONG Group); ULONG Ext2GetGroupDescOffsetInBlock(ULONG Group);
ULONG Ext2GetInodeGroupNumber(ULONG Inode); ULONG Ext2GetInodeGroupNumber(ULONG Inode);
ULONG Ext2GetInodeBlockNumber(ULONG Inode); ULONG Ext2GetInodeBlockNumber(ULONG Inode);
ULONG Ext2GetInodeOffsetInBlock(ULONG Inode); ULONG Ext2GetInodeOffsetInBlock(ULONG Inode);
BOOL Ext2ReadInode(ULONG Inode, PEXT2_INODE InodeBuffer); BOOLEAN Ext2ReadInode(ULONG Inode, PEXT2_INODE InodeBuffer);
BOOL Ext2ReadGroupDescriptor(ULONG Group, PEXT2_GROUP_DESC GroupBuffer); BOOLEAN Ext2ReadGroupDescriptor(ULONG Group, PEXT2_GROUP_DESC GroupBuffer);
ULONG* Ext2ReadBlockPointerList(PEXT2_INODE Inode); ULONG* Ext2ReadBlockPointerList(PEXT2_INODE Inode);
ULONGLONG Ext2GetInodeFileSize(PEXT2_INODE Inode); ULONGLONG Ext2GetInodeFileSize(PEXT2_INODE Inode);
BOOL Ext2CopyIndirectBlockPointers(ULONG* BlockList, ULONG* CurrentBlockInList, ULONG BlockCount, ULONG IndirectBlock); BOOLEAN Ext2CopyIndirectBlockPointers(ULONG* BlockList, ULONG* CurrentBlockInList, ULONG BlockCount, ULONG IndirectBlock);
BOOL Ext2CopyDoubleIndirectBlockPointers(ULONG* BlockList, ULONG* CurrentBlockInList, ULONG BlockCount, ULONG DoubleIndirectBlock); BOOLEAN Ext2CopyDoubleIndirectBlockPointers(ULONG* BlockList, ULONG* CurrentBlockInList, ULONG BlockCount, ULONG DoubleIndirectBlock);
BOOL Ext2CopyTripleIndirectBlockPointers(ULONG* BlockList, ULONG* CurrentBlockInList, ULONG BlockCount, ULONG TripleIndirectBlock); BOOLEAN Ext2CopyTripleIndirectBlockPointers(ULONG* BlockList, ULONG* CurrentBlockInList, ULONG BlockCount, ULONG TripleIndirectBlock);
#endif // #defined __EXT2_H #endif // #defined __EXT2_H

View file

@ -152,24 +152,24 @@ typedef struct
BOOL FatOpenVolume(ULONG DriveNumber, ULONG VolumeStartSector, ULONG PartitionSectorCount); BOOLEAN FatOpenVolume(ULONG DriveNumber, ULONG VolumeStartSector, ULONG PartitionSectorCount);
ULONG FatDetermineFatType(PFAT_BOOTSECTOR FatBootSector, ULONG PartitionSectorCount); ULONG FatDetermineFatType(PFAT_BOOTSECTOR FatBootSector, ULONG PartitionSectorCount);
PVOID FatBufferDirectory(ULONG DirectoryStartCluster, ULONG* EntryCountPointer, BOOL RootDirectory); PVOID FatBufferDirectory(ULONG DirectoryStartCluster, ULONG* EntryCountPointer, BOOLEAN RootDirectory);
BOOL FatSearchDirectoryBufferForFile(PVOID DirectoryBuffer, ULONG EntryCount, PCHAR FileName, PFAT_FILE_INFO FatFileInfoPointer); BOOLEAN FatSearchDirectoryBufferForFile(PVOID DirectoryBuffer, ULONG EntryCount, PCHAR FileName, PFAT_FILE_INFO FatFileInfoPointer);
BOOL FatLookupFile(PCSTR FileName, PFAT_FILE_INFO FatFileInfoPointer); BOOLEAN FatLookupFile(PCSTR FileName, PFAT_FILE_INFO FatFileInfoPointer);
void FatParseShortFileName(PCHAR Buffer, PDIRENTRY DirEntry); void FatParseShortFileName(PCHAR Buffer, PDIRENTRY DirEntry);
BOOL FatGetFatEntry(ULONG Cluster, ULONG* ClusterPointer); BOOLEAN FatGetFatEntry(ULONG Cluster, ULONG* ClusterPointer);
FILE* FatOpenFile(PCSTR FileName); FILE* FatOpenFile(PCSTR FileName);
ULONG FatCountClustersInChain(ULONG StartCluster); ULONG FatCountClustersInChain(ULONG StartCluster);
ULONG* FatGetClusterChainArray(ULONG StartCluster); ULONG* FatGetClusterChainArray(ULONG StartCluster);
BOOL FatReadCluster(ULONG ClusterNumber, PVOID Buffer); BOOLEAN FatReadCluster(ULONG ClusterNumber, PVOID Buffer);
BOOL FatReadClusterChain(ULONG StartClusterNumber, ULONG NumberOfClusters, PVOID Buffer); BOOLEAN FatReadClusterChain(ULONG StartClusterNumber, ULONG NumberOfClusters, PVOID Buffer);
BOOL FatReadPartialCluster(ULONG ClusterNumber, ULONG StartingOffset, ULONG Length, PVOID Buffer); BOOLEAN FatReadPartialCluster(ULONG ClusterNumber, ULONG StartingOffset, ULONG Length, PVOID Buffer);
BOOL FatReadFile(FILE *FileHandle, ULONG BytesToRead, ULONG* BytesRead, PVOID Buffer); BOOLEAN FatReadFile(FILE *FileHandle, ULONG BytesToRead, ULONG* BytesRead, PVOID Buffer);
ULONG FatGetFileSize(FILE *FileHandle); ULONG FatGetFileSize(FILE *FileHandle);
VOID FatSetFilePointer(FILE *FileHandle, ULONG NewFilePointer); VOID FatSetFilePointer(FILE *FileHandle, ULONG NewFilePointer);
ULONG FatGetFilePointer(FILE *FileHandle); ULONG FatGetFilePointer(FILE *FileHandle);
BOOL FatReadVolumeSectors(ULONG DriveNumber, ULONG SectorNumber, ULONG SectorCount, PVOID Buffer); BOOLEAN FatReadVolumeSectors(ULONG DriveNumber, ULONG SectorNumber, ULONG SectorCount, PVOID Buffer);
#define ATTR_NORMAL 0x00 #define ATTR_NORMAL 0x00

View file

@ -100,14 +100,14 @@ typedef struct
ULONG FileStart; // File start sector ULONG FileStart; // File start sector
ULONG FileSize; // File size ULONG FileSize; // File size
ULONG FilePointer; // File pointer ULONG FilePointer; // File pointer
BOOL Directory; BOOLEAN Directory;
ULONG DriveNumber; ULONG DriveNumber;
} ISO_FILE_INFO, * PISO_FILE_INFO; } ISO_FILE_INFO, * PISO_FILE_INFO;
BOOL IsoOpenVolume(ULONG DriveNumber); BOOLEAN IsoOpenVolume(ULONG DriveNumber);
FILE* IsoOpenFile(PCSTR FileName); FILE* IsoOpenFile(PCSTR FileName);
BOOL IsoReadFile(FILE *FileHandle, ULONG BytesToRead, ULONG* BytesRead, PVOID Buffer); BOOLEAN IsoReadFile(FILE *FileHandle, ULONG BytesToRead, ULONG* BytesRead, PVOID Buffer);
ULONG IsoGetFileSize(FILE *FileHandle); ULONG IsoGetFileSize(FILE *FileHandle);
VOID IsoSetFilePointer(FILE *FileHandle, ULONG NewFilePointer); VOID IsoSetFilePointer(FILE *FileHandle, ULONG NewFilePointer);
ULONG IsoGetFilePointer(FILE *FileHandle); ULONG IsoGetFilePointer(FILE *FileHandle);

View file

@ -218,9 +218,9 @@ typedef struct
ULONGLONG Offset; ULONGLONG Offset;
} PACKED NTFS_FILE_HANDLE, *PNTFS_FILE_HANDLE; } PACKED NTFS_FILE_HANDLE, *PNTFS_FILE_HANDLE;
BOOL NtfsOpenVolume(ULONG DriveNumber, ULONG VolumeStartSector); BOOLEAN NtfsOpenVolume(ULONG DriveNumber, ULONG VolumeStartSector);
FILE* NtfsOpenFile(PCSTR FileName); FILE* NtfsOpenFile(PCSTR FileName);
BOOL NtfsReadFile(FILE *FileHandle, ULONG BytesToRead, ULONG* BytesRead, PVOID Buffer); BOOLEAN NtfsReadFile(FILE *FileHandle, ULONG BytesToRead, ULONG* BytesRead, PVOID Buffer);
ULONG NtfsGetFileSize(FILE *FileHandle); ULONG NtfsGetFileSize(FILE *FileHandle);
VOID NtfsSetFilePointer(FILE *FileHandle, ULONG NewFilePointer); VOID NtfsSetFilePointer(FILE *FileHandle, ULONG NewFilePointer);
ULONG NtfsGetFilePointer(FILE *FileHandle); ULONG NtfsGetFilePointer(FILE *FileHandle);

View file

@ -20,10 +20,10 @@
#ifndef __FSREC_H #ifndef __FSREC_H
#define __FSREC_H #define __FSREC_H
BOOL FsRecognizeVolume(ULONG DriveNumber, ULONG VolumeStartSector, UCHAR* VolumeType); BOOLEAN FsRecognizeVolume(ULONG DriveNumber, ULONG VolumeStartSector, UCHAR* VolumeType);
BOOL FsRecIsIso9660(ULONG DriveNumber); BOOLEAN FsRecIsIso9660(ULONG DriveNumber);
BOOL FsRecIsExt2(ULONG DriveNumber, ULONG VolumeStartSector); BOOLEAN FsRecIsExt2(ULONG DriveNumber, ULONG VolumeStartSector);
BOOL FsRecIsFat(ULONG DriveNumber, ULONG VolumeStartSector); BOOLEAN FsRecIsFat(ULONG DriveNumber, ULONG VolumeStartSector);
BOOL FsRecIsNtfs(ULONG DriveNumber, ULONG VolumeStartSector); BOOLEAN FsRecIsNtfs(ULONG DriveNumber, ULONG VolumeStartSector);
#endif // #defined __FSREC_H #endif // #defined __FSREC_H

View file

@ -55,30 +55,30 @@ extern ULONG IniFileSettingCount;
PFILE IniOpenIniFile(); PFILE IniOpenIniFile();
BOOL IniParseFile(PCHAR IniFileData, ULONG IniFileSize); BOOLEAN IniParseFile(PCHAR IniFileData, ULONG IniFileSize);
ULONG IniGetNextLineSize(PCHAR IniFileData, ULONG IniFileSize, ULONG CurrentOffset); ULONG IniGetNextLineSize(PCHAR IniFileData, ULONG IniFileSize, ULONG CurrentOffset);
ULONG IniGetNextLine(PCHAR IniFileData, ULONG IniFileSize, PCHAR Buffer, ULONG BufferSize, ULONG CurrentOffset); ULONG IniGetNextLine(PCHAR IniFileData, ULONG IniFileSize, PCHAR Buffer, ULONG BufferSize, ULONG CurrentOffset);
BOOL IniIsLineEmpty(PCHAR LineOfText, ULONG TextLength); BOOLEAN IniIsLineEmpty(PCHAR LineOfText, ULONG TextLength);
BOOL IniIsCommentLine(PCHAR LineOfText, ULONG TextLength); BOOLEAN IniIsCommentLine(PCHAR LineOfText, ULONG TextLength);
BOOL IniIsSectionName(PCHAR LineOfText, ULONG TextLength); BOOLEAN IniIsSectionName(PCHAR LineOfText, ULONG TextLength);
ULONG IniGetSectionNameSize(PCHAR SectionNameLine, ULONG LineLength); ULONG IniGetSectionNameSize(PCHAR SectionNameLine, ULONG LineLength);
VOID IniExtractSectionName(PCHAR SectionName, PCHAR SectionNameLine, ULONG LineLength); VOID IniExtractSectionName(PCHAR SectionName, PCHAR SectionNameLine, ULONG LineLength);
BOOL IniIsSetting(PCHAR LineOfText, ULONG TextLength); BOOLEAN IniIsSetting(PCHAR LineOfText, ULONG TextLength);
ULONG IniGetSettingNameSize(PCHAR SettingNameLine, ULONG LineLength); ULONG IniGetSettingNameSize(PCHAR SettingNameLine, ULONG LineLength);
ULONG IniGetSettingValueSize(PCHAR SettingValueLine, ULONG LineLength); ULONG IniGetSettingValueSize(PCHAR SettingValueLine, ULONG LineLength);
VOID IniExtractSettingName(PCHAR SettingName, PCHAR SettingNameLine, ULONG LineLength); VOID IniExtractSettingName(PCHAR SettingName, PCHAR SettingNameLine, ULONG LineLength);
VOID IniExtractSettingValue(PCHAR SettingValue, PCHAR SettingValueLine, ULONG LineLength); VOID IniExtractSettingValue(PCHAR SettingValue, PCHAR SettingValueLine, ULONG LineLength);
BOOL IniFileInitialize(VOID); BOOLEAN IniFileInitialize(VOID);
BOOL IniOpenSection(PCSTR SectionName, ULONG* SectionId); BOOLEAN IniOpenSection(PCSTR SectionName, ULONG* SectionId);
ULONG IniGetNumSectionItems(ULONG SectionId); ULONG IniGetNumSectionItems(ULONG SectionId);
ULONG IniGetSectionSettingNameSize(ULONG SectionId, ULONG SettingIndex); ULONG IniGetSectionSettingNameSize(ULONG SectionId, ULONG SettingIndex);
ULONG IniGetSectionSettingValueSize(ULONG SectionId, ULONG SettingIndex); ULONG IniGetSectionSettingValueSize(ULONG SectionId, ULONG SettingIndex);
BOOL IniReadSettingByNumber(ULONG SectionId, ULONG SettingNumber, PCHAR SettingName, ULONG NameSize, PCHAR SettingValue, ULONG ValueSize); BOOLEAN IniReadSettingByNumber(ULONG SectionId, ULONG SettingNumber, PCHAR SettingName, ULONG NameSize, PCHAR SettingValue, ULONG ValueSize);
BOOL IniReadSettingByName(ULONG SectionId, PCSTR SettingName, PCHAR Buffer, ULONG BufferSize); BOOLEAN IniReadSettingByName(ULONG SectionId, PCSTR SettingName, PCHAR Buffer, ULONG BufferSize);
BOOL IniAddSection(PCSTR SectionName, ULONG* SectionId); BOOLEAN IniAddSection(PCSTR SectionName, ULONG* SectionId);
BOOL IniAddSettingValueToSection(ULONG SectionId, PCSTR SettingName, PCSTR SettingValue); BOOLEAN IniAddSettingValueToSection(ULONG SectionId, PCSTR SettingName, PCSTR SettingValue);
#endif // defined __PARSEINI_H #endif // defined __PARSEINI_H

View file

@ -129,11 +129,11 @@ VOID BootOldLinuxKernel(ULONG KernelSize); // Implemented in linux.S
VOID LoadAndBootLinux(PCSTR OperatingSystemName, PCSTR Description); VOID LoadAndBootLinux(PCSTR OperatingSystemName, PCSTR Description);
BOOL LinuxParseIniSection(PCSTR OperatingSystemName); BOOLEAN LinuxParseIniSection(PCSTR OperatingSystemName);
BOOL LinuxReadBootSector(PFILE LinuxKernelFile); BOOLEAN LinuxReadBootSector(PFILE LinuxKernelFile);
BOOL LinuxReadSetupSector(PFILE LinuxKernelFile); BOOLEAN LinuxReadSetupSector(PFILE LinuxKernelFile);
BOOL LinuxReadKernel(PFILE LinuxKernelFile); BOOLEAN LinuxReadKernel(PFILE LinuxKernelFile);
BOOL LinuxCheckKernelVersion(VOID); BOOLEAN LinuxCheckKernelVersion(VOID);
BOOL LinuxReadInitrd(PFILE LinuxInitrdFile); BOOLEAN LinuxReadInitrd(PFILE LinuxInitrdFile);
#endif // defined __LINUX_H #endif // defined __LINUX_H

View file

@ -37,18 +37,18 @@ typedef enum tagVIDEODISPLAYMODE
typedef struct tagMACHVTBL typedef struct tagMACHVTBL
{ {
VOID (*ConsPutChar)(int Ch); VOID (*ConsPutChar)(int Ch);
BOOL (*ConsKbHit)(VOID); BOOLEAN (*ConsKbHit)(VOID);
int (*ConsGetCh)(VOID); int (*ConsGetCh)(VOID);
VOID (*VideoClearScreen)(UCHAR Attr); VOID (*VideoClearScreen)(UCHAR Attr);
VIDEODISPLAYMODE (*VideoSetDisplayMode)(char *DisplayMode, BOOL Init); VIDEODISPLAYMODE (*VideoSetDisplayMode)(char *DisplayMode, BOOLEAN Init);
VOID (*VideoGetDisplaySize)(PULONG Width, PULONG Height, PULONG Depth); VOID (*VideoGetDisplaySize)(PULONG Width, PULONG Height, PULONG Depth);
ULONG (*VideoGetBufferSize)(VOID); ULONG (*VideoGetBufferSize)(VOID);
VOID (*VideoSetTextCursorPosition)(ULONG X, ULONG Y); VOID (*VideoSetTextCursorPosition)(ULONG X, ULONG Y);
VOID (*VideoHideShowTextCursor)(BOOL Show); VOID (*VideoHideShowTextCursor)(BOOLEAN Show);
VOID (*VideoPutChar)(int Ch, UCHAR Attr, unsigned X, unsigned Y); VOID (*VideoPutChar)(int Ch, UCHAR Attr, unsigned X, unsigned Y);
VOID (*VideoCopyOffScreenBufferToVRAM)(PVOID Buffer); VOID (*VideoCopyOffScreenBufferToVRAM)(PVOID Buffer);
BOOL (*VideoIsPaletteFixed)(VOID); BOOLEAN (*VideoIsPaletteFixed)(VOID);
VOID (*VideoSetPaletteColor)(UCHAR Color, UCHAR Red, UCHAR Green, UCHAR Blue); VOID (*VideoSetPaletteColor)(UCHAR Color, UCHAR Red, UCHAR Green, UCHAR Blue);
VOID (*VideoGetPaletteColor)(UCHAR Color, UCHAR* Red, UCHAR* Green, UCHAR* Blue); VOID (*VideoGetPaletteColor)(UCHAR Color, UCHAR* Red, UCHAR* Green, UCHAR* Blue);
VOID (*VideoSync)(VOID); VOID (*VideoSync)(VOID);
@ -56,15 +56,15 @@ typedef struct tagMACHVTBL
ULONG (*GetMemoryMap)(PBIOS_MEMORY_MAP BiosMemoryMap, ULONG MaxMemoryMapSize); ULONG (*GetMemoryMap)(PBIOS_MEMORY_MAP BiosMemoryMap, ULONG MaxMemoryMapSize);
BOOL (*DiskGetBootVolume)(PULONG DriveNumber, PULONGLONG StartSector, PULONGLONG SectorCount, int *FsType); BOOLEAN (*DiskGetBootVolume)(PULONG DriveNumber, PULONGLONG StartSector, PULONGLONG SectorCount, int *FsType);
BOOL (*DiskGetSystemVolume)(char *SystemPath, char *RemainingPath, PULONG Device, PULONG DriveNumber, PULONGLONG StartSector, PULONGLONG SectorCount, int *FsType); BOOLEAN (*DiskGetSystemVolume)(char *SystemPath, char *RemainingPath, PULONG Device, PULONG DriveNumber, PULONGLONG StartSector, PULONGLONG SectorCount, int *FsType);
BOOL (*DiskGetBootPath)(char *BootPath, unsigned Size); BOOLEAN (*DiskGetBootPath)(char *BootPath, unsigned Size);
VOID (*DiskGetBootDevice)(PULONG BootDevice); VOID (*DiskGetBootDevice)(PULONG BootDevice);
BOOL (*DiskBootingFromFloppy)(VOID); BOOLEAN (*DiskBootingFromFloppy)(VOID);
BOOL (*DiskNormalizeSystemPath)(char *SystemPath, unsigned Size); BOOLEAN (*DiskNormalizeSystemPath)(char *SystemPath, unsigned Size);
BOOL (*DiskReadLogicalSectors)(ULONG DriveNumber, ULONGLONG SectorNumber, ULONG SectorCount, PVOID Buffer); BOOLEAN (*DiskReadLogicalSectors)(ULONG DriveNumber, ULONGLONG SectorNumber, ULONG SectorCount, PVOID Buffer);
BOOL (*DiskGetPartitionEntry)(ULONG DriveNumber, ULONG PartitionNumber, PPARTITION_TABLE_ENTRY PartitionTableEntry); BOOLEAN (*DiskGetPartitionEntry)(ULONG DriveNumber, ULONG PartitionNumber, PPARTITION_TABLE_ENTRY PartitionTableEntry);
BOOL (*DiskGetDriveGeometry)(ULONG DriveNumber, PGEOMETRY DriveGeometry); BOOLEAN (*DiskGetDriveGeometry)(ULONG DriveNumber, PGEOMETRY DriveGeometry);
ULONG (*DiskGetCacheableBlockCount)(ULONG DriveNumber); ULONG (*DiskGetCacheableBlockCount)(ULONG DriveNumber);
VOID (*RTCGetCurrentDateTime)(PULONG Year, PULONG Month, PULONG Day, PULONG Hour, PULONG Minute, PULONG Second); VOID (*RTCGetCurrentDateTime)(PULONG Year, PULONG Month, PULONG Day, PULONG Hour, PULONG Minute, PULONG Second);
@ -77,24 +77,24 @@ VOID MachInit(const char *CmdLine);
extern MACHVTBL MachVtbl; extern MACHVTBL MachVtbl;
VOID MachConsPutChar(int Ch); VOID MachConsPutChar(int Ch);
BOOL MachConsKbHit(); BOOLEAN MachConsKbHit();
int MachConsGetCh(); int MachConsGetCh();
VOID MachVideoClearScreen(UCHAR Attr); VOID MachVideoClearScreen(UCHAR Attr);
VIDEODISPLAYMODE MachVideoSetDisplayMode(char *DisplayMode, BOOL Init); VIDEODISPLAYMODE MachVideoSetDisplayMode(char *DisplayMode, BOOLEAN Init);
VOID MachVideoGetDisplaySize(PULONG Width, PULONG Height, PULONG Depth); VOID MachVideoGetDisplaySize(PULONG Width, PULONG Height, PULONG Depth);
ULONG MachVideoGetBufferSize(VOID); ULONG MachVideoGetBufferSize(VOID);
VOID MachVideoSetTextCursorPosition(ULONG X, ULONG Y); VOID MachVideoSetTextCursorPosition(ULONG X, ULONG Y);
VOID MachVideoHideShowTextCursor(BOOL Show); VOID MachVideoHideShowTextCursor(BOOLEAN Show);
VOID MachVideoPutChar(int Ch, UCHAR Attr, unsigned X, unsigned Y); VOID MachVideoPutChar(int Ch, UCHAR Attr, unsigned X, unsigned Y);
VOID MachVideoCopyOffScreenBufferToVRAM(PVOID Buffer); VOID MachVideoCopyOffScreenBufferToVRAM(PVOID Buffer);
BOOL MachVideoIsPaletteFixed(VOID); BOOLEAN MachVideoIsPaletteFixed(VOID);
VOID MachVideoSetPaletteColor(UCHAR Color, UCHAR Red, UCHAR Green, UCHAR Blue); VOID MachVideoSetPaletteColor(UCHAR Color, UCHAR Red, UCHAR Green, UCHAR Blue);
VOID MachVideoGetPaletteColor(UCHAR Color, UCHAR *Red, UCHAR *Green, UCHAR *Blue); VOID MachVideoGetPaletteColor(UCHAR Color, UCHAR *Red, UCHAR *Green, UCHAR *Blue);
VOID MachVideoSync(VOID); VOID MachVideoSync(VOID);
VOID MachVideoPrepareForReactOS(VOID); VOID MachVideoPrepareForReactOS(VOID);
ULONG MachGetMemoryMap(PBIOS_MEMORY_MAP BiosMemoryMap, ULONG MaxMemoryMapSize); ULONG MachGetMemoryMap(PBIOS_MEMORY_MAP BiosMemoryMap, ULONG MaxMemoryMapSize);
BOOL MachDiskGetBootVolume(PULONG DriveNumber, PULONGLONG StartSector, PULONGLONG SectorCount, int *FsType); BOOLEAN MachDiskGetBootVolume(PULONG DriveNumber, PULONGLONG StartSector, PULONGLONG SectorCount, int *FsType);
BOOL BOOLEAN
MachDiskGetSystemVolume(char *SystemPath, MachDiskGetSystemVolume(char *SystemPath,
char *RemainingPath, char *RemainingPath,
PULONG Device, PULONG Device,
@ -102,13 +102,13 @@ MachDiskGetSystemVolume(char *SystemPath,
PULONGLONG StartSector, PULONGLONG StartSector,
PULONGLONG SectorCount, PULONGLONG SectorCount,
int *FsType); int *FsType);
BOOL MachDiskGetBootPath(char *BootPath, unsigned Size); BOOLEAN MachDiskGetBootPath(char *BootPath, unsigned Size);
VOID MachDiskGetBootDevice(PULONG BootDevice); VOID MachDiskGetBootDevice(PULONG BootDevice);
BOOL MachDiskBootingFromFloppy(); BOOLEAN MachDiskBootingFromFloppy();
BOOL MachDiskNormalizeSystemPath(char *SystemPath, unsigned Size); BOOLEAN MachDiskNormalizeSystemPath(char *SystemPath, unsigned Size);
BOOL MachDiskReadLogicalSectors(ULONG DriveNumber, ULONGLONG SectorNumber, ULONG SectorCount, PVOID Buffer); BOOLEAN MachDiskReadLogicalSectors(ULONG DriveNumber, ULONGLONG SectorNumber, ULONG SectorCount, PVOID Buffer);
BOOL MachDiskGetPartitionEntry(ULONG DriveNumber, ULONG PartitionNumber, PPARTITION_TABLE_ENTRY PartitionTableEntry); BOOLEAN MachDiskGetPartitionEntry(ULONG DriveNumber, ULONG PartitionNumber, PPARTITION_TABLE_ENTRY PartitionTableEntry);
BOOL MachDiskGetDriveGeometry(ULONG DriveNumber, PGEOMETRY DriveGeometry); BOOLEAN MachDiskGetDriveGeometry(ULONG DriveNumber, PGEOMETRY DriveGeometry);
ULONG MachDiskGetCacheableBlockCount(ULONG DriveNumber); ULONG MachDiskGetCacheableBlockCount(ULONG DriveNumber);
VOID MachRTCGetCurrentDateTime(PULONG Year, PULONG Month, PULONG Day, PULONG Hour, PULONG Minute, PULONG Second); VOID MachRTCGetCurrentDateTime(PULONG Year, PULONG Month, PULONG Day, PULONG Hour, PULONG Minute, PULONG Second);
VOID MachHwDetect(VOID); VOID MachHwDetect(VOID);

View file

@ -78,13 +78,13 @@ ULONG MmFindAvailablePagesFromEnd(PVOID PageLookupTable, ULONG TotalPageCount,
ULONG MmFindAvailablePagesBeforePage(PVOID PageLookupTable, ULONG TotalPageCount, ULONG PagesNeeded, ULONG LastPage); // Returns the page number of the first available page range before the specified page ULONG MmFindAvailablePagesBeforePage(PVOID PageLookupTable, ULONG TotalPageCount, ULONG PagesNeeded, ULONG LastPage); // Returns the page number of the first available page range before the specified page
VOID MmFixupSystemMemoryMap(PBIOS_MEMORY_MAP BiosMemoryMap, ULONG* MapCount); // Removes entries in the memory map that describe memory above 4G VOID MmFixupSystemMemoryMap(PBIOS_MEMORY_MAP BiosMemoryMap, ULONG* MapCount); // Removes entries in the memory map that describe memory above 4G
VOID MmUpdateLastFreePageHint(PVOID PageLookupTable, ULONG TotalPageCount); // Sets the LastFreePageHint to the last usable page of memory VOID MmUpdateLastFreePageHint(PVOID PageLookupTable, ULONG TotalPageCount); // Sets the LastFreePageHint to the last usable page of memory
BOOL MmAreMemoryPagesAvailable(PVOID PageLookupTable, ULONG TotalPageCount, PVOID PageAddress, ULONG PageCount); // Returns TRUE if the specified pages of memory are available, otherwise FALSE BOOLEAN MmAreMemoryPagesAvailable(PVOID PageLookupTable, ULONG TotalPageCount, PVOID PageAddress, ULONG PageCount); // Returns TRUE if the specified pages of memory are available, otherwise FALSE
ULONG GetSystemMemorySize(VOID); // Returns the amount of total memory in the system ULONG GetSystemMemorySize(VOID); // Returns the amount of total memory in the system
//BOOL MmInitializeMemoryManager(ULONG LowMemoryStart, ULONG LowMemoryLength); //BOOLEAN MmInitializeMemoryManager(ULONG LowMemoryStart, ULONG LowMemoryLength);
BOOL MmInitializeMemoryManager(VOID); BOOLEAN MmInitializeMemoryManager(VOID);
PVOID MmAllocateMemory(ULONG MemorySize); PVOID MmAllocateMemory(ULONG MemorySize);
VOID MmFreeMemory(PVOID MemoryPointer); VOID MmFreeMemory(PVOID MemoryPointer);
//PVOID MmAllocateLowMemory(ULONG MemorySize); //PVOID MmAllocateLowMemory(ULONG MemorySize);

View file

@ -20,9 +20,9 @@
#ifndef __OSLIST_H #ifndef __OSLIST_H
#define __OSLIST_H #define __OSLIST_H
BOOL InitOperatingSystemList(PCSTR **SectionNamesPointer, PCSTR **DisplayNamesPointer, ULONG* OperatingSystemCountPointer); BOOLEAN InitOperatingSystemList(PCSTR **SectionNamesPointer, PCSTR **DisplayNamesPointer, ULONG* OperatingSystemCountPointer);
ULONG CountOperatingSystems(ULONG SectionId); ULONG CountOperatingSystems(ULONG SectionId);
BOOL AllocateListMemory(PCHAR **SectionNamesPointer, PCHAR **DisplayNamesPointer, ULONG OperatingSystemCount); BOOLEAN AllocateListMemory(PCHAR **SectionNamesPointer, PCHAR **DisplayNamesPointer, ULONG OperatingSystemCount);
BOOL RemoveQuotes(PCHAR QuotedString); BOOLEAN RemoveQuotes(PCHAR QuotedString);
#endif // #defined __OSLIST_H #endif // #defined __OSLIST_H

View file

@ -40,7 +40,7 @@ VOID ReactOSRunSetupLoader(VOID);
// ARC Path Functions // ARC Path Functions
// //
/////////////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////////////
BOOL DissectArcPath(CHAR *ArcPath, CHAR *BootPath, ULONG* BootDrive, ULONG* BootPartition); BOOLEAN DissectArcPath(CHAR *ArcPath, CHAR *BootPath, ULONG* BootDrive, ULONG* BootPartition);
VOID ConstructArcPath(PCHAR ArcPath, PCHAR SystemFolder, ULONG Disk, ULONG Partition); VOID ConstructArcPath(PCHAR ArcPath, PCHAR SystemFolder, ULONG Disk, ULONG Partition);
ULONG ConvertArcNameToBiosDriveNumber(PCHAR ArcPath); ULONG ConvertArcNameToBiosDriveNumber(PCHAR ArcPath);
@ -59,11 +59,11 @@ extern memory_map_t reactos_memory_map[32]; // Memory map
VOID FASTCALL FrLdrSetupPae(ULONG Magic); VOID FASTCALL FrLdrSetupPae(ULONG Magic);
VOID FASTCALL FrLdrSetupPageDirectory(VOID); VOID FASTCALL FrLdrSetupPageDirectory(VOID);
VOID FASTCALL FrLdrGetPaeMode(VOID); VOID FASTCALL FrLdrGetPaeMode(VOID);
BOOL STDCALL FrLdrMapKernel(FILE *KernelImage); BOOLEAN NTAPI FrLdrMapKernel(FILE *KernelImage);
ULONG_PTR STDCALL FrLdrCreateModule(LPCSTR ModuleName); ULONG_PTR NTAPI FrLdrCreateModule(LPCSTR ModuleName);
ULONG_PTR STDCALL FrLdrLoadModule(FILE *ModuleImage, LPCSTR ModuleName, PULONG ModuleSize); ULONG_PTR NTAPI FrLdrLoadModule(FILE *ModuleImage, LPCSTR ModuleName, PULONG ModuleSize);
BOOL STDCALL FrLdrCloseModule(ULONG_PTR ModuleBase, ULONG dwModuleSize); BOOLEAN NTAPI FrLdrCloseModule(ULONG_PTR ModuleBase, ULONG dwModuleSize);
VOID STDCALL FrLdrStartup(ULONG Magic); VOID NTAPI FrLdrStartup(ULONG Magic);
typedef VOID (FASTCALL *ASMCODE)(ULONG Magic, PROS_LOADER_PARAMETER_BLOCK LoaderBlock); typedef VOID (FASTCALL *ASMCODE)(ULONG Magic, PROS_LOADER_PARAMETER_BLOCK LoaderBlock);
#endif // defined __REACTOS_H #endif // defined __REACTOS_H

View file

@ -67,7 +67,7 @@ VOID
RegInitializeRegistry(VOID); RegInitializeRegistry(VOID);
LONG LONG
RegInitCurrentControlSet(BOOL LastKnownGood); RegInitCurrentControlSet(BOOLEAN LastKnownGood);
LONG LONG
@ -125,11 +125,11 @@ ULONG
RegGetValueCount (FRLDRHKEY Key); RegGetValueCount (FRLDRHKEY Key);
BOOL BOOLEAN
RegImportBinaryHive (PCHAR ChunkBase, RegImportBinaryHive (PCHAR ChunkBase,
ULONG ChunkSize); ULONG ChunkSize);
BOOL BOOLEAN
RegExportBinaryHive (PCWSTR KeyName, RegExportBinaryHive (PCWSTR KeyName,
PCHAR ChunkBase, PCHAR ChunkBase,
ULONG* ChunkSize); ULONG* ChunkSize);

View file

@ -49,7 +49,7 @@ PLIST_ITEM RtlListRemoveHead(PLIST_ITEM ListHead); // Removes the entry a
PLIST_ITEM RtlListRemoveTail(PLIST_ITEM ListHead); // Removes the entry at the tail of the list PLIST_ITEM RtlListRemoveTail(PLIST_ITEM ListHead); // Removes the entry at the tail of the list
PLIST_ITEM RtlListGetHead(PLIST_ITEM ListHead); // Returns the entry at the head of the list PLIST_ITEM RtlListGetHead(PLIST_ITEM ListHead); // Returns the entry at the head of the list
PLIST_ITEM RtlListGetTail(PLIST_ITEM ListHead); // Returns the entry at the tail of the list PLIST_ITEM RtlListGetTail(PLIST_ITEM ListHead); // Returns the entry at the tail of the list
BOOL RtlListIsEmpty(PLIST_ITEM ListHead); // Indicates whether a doubly linked list is empty BOOLEAN RtlListIsEmpty(PLIST_ITEM ListHead); // Indicates whether a doubly linked list is empty
ULONG RtlListCountEntries(PLIST_ITEM ListHead); // Counts the entries in a doubly linked list ULONG RtlListCountEntries(PLIST_ITEM ListHead); // Counts the entries in a doubly linked list
PLIST_ITEM RtlListGetPrevious(PLIST_ITEM ListEntry); // Returns the previous item in the list PLIST_ITEM RtlListGetPrevious(PLIST_ITEM ListEntry); // Returns the previous item in the list
PLIST_ITEM RtlListGetNext(PLIST_ITEM ListEntry); // Returns the next item in the list PLIST_ITEM RtlListGetNext(PLIST_ITEM ListEntry); // Returns the next item in the list

View file

@ -43,12 +43,12 @@ extern UCHAR UiEditBoxBgColor; // Edit box text background color
extern CHAR UiTitleBoxTitleText[260]; // Title box's title text extern CHAR UiTitleBoxTitleText[260]; // Title box's title text
extern BOOL UserInterfaceUp; // Tells us if the user interface is displayed extern BOOLEAN UserInterfaceUp; // Tells us if the user interface is displayed
extern BOOL UiUseSpecialEffects; // Tells us if we should use fade effects extern BOOLEAN UiUseSpecialEffects; // Tells us if we should use fade effects
extern BOOL UiCenterMenu; extern BOOLEAN UiCenterMenu;
extern BOOL UiMenuBox; extern BOOLEAN UiMenuBox;
extern BOOL UiMinimal; extern BOOLEAN UiMinimal;
extern CHAR UiTimeText[]; extern CHAR UiTimeText[];
extern const CHAR UiMonthNames[12][15]; extern const CHAR UiMonthNames[12][15];
@ -58,13 +58,13 @@ extern const CHAR UiMonthNames[12][15];
// User Interface Functions // User Interface Functions
// //
/////////////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////////////
BOOL UiInitialize(BOOLEAN ShowGui); // Initialize User-Interface BOOLEAN UiInitialize(BOOLEAN ShowGui); // Initialize User-Interface
BOOL SetupUiInitialize(VOID); // Initialize User-Interface BOOLEAN SetupUiInitialize(VOID); // Initialize User-Interface
VOID UiUnInitialize(PCSTR BootText); // Un-initialize User-Interface VOID UiUnInitialize(PCSTR BootText); // Un-initialize User-Interface
VOID UiDrawBackdrop(VOID); // Fills the entire screen with a backdrop VOID UiDrawBackdrop(VOID); // Fills the entire screen with a backdrop
VOID UiFillArea(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom, CHAR FillChar, UCHAR Attr /* Color Attributes */); // Fills the area specified with FillChar and Attr VOID UiFillArea(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom, CHAR FillChar, UCHAR Attr /* Color Attributes */); // Fills the area specified with FillChar and Attr
VOID UiDrawShadow(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom); // Draws a shadow on the bottom and right sides of the area specified VOID UiDrawShadow(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom); // Draws a shadow on the bottom and right sides of the area specified
VOID UiDrawBox(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom, UCHAR VertStyle, UCHAR HorzStyle, BOOL Fill, BOOL Shadow, UCHAR Attr); // Draws a box around the area specified VOID UiDrawBox(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom, UCHAR VertStyle, UCHAR HorzStyle, BOOLEAN Fill, BOOLEAN Shadow, UCHAR Attr); // Draws a box around the area specified
VOID UiDrawText(ULONG X, ULONG Y, PCSTR Text, UCHAR Attr); // Draws text at coordinates specified VOID UiDrawText(ULONG X, ULONG Y, PCSTR Text, UCHAR Attr); // Draws text at coordinates specified
VOID UiDrawCenteredText(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom, PCSTR TextString, UCHAR Attr); // Draws centered text at the coordinates specified and clips the edges VOID UiDrawCenteredText(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom, PCSTR TextString, UCHAR Attr); // Draws centered text at the coordinates specified and clips the edges
VOID UiDrawStatusText(PCSTR StatusText); // Draws text at the very bottom line on the screen VOID UiDrawStatusText(PCSTR StatusText); // Draws text at the very bottom line on the screen
@ -76,7 +76,7 @@ VOID UiDrawProgressBarCenter(ULONG Position, ULONG Range, PCHAR ProgressText);
VOID UiDrawProgressBar(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom, ULONG Position, ULONG Range, PCHAR ProgressText); // Draws the progress bar showing nPos percent filled VOID UiDrawProgressBar(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom, ULONG Position, ULONG Range, PCHAR ProgressText); // Draws the progress bar showing nPos percent filled
VOID UiShowMessageBoxesInSection(PCSTR SectionName); // Displays all the message boxes in a given section VOID UiShowMessageBoxesInSection(PCSTR SectionName); // Displays all the message boxes in a given section
VOID UiEscapeString(PCHAR String); // Processes a string and changes all occurances of "\n" to '\n' VOID UiEscapeString(PCHAR String); // Processes a string and changes all occurances of "\n" to '\n'
BOOL UiEditBox(PCSTR MessageText, PCHAR EditTextBuffer, ULONG Length); BOOLEAN UiEditBox(PCSTR MessageText, PCHAR EditTextBuffer, ULONG Length);
UCHAR UiTextToColor(PCSTR ColorText); // Converts the text color into it's equivalent color value UCHAR UiTextToColor(PCSTR ColorText); // Converts the text color into it's equivalent color value
UCHAR UiTextToFillStyle(PCSTR FillStyleText); // Converts the text fill into it's equivalent fill value UCHAR UiTextToFillStyle(PCSTR FillStyleText); // Converts the text fill into it's equivalent fill value
@ -91,9 +91,9 @@ VOID UiFadeOut(VOID); // Fades the screen out
// Menu Functions // Menu Functions
// //
/////////////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////////////
typedef BOOL (*UiMenuKeyPressFilterCallback)(ULONG KeyPress); typedef BOOLEAN (*UiMenuKeyPressFilterCallback)(ULONG KeyPress);
BOOL UiDisplayMenu(PCSTR MenuItemList[], ULONG MenuItemCount, ULONG DefaultMenuItem, LONG MenuTimeOut, ULONG* SelectedMenuItem, BOOL CanEscape, UiMenuKeyPressFilterCallback KeyPressFilter); BOOLEAN UiDisplayMenu(PCSTR MenuItemList[], ULONG MenuItemCount, ULONG DefaultMenuItem, LONG MenuTimeOut, ULONG* SelectedMenuItem, BOOLEAN CanEscape, UiMenuKeyPressFilterCallback KeyPressFilter);

View file

@ -31,7 +31,7 @@
VOID GuiDrawBackdrop(VOID); // Fills the entire screen with a backdrop VOID GuiDrawBackdrop(VOID); // Fills the entire screen with a backdrop
VOID GuiFillArea(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom, UCHAR FillChar, UCHAR Attr /* Color Attributes */); // Fills the area specified with FillChar and Attr VOID GuiFillArea(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom, UCHAR FillChar, UCHAR Attr /* Color Attributes */); // Fills the area specified with FillChar and Attr
VOID GuiDrawShadow(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom); // Draws a shadow on the bottom and right sides of the area specified VOID GuiDrawShadow(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom); // Draws a shadow on the bottom and right sides of the area specified
VOID GuiDrawBox(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom, UCHAR VertStyle, UCHAR HorzStyle, BOOL Fill, BOOL Shadow, UCHAR Attr); // Draws a box around the area specified VOID GuiDrawBox(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom, UCHAR VertStyle, UCHAR HorzStyle, BOOLEAN Fill, BOOLEAN Shadow, UCHAR Attr); // Draws a box around the area specified
VOID GuiDrawText(ULONG X, ULONG Y, PUCHAR Text, UCHAR Attr); // Draws text at coordinates specified VOID GuiDrawText(ULONG X, ULONG Y, PUCHAR Text, UCHAR Attr); // Draws text at coordinates specified
VOID GuiDrawStatusText(PCSTR StatusText); // Draws text at the very bottom line on the screen VOID GuiDrawStatusText(PCSTR StatusText); // Draws text at the very bottom line on the screen
VOID GuiUpdateDateTime(VOID); // Updates the date and time VOID GuiUpdateDateTime(VOID); // Updates the date and time
@ -49,7 +49,7 @@ UCHAR GuiTextToFillStyle(PCSTR FillStyleText); // Converts the text fill into
// Menu Functions // Menu Functions
// //
/////////////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////////////
BOOL GuiDisplayMenu(PCSTR MenuItemList[], ULONG MenuItemCount, ULONG DefaultMenuItem, LONG MenuTimeOut, ULONG* SelectedMenuItem); BOOLEAN GuiDisplayMenu(PCSTR MenuItemList[], ULONG MenuItemCount, ULONG DefaultMenuItem, LONG MenuTimeOut, ULONG* SelectedMenuItem);

View file

@ -28,13 +28,13 @@
// Textual User Interface Functions // Textual User Interface Functions
// //
/////////////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////////////
BOOL TuiInitialize(VOID); // Initialize User-Interface BOOLEAN TuiInitialize(VOID); // Initialize User-Interface
VOID TuiUnInitialize(VOID); // Un-initialize User-Interface VOID TuiUnInitialize(VOID); // Un-initialize User-Interface
VOID TuiDrawBackdrop(VOID); // Fills the entire screen with a backdrop VOID TuiDrawBackdrop(VOID); // Fills the entire screen with a backdrop
VOID TuiFillArea(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom, CHAR FillChar, UCHAR Attr /* Color Attributes */); // Fills the area specified with FillChar and Attr VOID TuiFillArea(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom, CHAR FillChar, UCHAR Attr /* Color Attributes */); // Fills the area specified with FillChar and Attr
VOID TuiDrawShadow(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom); // Draws a shadow on the bottom and right sides of the area specified VOID TuiDrawShadow(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom); // Draws a shadow on the bottom and right sides of the area specified
VOID TuiDrawBox(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom, UCHAR VertStyle, UCHAR HorzStyle, BOOL Fill, BOOL Shadow, UCHAR Attr); // Draws a box around the area specified VOID TuiDrawBox(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom, UCHAR VertStyle, UCHAR HorzStyle, BOOLEAN Fill, BOOLEAN Shadow, UCHAR Attr); // Draws a box around the area specified
VOID TuiDrawText(ULONG X, ULONG Y, PCSTR Text, UCHAR Attr); // Draws text at coordinates specified VOID TuiDrawText(ULONG X, ULONG Y, PCSTR Text, UCHAR Attr); // Draws text at coordinates specified
VOID TuiDrawCenteredText(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom, PCSTR TextString, UCHAR Attr); // Draws centered text at the coordinates specified and clips the edges VOID TuiDrawCenteredText(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom, PCSTR TextString, UCHAR Attr); // Draws centered text at the coordinates specified and clips the edges
VOID TuiDrawStatusText(PCSTR StatusText); // Draws text at the very bottom line on the screen VOID TuiDrawStatusText(PCSTR StatusText); // Draws text at the very bottom line on the screen
@ -45,7 +45,7 @@ VOID TuiMessageBox(PCSTR MessageText); // Displays a message box on the scr
VOID TuiMessageBoxCritical(PCSTR MessageText); // Displays a message box on the screen with an ok button using no system resources VOID TuiMessageBoxCritical(PCSTR MessageText); // Displays a message box on the screen with an ok button using no system resources
VOID TuiDrawProgressBarCenter(ULONG Position, ULONG Range, PCHAR ProgressText); // Draws the progress bar showing nPos percent filled VOID TuiDrawProgressBarCenter(ULONG Position, ULONG Range, PCHAR ProgressText); // Draws the progress bar showing nPos percent filled
VOID TuiDrawProgressBar(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom, ULONG Position, ULONG Range, PCHAR ProgressText); // Draws the progress bar showing nPos percent filled VOID TuiDrawProgressBar(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom, ULONG Position, ULONG Range, PCHAR ProgressText); // Draws the progress bar showing nPos percent filled
BOOL TuiEditBox(PCSTR MessageText, PCHAR EditTextBuffer, ULONG Length); BOOLEAN TuiEditBox(PCSTR MessageText, PCHAR EditTextBuffer, ULONG Length);
UCHAR TuiTextToColor(PCSTR ColorText); // Converts the text color into it's equivalent color value UCHAR TuiTextToColor(PCSTR ColorText); // Converts the text color into it's equivalent color value
UCHAR TuiTextToFillStyle(PCSTR FillStyleText); // Converts the text fill into it's equivalent fill value UCHAR TuiTextToFillStyle(PCSTR FillStyleText); // Converts the text fill into it's equivalent fill value
@ -73,12 +73,12 @@ typedef struct
} TUI_MENU_INFO, *PTUI_MENU_INFO; } TUI_MENU_INFO, *PTUI_MENU_INFO;
VOID WINAPI TuiCalcMenuBoxSize(PTUI_MENU_INFO MenuInfo); VOID NTAPI TuiCalcMenuBoxSize(PTUI_MENU_INFO MenuInfo);
VOID WINAPI TuiDrawMenu(PTUI_MENU_INFO MenuInfo); VOID NTAPI TuiDrawMenu(PTUI_MENU_INFO MenuInfo);
VOID WINAPI TuiDrawMenuBox(PTUI_MENU_INFO MenuInfo); VOID NTAPI TuiDrawMenuBox(PTUI_MENU_INFO MenuInfo);
VOID WINAPI TuiDrawMenuItem(PTUI_MENU_INFO MenuInfo, ULONG MenuItemNumber); VOID NTAPI TuiDrawMenuItem(PTUI_MENU_INFO MenuInfo, ULONG MenuItemNumber);
ULONG WINAPI TuiProcessMenuKeyboardEvent(PTUI_MENU_INFO MenuInfo, UiMenuKeyPressFilterCallback KeyPressFilter); ULONG NTAPI TuiProcessMenuKeyboardEvent(PTUI_MENU_INFO MenuInfo, UiMenuKeyPressFilterCallback KeyPressFilter);
BOOL WINAPI TuiDisplayMenu(PCSTR MenuItemList[], ULONG MenuItemCount, ULONG DefaultMenuItem, LONG MenuTimeOut, ULONG* SelectedMenuItem, BOOL CanEscape, UiMenuKeyPressFilterCallback KeyPressFilter); BOOLEAN NTAPI TuiDisplayMenu(PCSTR MenuItemList[], ULONG MenuItemCount, ULONG DefaultMenuItem, LONG MenuTimeOut, ULONG* SelectedMenuItem, BOOLEAN CanEscape, UiMenuKeyPressFilterCallback KeyPressFilter);
/* /*

View file

@ -19,12 +19,12 @@
#include <freeldr.h> #include <freeldr.h>
BOOL IniFileInitialize(VOID) BOOLEAN IniFileInitialize(VOID)
{ {
PFILE Freeldr_Ini; // File handle for freeldr.ini PFILE Freeldr_Ini; // File handle for freeldr.ini
PCHAR FreeLoaderIniFileData; PCHAR FreeLoaderIniFileData;
ULONG FreeLoaderIniFileSize; ULONG FreeLoaderIniFileSize;
BOOL Success; BOOLEAN Success;
// Open freeldr.ini // Open freeldr.ini
Freeldr_Ini = IniOpenIniFile(); Freeldr_Ini = IniOpenIniFile();

View file

@ -22,7 +22,7 @@
#define NDEBUG #define NDEBUG
#include <debug.h> #include <debug.h>
BOOL IniOpenSection(PCSTR SectionName, ULONG* SectionId) BOOLEAN IniOpenSection(PCSTR SectionName, ULONG* SectionId)
{ {
PINI_SECTION Section; PINI_SECTION Section;
@ -79,7 +79,7 @@ ULONG IniGetSectionSettingValueSize(ULONG SectionId, ULONG SettingIndex)
return (strlen(Section->SectionItemList[SettingIndex].ItemValue) + 1); return (strlen(Section->SectionItemList[SettingIndex].ItemValue) + 1);
} }
BOOL IniReadSettingByNumber(ULONG SectionId, ULONG SettingNumber, PCHAR SettingName, ULONG NameSize, PCHAR SettingValue, ULONG ValueSize) BOOLEAN IniReadSettingByNumber(ULONG SectionId, ULONG SettingNumber, PCHAR SettingName, ULONG NameSize, PCHAR SettingValue, ULONG ValueSize)
{ {
PINI_SECTION Section = (PINI_SECTION)SectionId; PINI_SECTION Section = (PINI_SECTION)SectionId;
PINI_SECTION_ITEM SectionItem; PINI_SECTION_ITEM SectionItem;
@ -129,7 +129,7 @@ BOOL IniReadSettingByNumber(ULONG SectionId, ULONG SettingNumber, PCHAR SettingN
return FALSE; return FALSE;
} }
BOOL IniReadSettingByName(ULONG SectionId, PCSTR SettingName, PCHAR Buffer, ULONG BufferSize) BOOLEAN IniReadSettingByName(ULONG SectionId, PCSTR SettingName, PCHAR Buffer, ULONG BufferSize)
{ {
PINI_SECTION Section = (PINI_SECTION)SectionId; PINI_SECTION Section = (PINI_SECTION)SectionId;
PINI_SECTION_ITEM SectionItem; PINI_SECTION_ITEM SectionItem;
@ -161,7 +161,7 @@ BOOL IniReadSettingByName(ULONG SectionId, PCSTR SettingName, PCHAR Buffer, ULON
return FALSE; return FALSE;
} }
BOOL IniAddSection(PCSTR SectionName, ULONG* SectionId) BOOLEAN IniAddSection(PCSTR SectionName, ULONG* SectionId)
{ {
PINI_SECTION Section; PINI_SECTION Section;
@ -201,7 +201,7 @@ BOOL IniAddSection(PCSTR SectionName, ULONG* SectionId)
return TRUE; return TRUE;
} }
BOOL IniAddSettingValueToSection(ULONG SectionId, PCSTR SettingName, PCSTR SettingValue) BOOLEAN IniAddSettingValueToSection(ULONG SectionId, PCSTR SettingName, PCSTR SettingValue)
{ {
PINI_SECTION Section = (PINI_SECTION)SectionId; PINI_SECTION Section = (PINI_SECTION)SectionId;
PINI_SECTION_ITEM SectionItem; PINI_SECTION_ITEM SectionItem;

View file

@ -27,7 +27,7 @@ ULONG IniFileSectionCount = 0;
ULONG IniFileSettingCount = 0; ULONG IniFileSettingCount = 0;
BOOL IniParseFile(PCHAR IniFileData, ULONG IniFileSize) BOOLEAN IniParseFile(PCHAR IniFileData, ULONG IniFileSize)
{ {
ULONG CurrentOffset; ULONG CurrentOffset;
ULONG CurrentLineNumber; ULONG CurrentLineNumber;
@ -249,7 +249,7 @@ ULONG IniGetNextLine(PCHAR IniFileData, ULONG IniFileSize, PCHAR Buffer, ULONG B
return CurrentOffset; return CurrentOffset;
} }
BOOL IniIsLineEmpty(PCHAR LineOfText, ULONG TextLength) BOOLEAN IniIsLineEmpty(PCHAR LineOfText, ULONG TextLength)
{ {
ULONG Idx; ULONG Idx;
@ -272,7 +272,7 @@ BOOL IniIsLineEmpty(PCHAR LineOfText, ULONG TextLength)
return TRUE; return TRUE;
} }
BOOL IniIsCommentLine(PCHAR LineOfText, ULONG TextLength) BOOLEAN IniIsCommentLine(PCHAR LineOfText, ULONG TextLength)
{ {
ULONG Idx; ULONG Idx;
@ -298,7 +298,7 @@ BOOL IniIsCommentLine(PCHAR LineOfText, ULONG TextLength)
return FALSE; return FALSE;
} }
BOOL IniIsSectionName(PCHAR LineOfText, ULONG TextLength) BOOLEAN IniIsSectionName(PCHAR LineOfText, ULONG TextLength)
{ {
ULONG Idx; ULONG Idx;
@ -405,7 +405,7 @@ VOID IniExtractSectionName(PCHAR SectionName, PCHAR SectionNameLine, ULONG LineL
SectionName[DestIdx] = '\0'; SectionName[DestIdx] = '\0';
} }
BOOL IniIsSetting(PCHAR LineOfText, ULONG TextLength) BOOLEAN IniIsSetting(PCHAR LineOfText, ULONG TextLength)
{ {
ULONG Idx; ULONG Idx;

View file

@ -29,12 +29,12 @@
PLINUX_BOOTSECTOR LinuxBootSector = NULL; PLINUX_BOOTSECTOR LinuxBootSector = NULL;
PLINUX_SETUPSECTOR LinuxSetupSector = NULL; PLINUX_SETUPSECTOR LinuxSetupSector = NULL;
ULONG SetupSectorSize = 0; ULONG SetupSectorSize = 0;
BOOL NewStyleLinuxKernel = FALSE; BOOLEAN NewStyleLinuxKernel = FALSE;
ULONG LinuxKernelSize = 0; ULONG LinuxKernelSize = 0;
ULONG LinuxInitrdSize = 0; ULONG LinuxInitrdSize = 0;
CHAR LinuxKernelName[260]; CHAR LinuxKernelName[260];
CHAR LinuxInitrdName[260]; CHAR LinuxInitrdName[260];
BOOL LinuxHasInitrd = FALSE; BOOLEAN LinuxHasInitrd = FALSE;
CHAR LinuxCommandLine[260] = ""; CHAR LinuxCommandLine[260] = "";
ULONG LinuxCommandLineSize = 0; ULONG LinuxCommandLineSize = 0;
PVOID LinuxKernelLoadAddress = NULL; PVOID LinuxKernelLoadAddress = NULL;
@ -217,7 +217,7 @@ LinuxBootFailed:
LinuxCommandLineSize = 0; LinuxCommandLineSize = 0;
} }
BOOL LinuxParseIniSection(PCSTR OperatingSystemName) BOOLEAN LinuxParseIniSection(PCSTR OperatingSystemName)
{ {
CHAR SettingName[260]; CHAR SettingName[260];
ULONG SectionId; ULONG SectionId;
@ -262,7 +262,7 @@ BOOL LinuxParseIniSection(PCSTR OperatingSystemName)
return TRUE; return TRUE;
} }
BOOL LinuxReadBootSector(PFILE LinuxKernelFile) BOOLEAN LinuxReadBootSector(PFILE LinuxKernelFile)
{ {
// Allocate memory for boot sector // Allocate memory for boot sector
LinuxBootSector = (PLINUX_BOOTSECTOR)MmAllocateMemory(512); LinuxBootSector = (PLINUX_BOOTSECTOR)MmAllocateMemory(512);
@ -299,7 +299,7 @@ BOOL LinuxReadBootSector(PFILE LinuxKernelFile)
return TRUE; return TRUE;
} }
BOOL LinuxReadSetupSector(PFILE LinuxKernelFile) BOOLEAN LinuxReadSetupSector(PFILE LinuxKernelFile)
{ {
UCHAR TempLinuxSetupSector[512]; UCHAR TempLinuxSetupSector[512];
@ -365,7 +365,7 @@ BOOL LinuxReadSetupSector(PFILE LinuxKernelFile)
return TRUE; return TRUE;
} }
BOOL LinuxReadKernel(PFILE LinuxKernelFile) BOOLEAN LinuxReadKernel(PFILE LinuxKernelFile)
{ {
ULONG BytesLoaded; ULONG BytesLoaded;
CHAR StatusText[260]; CHAR StatusText[260];
@ -401,7 +401,7 @@ BOOL LinuxReadKernel(PFILE LinuxKernelFile)
return TRUE; return TRUE;
} }
BOOL LinuxCheckKernelVersion(VOID) BOOLEAN LinuxCheckKernelVersion(VOID)
{ {
// Just assume old kernel until we find otherwise // Just assume old kernel until we find otherwise
NewStyleLinuxKernel = FALSE; NewStyleLinuxKernel = FALSE;
@ -438,7 +438,7 @@ BOOL LinuxCheckKernelVersion(VOID)
return TRUE; return TRUE;
} }
BOOL LinuxReadInitrd(PFILE LinuxInitrdFile) BOOLEAN LinuxReadInitrd(PFILE LinuxInitrdFile)
{ {
ULONG BytesLoaded; ULONG BytesLoaded;
CHAR StatusText[260]; CHAR StatusText[260];

View file

@ -57,7 +57,7 @@ MachConsPutChar(int Ch)
MachVtbl.ConsPutChar(Ch); MachVtbl.ConsPutChar(Ch);
} }
BOOL BOOLEAN
MachConsKbHit() MachConsKbHit()
{ {
return MachVtbl.ConsKbHit(); return MachVtbl.ConsKbHit();
@ -76,7 +76,7 @@ MachVideoClearScreen(UCHAR Attr)
} }
VIDEODISPLAYMODE VIDEODISPLAYMODE
MachVideoSetDisplayMode(char *DisplayMode, BOOL Init) MachVideoSetDisplayMode(char *DisplayMode, BOOLEAN Init)
{ {
return MachVtbl.VideoSetDisplayMode(DisplayMode, Init); return MachVtbl.VideoSetDisplayMode(DisplayMode, Init);
} }
@ -100,7 +100,7 @@ MachVideoSetTextCursorPosition(ULONG X, ULONG Y)
} }
VOID VOID
MachVideoHideShowTextCursor(BOOL Show) MachVideoHideShowTextCursor(BOOLEAN Show)
{ {
MachVtbl.VideoHideShowTextCursor(Show); MachVtbl.VideoHideShowTextCursor(Show);
} }
@ -117,7 +117,7 @@ MachVideoCopyOffScreenBufferToVRAM(PVOID Buffer)
MachVtbl.VideoCopyOffScreenBufferToVRAM(Buffer); MachVtbl.VideoCopyOffScreenBufferToVRAM(Buffer);
} }
BOOL BOOLEAN
MachVideoIsPaletteFixed(VOID) MachVideoIsPaletteFixed(VOID)
{ {
return MachVtbl.VideoIsPaletteFixed(); return MachVtbl.VideoIsPaletteFixed();
@ -153,13 +153,13 @@ MachGetMemoryMap(PBIOS_MEMORY_MAP BiosMemoryMap, ULONG MaxMemoryMapSize)
return MachVtbl.GetMemoryMap(BiosMemoryMap, MaxMemoryMapSize); return MachVtbl.GetMemoryMap(BiosMemoryMap, MaxMemoryMapSize);
} }
BOOL BOOLEAN
MachDiskGetBootVolume(PULONG DriveNumber, PULONGLONG StartSector, PULONGLONG SectorCount, int *FsType) MachDiskGetBootVolume(PULONG DriveNumber, PULONGLONG StartSector, PULONGLONG SectorCount, int *FsType)
{ {
return MachVtbl.DiskGetBootVolume(DriveNumber, StartSector, SectorCount, FsType); return MachVtbl.DiskGetBootVolume(DriveNumber, StartSector, SectorCount, FsType);
} }
BOOL BOOLEAN
MachDiskGetSystemVolume(char *SystemPath, MachDiskGetSystemVolume(char *SystemPath,
char *RemainingPath, char *RemainingPath,
PULONG Device, PULONG Device,
@ -173,7 +173,7 @@ MachDiskGetSystemVolume(char *SystemPath,
FsType); FsType);
} }
BOOL BOOLEAN
MachDiskGetBootPath(char *BootPath, unsigned Size) MachDiskGetBootPath(char *BootPath, unsigned Size)
{ {
return MachVtbl.DiskGetBootPath(BootPath, Size); return MachVtbl.DiskGetBootPath(BootPath, Size);
@ -185,31 +185,31 @@ MachDiskGetBootDevice(PULONG BootDevice)
MachVtbl.DiskGetBootDevice(BootDevice); MachVtbl.DiskGetBootDevice(BootDevice);
} }
BOOL BOOLEAN
MachDiskBootingFromFloppy() MachDiskBootingFromFloppy()
{ {
return MachVtbl.DiskBootingFromFloppy(); return MachVtbl.DiskBootingFromFloppy();
} }
BOOL BOOLEAN
MachDiskNormalizeSystemPath(char *SystemPath, unsigned Size) MachDiskNormalizeSystemPath(char *SystemPath, unsigned Size)
{ {
return MachVtbl.DiskNormalizeSystemPath(SystemPath, Size); return MachVtbl.DiskNormalizeSystemPath(SystemPath, Size);
} }
BOOL BOOLEAN
MachDiskReadLogicalSectors(ULONG DriveNumber, ULONGLONG SectorNumber, ULONG SectorCount, PVOID Buffer) MachDiskReadLogicalSectors(ULONG DriveNumber, ULONGLONG SectorNumber, ULONG SectorCount, PVOID Buffer)
{ {
return MachVtbl.DiskReadLogicalSectors(DriveNumber, SectorNumber, SectorCount, Buffer); return MachVtbl.DiskReadLogicalSectors(DriveNumber, SectorNumber, SectorCount, Buffer);
} }
BOOL BOOLEAN
MachDiskGetPartitionEntry(ULONG DriveNumber, ULONG PartitionNumber, PPARTITION_TABLE_ENTRY PartitionTableEntry) MachDiskGetPartitionEntry(ULONG DriveNumber, ULONG PartitionNumber, PPARTITION_TABLE_ENTRY PartitionTableEntry)
{ {
return MachVtbl.DiskGetPartitionEntry(DriveNumber, PartitionNumber, PartitionTableEntry); return MachVtbl.DiskGetPartitionEntry(DriveNumber, PartitionNumber, PartitionTableEntry);
} }
BOOL BOOLEAN
MachDiskGetDriveGeometry(ULONG DriveNumber, PGEOMETRY DriveGeometry) MachDiskGetDriveGeometry(ULONG DriveNumber, PGEOMETRY DriveGeometry)
{ {
return MachVtbl.DiskGetDriveGeometry(DriveNumber, DriveGeometry); return MachVtbl.DiskGetDriveGeometry(DriveNumber, DriveGeometry);

View file

@ -1625,7 +1625,7 @@ enum reg_class
standard Unix calling sequences. If the option is not selected, standard Unix calling sequences. If the option is not selected,
the caller must always pop the args. the caller must always pop the args.
The attribute stdcall is equivalent to RTD on a per module basis. */ The attribute NTAPI is equivalent to RTD on a per module basis. */
#define RETURN_POPS_ARGS(FUNDECL, FUNTYPE, SIZE) \ #define RETURN_POPS_ARGS(FUNDECL, FUNTYPE, SIZE) \
ix86_return_pops_args ((FUNDECL), (FUNTYPE), (SIZE)) ix86_return_pops_args ((FUNDECL), (FUNTYPE), (SIZE))

View file

@ -1639,7 +1639,7 @@ getpagesize (void)
} }
#ifdef __i386__ #ifdef __i386__
extern int VirtualProtect (char *, int, int, int *) __attribute__((stdcall)); extern int VirtualProtect (char *, int, int, int *) __attribute__((NTAPI));
#endif #endif
int int

View file

@ -1626,7 +1626,7 @@ enum reg_class
standard Unix calling sequences. If the option is not selected, standard Unix calling sequences. If the option is not selected,
the caller must always pop the args. the caller must always pop the args.
The attribute stdcall is equivalent to RTD on a per module basis. */ The attribute NTAPI is equivalent to RTD on a per module basis. */
#define RETURN_POPS_ARGS(FUNDECL, FUNTYPE, SIZE) \ #define RETURN_POPS_ARGS(FUNDECL, FUNTYPE, SIZE) \
ix86_return_pops_args ((FUNDECL), (FUNTYPE), (SIZE)) ix86_return_pops_args ((FUNDECL), (FUNTYPE), (SIZE))

View file

@ -45,7 +45,7 @@ ULONG TotalPagesInLookupTable = 0;
ULONG FreePagesInLookupTable = 0; ULONG FreePagesInLookupTable = 0;
ULONG LastFreePageHint = 0; ULONG LastFreePageHint = 0;
BOOL MmInitializeMemoryManager(VOID) BOOLEAN MmInitializeMemoryManager(VOID)
{ {
BIOS_MEMORY_MAP BiosMemoryMap[32]; BIOS_MEMORY_MAP BiosMemoryMap[32];
ULONG BiosMemoryMapEntryCount; ULONG BiosMemoryMapEntryCount;
@ -416,7 +416,7 @@ VOID MmUpdateLastFreePageHint(PVOID PageLookupTable, ULONG TotalPageCount)
} }
} }
BOOL MmAreMemoryPagesAvailable(PVOID PageLookupTable, ULONG TotalPageCount, PVOID PageAddress, ULONG PageCount) BOOLEAN MmAreMemoryPagesAvailable(PVOID PageLookupTable, ULONG TotalPageCount, PVOID PageAddress, ULONG PageCount)
{ {
PPAGE_LOOKUP_TABLE_ITEM RealPageLookupTable = (PPAGE_LOOKUP_TABLE_ITEM)PageLookupTable; PPAGE_LOOKUP_TABLE_ITEM RealPageLookupTable = (PPAGE_LOOKUP_TABLE_ITEM)PageLookupTable;
ULONG StartPage; ULONG StartPage;

View file

@ -19,7 +19,7 @@
#include <freeldr.h> #include <freeldr.h>
BOOL InitOperatingSystemList(PCSTR **SectionNamesPointer, PCSTR **DisplayNamesPointer, ULONG* OperatingSystemCountPointer) BOOLEAN InitOperatingSystemList(PCSTR **SectionNamesPointer, PCSTR **DisplayNamesPointer, ULONG* OperatingSystemCountPointer)
{ {
ULONG Idx; ULONG Idx;
ULONG CurrentOperatingSystemIndex; ULONG CurrentOperatingSystemIndex;
@ -110,7 +110,7 @@ ULONG CountOperatingSystems(ULONG SectionId)
return OperatingSystemCount; return OperatingSystemCount;
} }
BOOL AllocateListMemory(PCHAR **SectionNamesPointer, PCHAR **DisplayNamesPointer, ULONG OperatingSystemCount) BOOLEAN AllocateListMemory(PCHAR **SectionNamesPointer, PCHAR **DisplayNamesPointer, ULONG OperatingSystemCount)
{ {
ULONG Idx; ULONG Idx;
PCHAR *OperatingSystemSectionNames = NULL; PCHAR *OperatingSystemSectionNames = NULL;
@ -195,7 +195,7 @@ AllocateListMemoryFailed:
return FALSE; return FALSE;
} }
BOOL RemoveQuotes(PCHAR QuotedString) BOOLEAN RemoveQuotes(PCHAR QuotedString)
{ {
CHAR TempString[200]; CHAR TempString[200];

View file

@ -21,7 +21,7 @@
#include <freeldr.h> #include <freeldr.h>
BOOL DissectArcPath(CHAR *ArcPath, CHAR *BootPath, ULONG* BootDrive, ULONG* BootPartition) BOOLEAN DissectArcPath(CHAR *ArcPath, CHAR *BootPath, ULONG* BootDrive, ULONG* BootPartition)
{ {
char *p; char *p;

View file

@ -327,7 +327,7 @@ CmiCreateDefaultRootKeyCell (PKEY_CELL RootKeyCell, PCWSTR KeyName)
ULONG NameSize; ULONG NameSize;
ULONG CellSize; ULONG CellSize;
ULONG i; ULONG i;
BOOL Packable = TRUE; BOOLEAN Packable = TRUE;
assert (RootKeyCell); assert (RootKeyCell);
@ -463,7 +463,7 @@ CmiCreateHive (PCWSTR KeyName)
static VOID static VOID
CmiCleanupHive(PREGISTRY_HIVE Hive, BOOL Release) CmiCleanupHive(PREGISTRY_HIVE Hive, BOOLEAN Release)
{ {
MmFreeMemory (Hive->FreeListOffset); MmFreeMemory (Hive->FreeListOffset);
MmFreeMemory (Hive->FreeList); MmFreeMemory (Hive->FreeList);
@ -494,7 +494,7 @@ CmiGetBin (PREGISTRY_HIVE Hive,
} }
static BOOL static BOOLEAN
CmiMergeFree(PREGISTRY_HIVE RegistryHive, CmiMergeFree(PREGISTRY_HIVE RegistryHive,
PCELL_HEADER FreeBlock, PCELL_HEADER FreeBlock,
BLOCK_OFFSET FreeOffset) BLOCK_OFFSET FreeOffset)
@ -584,11 +584,11 @@ CmiMergeFree(PREGISTRY_HIVE RegistryHive,
} }
static BOOL static BOOLEAN
CmiAddFree(PREGISTRY_HIVE RegistryHive, CmiAddFree(PREGISTRY_HIVE RegistryHive,
PCELL_HEADER FreeBlock, PCELL_HEADER FreeBlock,
BLOCK_OFFSET FreeOffset, BLOCK_OFFSET FreeOffset,
BOOL MergeFreeBlocks) BOOLEAN MergeFreeBlocks)
{ {
PCELL_HEADER *tmpList; PCELL_HEADER *tmpList;
BLOCK_OFFSET *tmpListOffset; BLOCK_OFFSET *tmpListOffset;
@ -691,7 +691,7 @@ CmiAddFree(PREGISTRY_HIVE RegistryHive,
} }
static BOOL static BOOLEAN
CmiAddBin(PREGISTRY_HIVE RegistryHive, CmiAddBin(PREGISTRY_HIVE RegistryHive,
ULONG BlockCount, ULONG BlockCount,
PVOID *NewBlock, PVOID *NewBlock,
@ -751,7 +751,7 @@ CmiAddBin(PREGISTRY_HIVE RegistryHive,
} }
static BOOL static BOOLEAN
CmiAllocateCell (PREGISTRY_HIVE RegistryHive, CmiAllocateCell (PREGISTRY_HIVE RegistryHive,
LONG CellSize, LONG CellSize,
PVOID *Block, PVOID *Block,
@ -848,14 +848,14 @@ CmiGetCell (PREGISTRY_HIVE Hive,
} }
static BOOL static BOOLEAN
CmiAllocateHashTableCell (PREGISTRY_HIVE Hive, CmiAllocateHashTableCell (PREGISTRY_HIVE Hive,
PBLOCK_OFFSET HBOffset, PBLOCK_OFFSET HBOffset,
ULONG SubKeyCount) ULONG SubKeyCount)
{ {
PHASH_TABLE_CELL HashCell; PHASH_TABLE_CELL HashCell;
ULONG NewHashSize; ULONG NewHashSize;
BOOL Status; BOOLEAN Status;
NewHashSize = sizeof(HASH_TABLE_CELL) + NewHashSize = sizeof(HASH_TABLE_CELL) +
(SubKeyCount * sizeof(HASH_RECORD)); (SubKeyCount * sizeof(HASH_RECORD));
@ -875,7 +875,7 @@ CmiAllocateHashTableCell (PREGISTRY_HIVE Hive,
} }
static BOOL static BOOLEAN
CmiAddKeyToParentHashTable (PREGISTRY_HIVE Hive, CmiAddKeyToParentHashTable (PREGISTRY_HIVE Hive,
BLOCK_OFFSET ParentKeyOffset, BLOCK_OFFSET ParentKeyOffset,
PKEY_CELL NewKeyCell, PKEY_CELL NewKeyCell,
@ -916,14 +916,14 @@ CmiAddKeyToParentHashTable (PREGISTRY_HIVE Hive,
} }
static BOOL static BOOLEAN
CmiAllocateValueListCell (PREGISTRY_HIVE Hive, CmiAllocateValueListCell (PREGISTRY_HIVE Hive,
PBLOCK_OFFSET ValueListOffset, PBLOCK_OFFSET ValueListOffset,
ULONG ValueCount) ULONG ValueCount)
{ {
PVALUE_LIST_CELL ValueListCell; PVALUE_LIST_CELL ValueListCell;
ULONG ValueListSize; ULONG ValueListSize;
BOOL Status; BOOLEAN Status;
ValueListSize = sizeof(VALUE_LIST_CELL) + ValueListSize = sizeof(VALUE_LIST_CELL) +
(ValueCount * sizeof(BLOCK_OFFSET)); (ValueCount * sizeof(BLOCK_OFFSET));
@ -941,7 +941,7 @@ CmiAllocateValueListCell (PREGISTRY_HIVE Hive,
} }
static BOOL static BOOLEAN
CmiAllocateValueCell(PREGISTRY_HIVE Hive, CmiAllocateValueCell(PREGISTRY_HIVE Hive,
PVALUE_CELL *ValueCell, PVALUE_CELL *ValueCell,
BLOCK_OFFSET *ValueCellOffset, BLOCK_OFFSET *ValueCellOffset,
@ -949,7 +949,7 @@ CmiAllocateValueCell(PREGISTRY_HIVE Hive,
{ {
PVALUE_CELL NewValueCell; PVALUE_CELL NewValueCell;
ULONG NameSize; ULONG NameSize;
BOOL Status; BOOLEAN Status;
BOOLEAN Packable = TRUE; BOOLEAN Packable = TRUE;
ULONG i; ULONG i;
@ -1003,7 +1003,7 @@ CmiAllocateValueCell(PREGISTRY_HIVE Hive,
} }
static BOOL static BOOLEAN
CmiAddValueToKeyValueList(PREGISTRY_HIVE Hive, CmiAddValueToKeyValueList(PREGISTRY_HIVE Hive,
BLOCK_OFFSET KeyCellOffset, BLOCK_OFFSET KeyCellOffset,
BLOCK_OFFSET ValueCellOffset) BLOCK_OFFSET ValueCellOffset)
@ -1031,7 +1031,7 @@ CmiAddValueToKeyValueList(PREGISTRY_HIVE Hive,
return TRUE; return TRUE;
} }
static BOOL static BOOLEAN
CmiExportValue (PREGISTRY_HIVE Hive, CmiExportValue (PREGISTRY_HIVE Hive,
BLOCK_OFFSET KeyCellOffset, BLOCK_OFFSET KeyCellOffset,
FRLDRHKEY Key, FRLDRHKEY Key,
@ -1106,7 +1106,7 @@ CmiExportValue (PREGISTRY_HIVE Hive,
} }
static BOOL static BOOLEAN
CmiExportSubKey (PREGISTRY_HIVE Hive, CmiExportSubKey (PREGISTRY_HIVE Hive,
BLOCK_OFFSET ParentKeyOffset, BLOCK_OFFSET ParentKeyOffset,
FRLDRHKEY ParentKey, FRLDRHKEY ParentKey,
@ -1270,7 +1270,7 @@ CmiCalcHiveChecksum (PREGISTRY_HIVE Hive)
} }
static BOOL static BOOLEAN
CmiExportHive (PREGISTRY_HIVE Hive, CmiExportHive (PREGISTRY_HIVE Hive,
PCWSTR KeyName) PCWSTR KeyName)
{ {
@ -1365,7 +1365,7 @@ CmiExportHive (PREGISTRY_HIVE Hive,
} }
static BOOL static BOOLEAN
RegImportValue (PHBIN RootBin, RegImportValue (PHBIN RootBin,
PVALUE_CELL ValueCell, PVALUE_CELL ValueCell,
FRLDRHKEY Key) FRLDRHKEY Key)
@ -1451,7 +1451,7 @@ RegImportValue (PHBIN RootBin,
} }
static BOOL static BOOLEAN
RegImportSubKey(PHBIN RootBin, RegImportSubKey(PHBIN RootBin,
PKEY_CELL KeyCell, PKEY_CELL KeyCell,
FRLDRHKEY ParentKey) FRLDRHKEY ParentKey)
@ -1550,7 +1550,7 @@ RegImportSubKey(PHBIN RootBin,
} }
BOOL BOOLEAN
RegImportBinaryHive(PCHAR ChunkBase, RegImportBinaryHive(PCHAR ChunkBase,
ULONG ChunkSize) ULONG ChunkSize)
{ {
@ -1627,7 +1627,7 @@ RegImportBinaryHive(PCHAR ChunkBase,
} }
BOOL BOOLEAN
RegExportBinaryHive(PCWSTR KeyName, RegExportBinaryHive(PCWSTR KeyName,
PCHAR ChunkBase, PCHAR ChunkBase,
ULONG* ChunkSize) ULONG* ChunkSize)

View file

@ -33,8 +33,8 @@ memory_map_t reactos_memory_map[32]; // Memory map
static CHAR szLoadingMsg[] = "Loading ReactOS..."; static CHAR szLoadingMsg[] = "Loading ReactOS...";
static BOOL static BOOLEAN
STDCALL NTAPI
FrLdrLoadKernel(PCHAR szFileName, FrLdrLoadKernel(PCHAR szFileName,
INT nPos) INT nPos)
{ {
@ -109,7 +109,7 @@ FreeldrSeekFile(PVOID FileContext, ULONG_PTR Position)
return TRUE; return TRUE;
} }
static BOOL static BOOLEAN
LoadKernelSymbols(PCHAR szKernelName, int nPos) LoadKernelSymbols(PCHAR szKernelName, int nPos)
{ {
static ROSSYM_CALLBACKS FreeldrCallbacks = static ROSSYM_CALLBACKS FreeldrCallbacks =
@ -143,7 +143,7 @@ LoadKernelSymbols(PCHAR szKernelName, int nPos)
return TRUE; return TRUE;
} }
static BOOL static BOOLEAN
FrLdrLoadNlsFile(PCSTR szFileName, FrLdrLoadNlsFile(PCSTR szFileName,
PCSTR szModuleName) PCSTR szModuleName)
{ {
@ -182,7 +182,7 @@ FrLdrLoadNlsFile(PCSTR szFileName,
return(TRUE); return(TRUE);
} }
static BOOL static BOOLEAN
FrLdrLoadNlsFiles(PCHAR szSystemRoot, FrLdrLoadNlsFiles(PCHAR szSystemRoot,
PCHAR szErrorOut) PCHAR szErrorOut)
{ {
@ -294,7 +294,7 @@ FrLdrLoadNlsFiles(PCHAR szSystemRoot,
return(TRUE); return(TRUE);
} }
static BOOL static BOOLEAN
FrLdrLoadDriver(PCHAR szFileName, FrLdrLoadDriver(PCHAR szFileName,
INT nPos) INT nPos)
{ {

View file

@ -93,7 +93,7 @@ RegInitializeRegistry (VOID)
LONG LONG
RegInitCurrentControlSet(BOOL LastKnownGood) RegInitCurrentControlSet(BOOLEAN LastKnownGood)
{ {
WCHAR ControlSetKeyName[80]; WCHAR ControlSetKeyName[80];
FRLDRHKEY SelectKey; FRLDRHKEY SelectKey;

View file

@ -45,7 +45,7 @@ FreeldrSeekFile(PVOID FileContext, ULONG_PTR Position)
return TRUE; return TRUE;
} }
static BOOL static BOOLEAN
LoadKernel(PCSTR szSourcePath, PCSTR szFileName) LoadKernel(PCSTR szSourcePath, PCSTR szFileName)
{ {
CHAR szFullName[256]; CHAR szFullName[256];
@ -110,7 +110,7 @@ LoadKernel(PCSTR szSourcePath, PCSTR szFileName)
return(TRUE); return(TRUE);
} }
static BOOL static BOOLEAN
LoadKernelSymbols(PCSTR szSourcePath, PCSTR szFileName) LoadKernelSymbols(PCSTR szSourcePath, PCSTR szFileName)
{ {
static ROSSYM_CALLBACKS FreeldrCallbacks = static ROSSYM_CALLBACKS FreeldrCallbacks =
@ -165,7 +165,7 @@ LoadKernelSymbols(PCSTR szSourcePath, PCSTR szFileName)
return FALSE; return FALSE;
} }
static BOOL static BOOLEAN
LoadDriver(PCSTR szSourcePath, PCSTR szFileName) LoadDriver(PCSTR szSourcePath, PCSTR szFileName)
{ {
CHAR szFullName[256]; CHAR szFullName[256];
@ -230,7 +230,7 @@ LoadDriver(PCSTR szSourcePath, PCSTR szFileName)
} }
static BOOL static BOOLEAN
LoadNlsFile(PCSTR szSourcePath, PCSTR szFileName, PCSTR szModuleName) LoadNlsFile(PCSTR szSourcePath, PCSTR szFileName, PCSTR szModuleName)
{ {
CHAR szFullName[256]; CHAR szFullName[256];

View file

@ -82,7 +82,7 @@ PLIST_ITEM RtlListGetTail(PLIST_ITEM ListHead)
return ListHead; return ListHead;
} }
BOOL RtlListIsEmpty(PLIST_ITEM ListHead) BOOLEAN RtlListIsEmpty(PLIST_ITEM ListHead)
{ {
if (ListHead == NULL) if (ListHead == NULL)
{ {

View file

@ -31,7 +31,7 @@ VOID GuiDrawShadow(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom)
{ {
} }
VOID GuiDrawBox(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom, UCHAR VertStyle, UCHAR HorzStyle, BOOL Fill, BOOL Shadow, UCHAR Attr) VOID GuiDrawBox(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom, UCHAR VertStyle, UCHAR HorzStyle, BOOLEAN Fill, BOOLEAN Shadow, UCHAR Attr)
{ {
} }

View file

@ -20,8 +20,8 @@
#include <freeldr.h> #include <freeldr.h>
PVOID TextVideoBuffer = NULL; PVOID TextVideoBuffer = NULL;
extern BOOL UiDrawTime; extern BOOLEAN UiDrawTime;
extern BOOL UiMinimal; extern BOOLEAN UiMinimal;
/* /*
* printf() - prints formatted text to stdout * printf() - prints formatted text to stdout
@ -82,7 +82,7 @@ int printf(const char *format, ... )
return 0; return 0;
} }
BOOL TuiInitialize(VOID) BOOLEAN TuiInitialize(VOID)
{ {
MachVideoClearScreen(ATTR(COLOR_WHITE, COLOR_BLACK)); MachVideoClearScreen(ATTR(COLOR_WHITE, COLOR_BLACK));
MachVideoHideShowTextCursor(FALSE); MachVideoHideShowTextCursor(FALSE);
@ -300,7 +300,7 @@ VOID TuiDrawShadow(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom)
* DrawBox() * DrawBox()
* This function assumes coordinates are zero-based * This function assumes coordinates are zero-based
*/ */
VOID TuiDrawBox(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom, UCHAR VertStyle, UCHAR HorzStyle, BOOL Fill, BOOL Shadow, UCHAR Attr) VOID TuiDrawBox(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom, UCHAR VertStyle, UCHAR HorzStyle, BOOLEAN Fill, BOOLEAN Shadow, UCHAR Attr)
{ {
UCHAR ULCorner, URCorner, LLCorner, LRCorner; UCHAR ULCorner, URCorner, LLCorner, LRCorner;
@ -473,7 +473,7 @@ VOID TuiUpdateDateTime(VOID)
CHAR DateString[40]; CHAR DateString[40];
CHAR TimeString[40]; CHAR TimeString[40];
CHAR TempString[20]; CHAR TempString[20];
BOOL PMHour = FALSE; BOOLEAN PMHour = FALSE;
/* Don't draw the time if this has been disabled */ /* Don't draw the time if this has been disabled */
if (!UiDrawTime) return; if (!UiDrawTime) return;
@ -882,7 +882,7 @@ VOID TuiFadeOut(VOID)
} }
BOOL TuiEditBox(PCSTR MessageText, PCHAR EditTextBuffer, ULONG Length) BOOLEAN TuiEditBox(PCSTR MessageText, PCHAR EditTextBuffer, ULONG Length)
{ {
int width = 8; int width = 8;
unsigned int height = 1; unsigned int height = 1;
@ -897,7 +897,7 @@ BOOL TuiEditBox(PCSTR MessageText, PCHAR EditTextBuffer, ULONG Length)
int EditBoxCursorX; int EditBoxCursorX;
unsigned int EditBoxTextCount; unsigned int EditBoxTextCount;
int EditBoxTextDisplayIndex; int EditBoxTextDisplayIndex;
BOOL ReturnCode; BOOLEAN ReturnCode;
PVOID ScreenBuffer; PVOID ScreenBuffer;
// Save the screen contents // Save the screen contents

View file

@ -13,14 +13,14 @@
/* FUNCTIONS *****************************************************************/ /* FUNCTIONS *****************************************************************/
BOOL BOOLEAN
WINAPI NTAPI
TuiDisplayMenu(PCSTR MenuItemList[], TuiDisplayMenu(PCSTR MenuItemList[],
ULONG MenuItemCount, ULONG MenuItemCount,
ULONG DefaultMenuItem, ULONG DefaultMenuItem,
LONG MenuTimeOut, LONG MenuTimeOut,
ULONG* SelectedMenuItem, ULONG* SelectedMenuItem,
BOOL CanEscape, BOOLEAN CanEscape,
UiMenuKeyPressFilterCallback KeyPressFilter) UiMenuKeyPressFilterCallback KeyPressFilter)
{ {
TUI_MENU_INFO MenuInformation; TUI_MENU_INFO MenuInformation;
@ -135,7 +135,7 @@ TuiDisplayMenu(PCSTR MenuItemList[],
} }
VOID VOID
WINAPI NTAPI
TuiCalcMenuBoxSize(PTUI_MENU_INFO MenuInfo) TuiCalcMenuBoxSize(PTUI_MENU_INFO MenuInfo)
{ {
ULONG i; ULONG i;
@ -195,7 +195,7 @@ TuiCalcMenuBoxSize(PTUI_MENU_INFO MenuInfo)
} }
VOID VOID
WINAPI NTAPI
TuiDrawMenu(PTUI_MENU_INFO MenuInfo) TuiDrawMenu(PTUI_MENU_INFO MenuInfo)
{ {
ULONG i; ULONG i;
@ -262,7 +262,7 @@ TuiDrawMenu(PTUI_MENU_INFO MenuInfo)
} }
VOID VOID
WINAPI NTAPI
TuiDrawMenuBox(PTUI_MENU_INFO MenuInfo) TuiDrawMenuBox(PTUI_MENU_INFO MenuInfo)
{ {
CHAR MenuLineText[80]; CHAR MenuLineText[80];
@ -360,7 +360,7 @@ TuiDrawMenuBox(PTUI_MENU_INFO MenuInfo)
} }
VOID VOID
WINAPI NTAPI
TuiDrawMenuItem(PTUI_MENU_INFO MenuInfo, TuiDrawMenuItem(PTUI_MENU_INFO MenuInfo,
ULONG MenuItemNumber) ULONG MenuItemNumber)
{ {
@ -440,7 +440,7 @@ TuiDrawMenuItem(PTUI_MENU_INFO MenuInfo,
} }
ULONG ULONG
WINAPI NTAPI
TuiProcessMenuKeyboardEvent(PTUI_MENU_INFO MenuInfo, TuiProcessMenuKeyboardEvent(PTUI_MENU_INFO MenuInfo,
UiMenuKeyPressFilterCallback KeyPressFilter) UiMenuKeyPressFilterCallback KeyPressFilter)
{ {

View file

@ -45,21 +45,21 @@ UCHAR UiEditBoxBgColor = COLOR_BLACK; // Edit box text background color
CHAR UiTitleBoxTitleText[260] = "Boot Menu"; // Title box's title text CHAR UiTitleBoxTitleText[260] = "Boot Menu"; // Title box's title text
BOOL UserInterfaceUp = FALSE; // Tells us if the user interface is displayed BOOLEAN UserInterfaceUp = FALSE; // Tells us if the user interface is displayed
VIDEODISPLAYMODE UiDisplayMode = VideoTextMode; // Tells us if we are in text or graphics mode VIDEODISPLAYMODE UiDisplayMode = VideoTextMode; // Tells us if we are in text or graphics mode
BOOL UiUseSpecialEffects = FALSE; // Tells us if we should use fade effects BOOLEAN UiUseSpecialEffects = FALSE; // Tells us if we should use fade effects
BOOL UiDrawTime = TRUE; // Tells us if we should draw the time BOOLEAN UiDrawTime = TRUE; // Tells us if we should draw the time
BOOL UiMinimal = FALSE; // Tells us if we should use a minimal console-like UI BOOLEAN UiMinimal = FALSE; // Tells us if we should use a minimal console-like UI
BOOL UiCenterMenu = TRUE; // Tells us if we should use a centered or left-aligned menu BOOLEAN UiCenterMenu = TRUE; // Tells us if we should use a centered or left-aligned menu
BOOL UiMenuBox = TRUE; // Tells us if we shuld draw a box around the menu BOOLEAN UiMenuBox = TRUE; // Tells us if we shuld draw a box around the menu
CHAR UiTimeText[260] = "[Time Remaining: ] "; CHAR UiTimeText[260] = "[Time Remaining: ] ";
const CHAR UiMonthNames[12][15] = { "January ", "February ", "March ", "April ", "May ", "June ", "July ", "August ", "September ", "October ", "November ", "December " }; const CHAR UiMonthNames[12][15] = { "January ", "February ", "March ", "April ", "May ", "June ", "July ", "August ", "September ", "October ", "November ", "December " };
BOOL UiInitialize(BOOLEAN ShowGui) BOOLEAN UiInitialize(BOOLEAN ShowGui)
{ {
ULONG SectionId; ULONG SectionId;
CHAR DisplayModeText[260]; CHAR DisplayModeText[260];
@ -248,7 +248,7 @@ BOOL UiInitialize(BOOLEAN ShowGui)
return TRUE; return TRUE;
} }
BOOL SetupUiInitialize(VOID) BOOLEAN SetupUiInitialize(VOID)
{ {
CHAR DisplayModeText[260]; CHAR DisplayModeText[260];
@ -340,7 +340,7 @@ VOID UiDrawShadow(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom)
} }
} }
VOID UiDrawBox(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom, UCHAR VertStyle, UCHAR HorzStyle, BOOL Fill, BOOL Shadow, UCHAR Attr) VOID UiDrawBox(ULONG Left, ULONG Top, ULONG Right, ULONG Bottom, UCHAR VertStyle, UCHAR HorzStyle, BOOLEAN Fill, BOOLEAN Shadow, UCHAR Attr)
{ {
if (VideoTextMode == UiDisplayMode) if (VideoTextMode == UiDisplayMode)
{ {
@ -652,7 +652,7 @@ VOID UiTruncateStringEllipsis(PCHAR StringText, ULONG MaxChars)
} }
} }
BOOL UiDisplayMenu(PCSTR MenuItemList[], ULONG MenuItemCount, ULONG DefaultMenuItem, LONG MenuTimeOut, ULONG* SelectedMenuItem, BOOL CanEscape, UiMenuKeyPressFilterCallback KeyPressFilter) BOOLEAN UiDisplayMenu(PCSTR MenuItemList[], ULONG MenuItemCount, ULONG DefaultMenuItem, LONG MenuTimeOut, ULONG* SelectedMenuItem, BOOLEAN CanEscape, UiMenuKeyPressFilterCallback KeyPressFilter)
{ {
if (VideoTextMode == UiDisplayMode) if (VideoTextMode == UiDisplayMode)
{ {
@ -692,7 +692,7 @@ VOID UiFadeOut(VOID)
} }
} }
BOOL UiEditBox(PCSTR MessageText, PCHAR EditTextBuffer, ULONG Length) BOOLEAN UiEditBox(PCSTR MessageText, PCHAR EditTextBuffer, ULONG Length)
{ {
if (VideoTextMode == UiDisplayMode) if (VideoTextMode == UiDisplayMode)
{ {