mirror of
https://github.com/reactos/reactos.git
synced 2025-08-07 03:03:13 +00:00
Git conversion: Make reactos the root directory, move rosapps, rostests, wallpapers into modules, and delete rossubsys.
This commit is contained in:
parent
b94e2d8ca0
commit
c2c66aff7d
24198 changed files with 0 additions and 37285 deletions
70
boot/environ/lib/io/io.c
Normal file
70
boot/environ/lib/io/io.c
Normal file
|
@ -0,0 +1,70 @@
|
|||
/*
|
||||
* COPYRIGHT: See COPYING.ARM in the top level directory
|
||||
* PROJECT: ReactOS UEFI Boot Library
|
||||
* FILE: boot/environ/lib/io/io.c
|
||||
* PURPOSE: Boot Library I/O Management Routines
|
||||
* PROGRAMMER: Alex Ionescu (alex.ionescu@reactos.org)
|
||||
*/
|
||||
|
||||
/* INCLUDES ******************************************************************/
|
||||
|
||||
#include "bl.h"
|
||||
|
||||
/* DATA VARIABLES ************************************************************/
|
||||
|
||||
ULONG IoMgrRoutineEntries;
|
||||
PVOID* IoMgrDestroyRoutineTable;
|
||||
|
||||
/* FUNCTIONS *****************************************************************/
|
||||
|
||||
NTSTATUS
|
||||
BlpIoRegisterDestroyRoutine (
|
||||
_In_ PBL_IO_DESTROY_ROUTINE DestroyRoutine
|
||||
)
|
||||
{
|
||||
ULONG Id;
|
||||
|
||||
return BlTblSetEntry(&IoMgrDestroyRoutineTable,
|
||||
&IoMgrRoutineEntries,
|
||||
DestroyRoutine,
|
||||
&Id,
|
||||
TblDoNotPurgeEntry);
|
||||
}
|
||||
|
||||
NTSTATUS
|
||||
BlpIoInitialize (
|
||||
VOID
|
||||
)
|
||||
{
|
||||
NTSTATUS Status;
|
||||
ULONG Size;
|
||||
|
||||
/* Allocate the I/O table */
|
||||
IoMgrRoutineEntries = 4;
|
||||
Size = IoMgrRoutineEntries * sizeof(PVOID);
|
||||
IoMgrDestroyRoutineTable = BlMmAllocateHeap(Size);
|
||||
if (IoMgrDestroyRoutineTable)
|
||||
{
|
||||
/* Zero it out */
|
||||
RtlZeroMemory(IoMgrDestroyRoutineTable, Size);
|
||||
|
||||
/* Initialize the device manager */
|
||||
Status = BlpDeviceInitialize();
|
||||
|
||||
/* Initialize the file manager */
|
||||
if (NT_SUCCESS(Status))
|
||||
{
|
||||
Status = BlpFileInitialize();
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
/* No memory */
|
||||
Status = STATUS_NO_MEMORY;
|
||||
}
|
||||
|
||||
/* Return initialization status */
|
||||
return Status;
|
||||
}
|
||||
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue