ReactOS  0.4.14-dev-554-g2f8d847
archmach.c File Reference
#include <freeldr.h>
Include dependency graph for archmach.c:

Go to the source code of this file.

Functions

VOID MachInit (const char *CmdLine)
 

Function Documentation

◆ MachInit()

VOID MachInit ( const char CmdLine)

Definition at line 22 of file archmach.c.

23 {
24  ULONG PciId;
25 
26  memset(&MachVtbl, 0, sizeof(MACHVTBL));
27 
28  /* Check for Xbox by identifying device at PCI 0:0:0, if it's
29  * 0x10de/0x02a5 then we're running on an Xbox */
30  WRITE_PORT_ULONG((ULONG*)0xcf8, CONFIG_CMD(0, 0, 0));
31  PciId = READ_PORT_ULONG((ULONG*)0xcfc);
32  if (PciId == 0x02a510de)
33  {
35  }
36  else
37  {
39  }
40 
42 }
VOID HalpCalibrateStallExecution(VOID)
Definition: hardware.c:100
ULONG NTAPI READ_PORT_ULONG(IN PULONG Port)
Definition: portio.c:70
VOID NTAPI WRITE_PORT_ULONG(IN PULONG Port, IN ULONG Value)
Definition: portio.c:123
CHAR CmdLine[MAX_PATH]
Definition: mach.c:34
VOID XboxMachInit(const char *CmdLine)
Definition: machxbox.c:256
VOID PcMachInit(const char *CmdLine)
Definition: machpc.c:1407
MACHVTBL MachVtbl
Definition: arcemul.c:21
#define CONFIG_CMD(bus, dev_fn, where)
Definition: hardware.h:23
unsigned int ULONG
Definition: retypes.h:1
#define memset(x, y, z)
Definition: compat.h:39