Author: sserapion
Date: Wed Dec 30 08:53:02 2009
New Revision: 44807
URL:
http://svn.reactos.org/svn/reactos?rev=44807&view=rev
Log:
Add definitions for the x86bios emulator.
http://www.geoffchappell.com/viewer.htm?doc=studies/windows/km/hal/api/x86b…
Added:
branches/ros-amd64-bringup/reactos/hal/halamd64/generic/x86bios.c (with props)
Modified:
branches/ros-amd64-bringup/reactos/hal/hal/hal.c
branches/ros-amd64-bringup/reactos/hal/hal/hal.rbuild
branches/ros-amd64-bringup/reactos/hal/hal/hal_amd64.def
branches/ros-amd64-bringup/reactos/hal/halamd64/generic/generic.rbuild
branches/ros-amd64-bringup/reactos/hal/halamd64/generic/misc.c
branches/ros-amd64-bringup/reactos/include/ndk/halfuncs.h
branches/ros-amd64-bringup/reactos/include/ndk/haltypes.h
Modified: branches/ros-amd64-bringup/reactos/hal/hal/hal.c
URL:
http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/hal/h…
==============================================================================
--- branches/ros-amd64-bringup/reactos/hal/hal/hal.c [iso-8859-1] (original)
+++ branches/ros-amd64-bringup/reactos/hal/hal/hal.c [iso-8859-1] Wed Dec 30 08:53:02
2009
@@ -172,6 +172,13 @@
return NULL;
}
+VOID
+NTAPI
+HalBugCheckSystem (PVOID ErrorRecord)
+{
+ UNIMPLEMENTED;
+}
+
NTSTATUS
NTAPI
@@ -248,7 +255,7 @@
NTAPI
HalEndSystemInterrupt(
KIRQL Irql,
- ULONG Unknown2)
+ ULONG Vector)
{
UNIMPLEMENTED;
}
@@ -1106,4 +1113,61 @@
return 0;
}
+#ifdef _X86BIOS_
+NTSTATUS
+NTAPI
+x86BiosAllocateBuffer (
+ ULONG *Size,
+ USHORT *Segment,
+ USHORT *Offset)
+{
+ UNIMPLEMENTED;
+ return STATUS_UNSUCCESSFUL;;
+
+}
+
+BOOLEAN
+NTAPI
+x86BiosCall (
+ ULONG InterruptNumber,
+ X86_BIOS_REGISTERS *Registers)
+{
+ UNIMPLEMENTED;
+ return FALSE;
+}
+
+NTSTATUS
+NTAPI
+x86BiosFreeBuffer (
+ USHORT Segment,
+ USHORT Offset)
+{
+ UNIMPLEMENTED;
+ return STATUS_UNSUCCESSFUL;;
+}
+
+NTSTATUS
+x86BiosReadMemory (
+ USHORT Segment,
+ USHORT Offset,
+ PVOID Buffer,
+ ULONG Size)
+{
+ UNIMPLEMENTED;
+ return STATUS_UNSUCCESSFUL;;
+}
+
+NTSTATUS
+NTAPI
+x86BiosWriteMemory (
+ USHORT Segment,
+ USHORT Offset,
+ PVOID Buffer,
+ ULONG Size)
+{
+ UNIMPLEMENTED;
+ return STATUS_UNSUCCESSFUL;;
+}
+#endif
+
/* EOF */
Modified: branches/ros-amd64-bringup/reactos/hal/hal/hal.rbuild
URL:
http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/hal/h…
==============================================================================
--- branches/ros-amd64-bringup/reactos/hal/hal/hal.rbuild [iso-8859-1] (original)
+++ branches/ros-amd64-bringup/reactos/hal/hal/hal.rbuild [iso-8859-1] Wed Dec 30 08:53:02
2009
@@ -36,6 +36,7 @@
<include base="ntoskrnl">include</include>
<library>ntoskrnl</library>
<define name="_NTHAL_" />
+ <define name="_X86BIOS_" />
<file>hal.c</file>
<file>hal.rc</file>
</module>
Modified: branches/ros-amd64-bringup/reactos/hal/hal/hal_amd64.def
URL:
http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/hal/h…
==============================================================================
--- branches/ros-amd64-bringup/reactos/hal/hal/hal_amd64.def [iso-8859-1] (original)
+++ branches/ros-amd64-bringup/reactos/hal/hal/hal_amd64.def [iso-8859-1] Wed Dec 30
08:53:02 2009
@@ -9,8 +9,9 @@
HalAllocateAdapterChannel
HalAllocateCommonBuffer
HalAllocateCrashDumpRegisters
+;HalAllocateHardwareCounters
HalAssignSlotResources
-;HalBugCheckSystem
+HalBugCheckSystem
HalCalibratePerformanceCounter
HalClearSoftwareInterrupt
;HalConvertDeviceIdtToIrql
@@ -21,6 +22,7 @@
;HalEnumerateProcessors
HalFlushCommonBuffer
HalFreeCommonBuffer
+;HalFreeHardwareCounters
HalGetAdapter
HalGetBusData
HalGetBusDataByOffset
@@ -28,6 +30,7 @@
;HalGetEnvironmentVariableEx
;HalGetInterruptTargetInformation
HalGetInterruptVector
+;HalGetMemoryCachingRequirements
;HalGetMessageRoutingInfo
;HalGetProcessorIdByNtNumber
;HalGetVectorInput
@@ -39,6 +42,8 @@
HalInitializeProcessor
;HalIsHyperThreadingEnabled
HalMakeBeep
+;HalMcUpdateReadPCIConfig
+;HalPerformEndOfInterrupt
HalProcessorIdle
HalQueryDisplayParameters
;HalQueryEnvironmentVariableInfoEx
@@ -48,6 +53,8 @@
;HalRegisterDynamicProcessor
;HalRegisterErrataCallbacks
HalReportResourceUsage
+;HalRequestClockInterrupt
+;HalRequestDeferredRecoveryServiceInterrupt
HalRequestIpi
HalRequestSoftwareInterrupt
HalReturnToFirmware
@@ -67,7 +74,7 @@
HalStopProfileInterrupt
HalSystemVectorDispatchEntry
HalTranslateBusAddress
-IoAssignDriveLetters
+IoAssignDriveLetters ;not present in win7
IoFlushAdapterBuffers
IoFreeAdapterChannel
IoFreeMapRegisters
@@ -79,8 +86,8 @@
KeFlushWriteBuffer
KeQueryPerformanceCounter
KeStallExecutionProcessor
-;x86BiosAllocateBuffer
-;x86BiosCall
-;x86BiosFreeBuffer
-;x86BiosReadMemory
-;x86BiosWriteMemory
+x86BiosAllocateBuffer
+x86BiosCall
+x86BiosFreeBuffer
+x86BiosReadMemory
+x86BiosWriteMemory
Modified: branches/ros-amd64-bringup/reactos/hal/halamd64/generic/generic.rbuild
URL:
http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/hal/h…
==============================================================================
--- branches/ros-amd64-bringup/reactos/hal/halamd64/generic/generic.rbuild [iso-8859-1]
(original)
+++ branches/ros-amd64-bringup/reactos/hal/halamd64/generic/generic.rbuild [iso-8859-1]
Wed Dec 30 08:53:02 2009
@@ -6,6 +6,7 @@
<include base="ntoskrnl">include</include>
<define name="_DISABLE_TIDENTS" />
<define name="_NTHAL_" />
+ <define name="_X86BIOS_" />
<file>halinit.c</file>
<file>irq.S</file>
<file>misc.c</file>
@@ -13,6 +14,7 @@
<file>systimer.S</file>
<file>usage.c</file>
<file>pic.c</file>
+ <file>x86bios.c</file>
<pch>../include/hal.h</pch>
</module>
</group>
Modified: branches/ros-amd64-bringup/reactos/hal/halamd64/generic/misc.c
URL:
http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/hal/h…
==============================================================================
--- branches/ros-amd64-bringup/reactos/hal/halamd64/generic/misc.c [iso-8859-1]
(original)
+++ branches/ros-amd64-bringup/reactos/hal/halamd64/generic/misc.c [iso-8859-1] Wed Dec 30
08:53:02 2009
@@ -96,6 +96,14 @@
return FALSE;
}
+VOID
+NTAPI
+HalBugCheckSystem (PVOID ErrorRecord)
+{
+ UNIMPLEMENTED;
+}
+
+
/*
* @implemented
*/
@@ -126,3 +134,4 @@
Result.QuadPart = __rdtsc();
return Result;
}
+
Added: branches/ros-amd64-bringup/reactos/hal/halamd64/generic/x86bios.c
URL:
http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/hal/h…
==============================================================================
--- branches/ros-amd64-bringup/reactos/hal/halamd64/generic/x86bios.c (added)
+++ branches/ros-amd64-bringup/reactos/hal/halamd64/generic/x86bios.c [iso-8859-1] Wed Dec
30 08:53:02 2009
@@ -1,0 +1,69 @@
+/*
+ * PROJECT: ReactOS HAL
+ * LICENSE: See COPYING in the top level directory
+ * FILE: hal/halamd64/generic/x86bios.c
+ * PURPOSE:
+ * PROGRAMMERS:
+ */
+
+/* INCLUDES ******************************************************************/
+
+#include <hal.h>
+//#define NDEBUG
+#include <debug.h>
+
+NTSTATUS
+NTAPI
+x86BiosAllocateBuffer (
+ ULONG *Size,
+ USHORT *Segment,
+ USHORT *Offset)
+{
+ UNIMPLEMENTED;
+ return STATUS_UNSUCCESSFUL;;
+
+}
+
+BOOLEAN
+NTAPI
+x86BiosCall (
+ ULONG InterruptNumber,
+ X86_BIOS_REGISTERS *Registers)
+{
+ UNIMPLEMENTED;
+ return FALSE;
+}
+
+NTSTATUS
+NTAPI
+x86BiosFreeBuffer (
+ USHORT Segment,
+ USHORT Offset)
+{
+ UNIMPLEMENTED;
+ return STATUS_UNSUCCESSFUL;;
+}
+
+NTSTATUS
+x86BiosReadMemory (
+ USHORT Segment,
+ USHORT Offset,
+ PVOID Buffer,
+ ULONG Size)
+{
+ UNIMPLEMENTED;
+ return STATUS_UNSUCCESSFUL;;
+}
+
+NTSTATUS
+NTAPI
+x86BiosWriteMemory (
+ USHORT Segment,
+ USHORT Offset,
+ PVOID Buffer,
+ ULONG Size)
+{
+ UNIMPLEMENTED;
+ return STATUS_UNSUCCESSFUL;;
+}
+
Propchange: branches/ros-amd64-bringup/reactos/hal/halamd64/generic/x86bios.c
------------------------------------------------------------------------------
svn:eol-style = native
Modified: branches/ros-amd64-bringup/reactos/include/ndk/halfuncs.h
URL:
http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/inclu…
==============================================================================
--- branches/ros-amd64-bringup/reactos/include/ndk/halfuncs.h [iso-8859-1] (original)
+++ branches/ros-amd64-bringup/reactos/include/ndk/halfuncs.h [iso-8859-1] Wed Dec 30
08:53:02 2009
@@ -274,5 +274,47 @@
IN PTIME_FIELDS RtcTime
);
-#endif
-#endif
+// x86 BIOS emulator
+#ifdef _X86BIOS_
+NTSTATUS
+NTAPI
+x86BiosAllocateBuffer (
+ ULONG *Size,
+ USHORT *Segment,
+ USHORT *Offset
+);
+
+BOOLEAN
+NTAPI
+x86BiosCall (
+ ULONG InterruptNumber,
+ X86_BIOS_REGISTERS *Registers
+);
+
+NTSTATUS
+NTAPI
+x86BiosFreeBuffer (
+ USHORT Segment,
+ USHORT Offset
+);
+
+NTSTATUS
+x86BiosReadMemory (
+ USHORT Segment,
+ USHORT Offset,
+ PVOID Buffer,
+ ULONG Size
+);
+
+NTSTATUS
+NTAPI
+x86BiosWriteMemory (
+ USHORT Segment,
+ USHORT Offset,
+ PVOID Buffer,
+ ULONG Size
+);
+#endif
+
+#endif
+#endif
Modified: branches/ros-amd64-bringup/reactos/include/ndk/haltypes.h
URL:
http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/inclu…
==============================================================================
--- branches/ros-amd64-bringup/reactos/include/ndk/haltypes.h [iso-8859-1] (original)
+++ branches/ros-amd64-bringup/reactos/include/ndk/haltypes.h [iso-8859-1] Wed Dec 30
08:53:02 2009
@@ -246,6 +246,19 @@
PVOID Spare8;
} BUS_HANDLER;
+#ifdef _X86BIOS_
+typedef struct _X86_BIOS_REGISTERS {
+ ULONG Eax;
+ ULONG Ecx;
+ ULONG Edx;
+ ULONG Ebx;
+ ULONG Ebp;
+ ULONG Esi;
+ ULONG Edi;
+ USHORT SegDs;
+ USHORT SegEs;
+} X86_BIOS_REGISTERS, *PX86_BIOS_REGISTERS;
+#endif
//
// HAL Chip Hacks
//