ReactOS 0.4.16-dev-106-g10b08aa
halstub.c
Go to the documentation of this file.
1/*
2 * PROJECT: ReactOS Kernel
3 * LICENSE: GPL - See COPYING in the top level directory
4 * FILE: boot/freeldr/freeldr/arch/i386/halstub.c
5 * PURPOSE: I/O Stub HAL Routines
6 * PROGRAMMERS: Alex Ionescu (alex.ionescu@reactos.org)
7 */
8
9/* INCLUDES ******************************************************************/
10
11#include <ntoskrnl.h>
12
13/* FUNCTIONS *****************************************************************/
14
22{
27}
28
32{
33 /* Return the vector */
34 return (UCHAR)Vector;
35}
36
37VOID
40{
41 /* Halt execution */
42 while (TRUE);
43}
44
45/* GLOBALS *******************************************************************/
46
48{
53 0,
73};
74
76{
97};
unsigned char BOOLEAN
LONG NTSTATUS
Definition: precomp.h:26
NTSTATUS FASTCALL xHalIoReadPartitionTable(IN PDEVICE_OBJECT DeviceObject, IN ULONG SectorSize, IN BOOLEAN ReturnRecognizedPartitions, OUT PDRIVE_LAYOUT_INFORMATION *PartitionBuffer)
Definition: halstub.c:17
HAL_PRIVATE_DISPATCH HalPrivateDispatchTable
Definition: halstub.c:75
UCHAR NTAPI xHalVectorToIDTEntry(IN ULONG Vector)
Definition: halstub.c:31
VOID NTAPI xHalHaltSystem(VOID)
Definition: halstub.c:39
HAL_DISPATCH HalDispatchTable
Definition: halstub.c:47
NTSTATUS FASTCALL IoReadPartitionTable(IN PDEVICE_OBJECT DeviceObject, IN ULONG SectorSize, IN BOOLEAN ReturnRecognizedPartitions, OUT PDRIVE_LAYOUT_INFORMATION *PartitionBuffer)
Definition: partition.c:495
#define NULL
Definition: types.h:112
#define TRUE
Definition: types.h:120
VOID(NTAPI * pHalLocateHiberRanges)(_In_ PVOID MemoryMap)
Definition: haltypes.h:86
#define HAL_PRIVATE_DISPATCH_VERSION
Definition: haltypes.h:166
VOID(NTAPI * pHalSetWakeAlarm)(_In_ ULONGLONG AlartTime, _In_ PTIME_FIELDS TimeFields)
Definition: haltypes.h:79
NTSTATUS(NTAPI * pHalAllocateMapRegisters)(_In_ PADAPTER_OBJECT AdapterObject, _In_ ULONG Unknown, _In_ ULONG Unknown2, PMAP_REGISTER_ENTRY Registers)
Definition: haltypes.h:92
PBUS_HANDLER(FASTCALL * pHalHandlerForConfigSpace)(_In_ BUS_DATA_TYPE ConfigSpace, _In_ ULONG BusNumber)
Definition: haltypes.h:47
NTSTATUS(NTAPI * pHalRegisterBusHandler)(_In_ INTERFACE_TYPE InterfaceType, _In_ BUS_DATA_TYPE ConfigSpace, _In_ ULONG BusNumber, _In_ INTERFACE_TYPE ParentInterfaceType, _In_ ULONG ParentBusNumber, _In_ ULONG ContextSize, _In_ PINSTALL_BUS_HANDLER InstallCallback, _Out_ PBUS_HANDLER *BusHandler)
Definition: haltypes.h:60
VOID(NTAPI * pHalSetWakeEnable)(_In_ BOOLEAN Enable)
Definition: haltypes.h:73
#define FASTCALL
Definition: nt_native.h:50
#define NTAPI
Definition: typedefs.h:36
#define IN
Definition: typedefs.h:39
uint32_t ULONG
Definition: typedefs.h:59
#define OUT
Definition: typedefs.h:40
_In_ PDEVICE_OBJECT DeviceObject
Definition: wdfdevice.h:2055
_In_ ULONG SectorSize
Definition: halfuncs.h:291
NTSTATUS(NTAPI * pHalQuerySystemInformation)(_In_ HAL_QUERY_INFORMATION_CLASS InformationClass, _In_ ULONG BufferSize, _Inout_updates_bytes_to_(BufferSize, *ReturnedLength) PVOID Buffer, _Out_ PULONG ReturnedLength)
Definition: haltypes.h:65
NTSTATUS(FASTCALL * pHalIoSetPartitionInformation)(_In_ PDEVICE_OBJECT DeviceObject, _In_ ULONG SectorSize, _In_ ULONG PartitionNumber, _In_ ULONG PartitionType)
Definition: haltypes.h:92
NTSTATUS(NTAPI * pHalAssignSlotResources)(_In_ PUNICODE_STRING RegistryPath, _In_opt_ PUNICODE_STRING DriverClassName, _In_ PDRIVER_OBJECT DriverObject, _In_ PDEVICE_OBJECT DeviceObject, _In_ INTERFACE_TYPE BusType, _In_ ULONG BusNumber, _In_ ULONG SlotNumber, _Inout_ PCM_RESOURCE_LIST *AllocatedResources)
Definition: haltypes.h:169
NTSTATUS(NTAPI * pHalGetInterruptTranslator)(_In_ INTERFACE_TYPE ParentInterfaceType, _In_ ULONG ParentBusNumber, _In_ INTERFACE_TYPE BridgeInterfaceType, _In_ USHORT Size, _In_ USHORT Version, _Out_ PTRANSLATOR_INTERFACE Translator, _Out_ PULONG BridgeBusNumber)
Definition: haltypes.h:134
NTSTATUS(NTAPI * pHalQueryBusSlots)(_In_ PBUS_HANDLER BusHandler, _In_ ULONG BufferSize, _Out_ PULONG SlotNumbers, _Out_ PULONG ReturnedLength)
Definition: haltypes.h:107
BOOLEAN(NTAPI * pHalTranslateBusAddress)(_In_ INTERFACE_TYPE InterfaceType, _In_ ULONG BusNumber, _In_ PHYSICAL_ADDRESS BusAddress, _Inout_ PULONG AddressSpace, _Out_ PPHYSICAL_ADDRESS TranslatedAddress)
Definition: haltypes.h:161
PVOID(NTAPI * pHalGetAcpiTable)(_In_ ULONG Signature, _In_opt_ PCSTR OemId, _In_opt_ PCSTR OemTableId)
Definition: haltypes.h:206
NTSTATUS(FASTCALL * pHalIoWritePartitionTable)(_In_ PDEVICE_OBJECT DeviceObject, _In_ ULONG SectorSize, _In_ ULONG SectorsPerTrack, _In_ ULONG NumberOfHeads, _In_ struct _DRIVE_LAYOUT_INFORMATION *PartitionBuffer)
Definition: haltypes.h:99
PBUS_HANDLER(FASTCALL * pHalHandlerForBus)(_In_ INTERFACE_TYPE InterfaceType, _In_ ULONG BusNumber)
Definition: haltypes.h:10
VOID(NTAPI * pHalSetPciErrorHandlerCallback)(_In_ PCI_ERROR_HANDLER_CALLBACK Callback)
Definition: haltypes.h:227
NTSTATUS(NTAPI * pHalMirrorVerify)(_In_ PHYSICAL_ADDRESS PhysicalAddress, _In_ LARGE_INTEGER NumberOfBytes)
Definition: haltypes.h:156
NTSTATUS(FASTCALL * pHalIoReadPartitionTable)(_In_ PDEVICE_OBJECT DeviceObject, _In_ ULONG SectorSize, _In_ BOOLEAN ReturnRecognizedPartitions, _Out_ struct _DRIVE_LAYOUT_INFORMATION **PartitionBuffer)
Definition: haltypes.h:85
BOOLEAN(NTAPI * pHalResetDisplay)(VOID)
Definition: haltypes.h:183
struct _DMA_ADAPTER *NTAPI * pHalGetDmaAdapter(_In_ PVOID Context, _In_ struct _DEVICE_DESCRIPTION *DeviceDescriptor, _Out_ PULONG NumberOfMapRegisters)
Definition: haltypes.h:128
VOID(FASTCALL * pHalExamineMBR)(_In_ PDEVICE_OBJECT DeviceObject, _In_ ULONG SectorSize, _In_ ULONG MBRTypeIdentifier, _Out_ PVOID *Buffer)
Definition: haltypes.h:78
UCHAR(NTAPI * pHalVectorToIDTEntry)(ULONG Vector)
Definition: haltypes.h:191
NTSTATUS(NTAPI * pHalMirrorPhysicalMemory)(_In_ PHYSICAL_ADDRESS PhysicalAddress, _In_ LARGE_INTEGER NumberOfBytes)
Definition: haltypes.h:151
NTSTATUS(NTAPI * pHalStartMirroring)(VOID)
Definition: haltypes.h:144
NTSTATUS(NTAPI * pHalSetSystemInformation)(_In_ HAL_SET_INFORMATION_CLASS InformationClass, _In_ ULONG BufferSize, _In_ PVOID Buffer)
Definition: haltypes.h:72
NTSTATUS(NTAPI * pHalEndMirroring)(_In_ ULONG PassNumber)
Definition: haltypes.h:147
#define HAL_DISPATCH_VERSION
Definition: haltypes.h:290
VOID(FASTCALL * pHalIoAssignDriveLetters)(_In_ struct _LOADER_PARAMETER_BLOCK *LoaderBlock, _In_ PSTRING NtDeviceName, _Out_ PUCHAR NtSystemPath, _Out_ PSTRING NtSystemPathString)
Definition: haltypes.h:232
VOID(NTAPI * pHalEndOfBoot)(VOID)
Definition: haltypes.h:203
NTSTATUS(NTAPI * pHalInitPnpDriver)(VOID)
Definition: haltypes.h:114
VOID(NTAPI * pHalHaltSystem)(VOID)
Definition: haltypes.h:180
VOID(FASTCALL * pHalReferenceBusHandler)(_In_ PBUS_HANDLER BusHandler)
Definition: haltypes.h:15
NTSTATUS(NTAPI * pHalInitPowerManagement)(_In_ PPM_DISPATCH_TABLE PmDriverDispatchTable, _Out_ PPM_DISPATCH_TABLE *PmHalDispatchTable)
Definition: haltypes.h:123
BOOLEAN(NTAPI * pHalFindBusAddressTranslation)(_In_ PHYSICAL_ADDRESS BusAddress, _Inout_ PULONG AddressSpace, _Out_ PPHYSICAL_ADDRESS TranslatedAddress, _Inout_ PULONG_PTR Context, _In_ BOOLEAN NextBus)
Definition: haltypes.h:195
_In_ ULONG _In_ BOOLEAN ReturnRecognizedPartitions
Definition: iofuncs.h:2051
_In_ ULONG _In_ BOOLEAN _Out_ struct _DRIVE_LAYOUT_INFORMATION ** PartitionBuffer
Definition: iofuncs.h:2052
PVOID(NTAPI * pKdMapPhysicalMemory64)(_In_ PHYSICAL_ADDRESS PhysicalAddress, _In_ ULONG NumberPages, _In_ BOOLEAN FlushCurrentTLB)
Definition: kdtypes.h:138
PVOID(NTAPI * pKdGetAcpiTablePhase0)(_In_ struct _LOADER_PARAMETER_BLOCK *LoaderBlock, _In_ ULONG Signature)
Definition: kdtypes.h:129
NTSTATUS(NTAPI * pKdReleasePciDeviceForDebugging)(_Inout_ PDEBUG_DEVICE_DESCRIPTOR PciDevice)
Definition: kdtypes.h:125
VOID(NTAPI * pKdUnmapVirtualAddress)(_In_ PVOID VirtualAddress, _In_ ULONG NumberPages, _In_ BOOLEAN FlushCurrentTLB)
Definition: kdtypes.h:144
NTSTATUS(NTAPI * pKdSetupPciDeviceForDebugging)(_In_opt_ PVOID LoaderBlock, _Inout_ PDEBUG_DEVICE_DESCRIPTOR PciDevice)
Definition: kdtypes.h:120
VOID(NTAPI * pKdCheckPowerButton)(VOID)
Definition: kdtypes.h:134
unsigned char UCHAR
Definition: xmlstorage.h:181