ReactOS  0.4.15-dev-3302-ga37d9a4
halinit.c
Go to the documentation of this file.
1 /*
2  * PROJECT: Xbox HAL
3  * LICENSE: GPL-2.0-or-later (https://spdx.org/licenses/GPL-2.0-or-later)
4  * PURPOSE: Initialize the x86 HAL
5  * COPYRIGHT: Copyright 1998 David Welch (welch@cwcom.net)
6  */
7 
8 /* INCLUDES *****************************************************************/
9 
10 #include "halxbox.h"
11 
12 #define NDEBUG
13 #include <debug.h>
14 
15 /* FUNCTIONS ****************************************************************/
16 
17 VOID
18 NTAPI
20  IN ULONG ProcessorNumber,
21  IN PLOADER_PARAMETER_BLOCK LoaderBlock)
22 {
23  /* Set default IDR */
24  KeGetPcr()->IDR = 0xFFFFFFFF & ~(1 << PIC_CASCADE_IRQ);
25 }
26 
27 VOID
29 {
30  /* Initialize Xbox-specific disk hacks */
32 }
33 
34 VOID
36 {
37  /* Enable timer interrupt handler */
39  0,
43  Latched);
44 
45  /* Enable RTC interrupt handler */
47  0,
51  Latched);
52 
53  /* Initialize DMA. NT does this in Phase 0 */
54  HalpInitDma();
55 }
56 
57 /* EOF */
#define PIC_RTC_IRQ
Definition: halhw.h:157
#define IN
Definition: typedefs.h:39
#define PRIMARY_VECTOR_BASE
Definition: halp.h:16
VOID HalpXboxInitPartIo(VOID)
Definition: part_xbox.c:331
#define KeGetPcr()
Definition: ke.h:26
NTSTATUS(* NTAPI)(IN PFILE_FULL_EA_INFORMATION EaBuffer, IN ULONG EaLength, OUT PULONG ErrorOffset)
Definition: IoEaTest.cpp:117
VOID HalpProfileInterrupt(VOID)
#define PIC_CASCADE_IRQ
Definition: halhw.h:156
VOID HalpInitDma(VOID)
Definition: dma.c:153
VOID NTAPI HalpEnableInterruptHandler(IN UCHAR Flags, IN ULONG BusVector, IN ULONG SystemVector, IN KIRQL Irql, IN PVOID Handler, IN KINTERRUPT_MODE Mode)
Definition: usage.c:49
VOID HalpInitPhase1(VOID)
Definition: halinit.c:54
VOID HalpInitPhase0(IN PLOADER_PARAMETER_BLOCK LoaderBlock)
Definition: halinit.c:38
#define CLOCK2_LEVEL
Definition: env_spec_w32.h:700
VOID HalpClockInterrupt(VOID)
Definition: timer.c:30
#define PIC_TIMER_IRQ
Definition: halhw.h:155
#define PROFILE_LEVEL
Definition: env_spec_w32.h:698
unsigned int ULONG
Definition: retypes.h:1
#define IDT_DEVICE
Definition: halp.h:22
VOID NTAPI HalpInitProcessor(IN ULONG ProcessorNumber, IN PLOADER_PARAMETER_BLOCK LoaderBlock)
Definition: halinit.c:23