mgh: fix for default HDD DMA mode, that wasn't correctly set
[open-ps2-loader.git] / ee_core / include / ee_core.h
blobe2d6e56c612ae0892f87c5072d445b1f60d7406e
1 /*
2 Copyright 2009-2010, Ifcaro, jimmikaelkael & Polo
3 Copyright 2006-2008 Polo
4 Licenced under Academic Free License version 3.0
5 Review OpenUsbLd README & LICENSE files for further details.
7 Some parts of the code are taken from HD Project by Polo
8 */
10 #ifndef _LOADER_H_
11 #define _LOADER_H_
13 #include <tamtypes.h>
14 #include <kernel.h>
15 #include <stdio.h>
16 #include <iopheap.h>
17 #include <sifrpc.h>
18 #include <string.h>
19 #include <sbv_patches.h>
20 #include <smem.h>
21 #include <smod.h>
23 #ifdef __EESIO_DEBUG
24 #include <sio.h>
25 #define DPRINTF(args...) sio_printf(args)
26 #define DINIT() sio_init(38400, 0, 0, 0, 0)
27 #else
28 #define DPRINTF(args...) do { } while(0)
29 #define DINIT() do { } while(0)
30 #endif
32 u8 *g_buf;
34 extern int set_reg_hook;
35 extern int set_reg_disabled;
36 extern int iop_reboot_count;
38 extern int padOpen_hooked;
40 #define IPCONFIG_MAX_LEN 64
41 char g_ipconfig[IPCONFIG_MAX_LEN] __attribute__((aligned(64)));
42 int g_ipconfig_len;
43 char g_ps2_ip[16];
44 char g_ps2_netmask[16];
45 char g_ps2_gateway[16];
46 u32 g_compat_mask;
48 #define COMPAT_MODE_1 0x01
49 #define COMPAT_MODE_2 0x02
50 #define COMPAT_MODE_3 0x04
51 #define COMPAT_MODE_4 0x08
52 #define COMPAT_MODE_5 0x10
53 #define COMPAT_MODE_6 0x20
54 #define COMPAT_MODE_7 0x40
55 #define COMPAT_MODE_8 0x80
57 char GameID[16];
58 int GameMode;
59 #define USB_MODE 0
60 #define ETH_MODE 1
61 #define HDD_MODE 2
63 char ExitPath[32];
64 int USBDelay;
65 int HDDSpindown;
67 int DisableDebug;
68 #define GS_BGCOLOUR *((volatile unsigned long int*)0x120000E0)
70 extern void (*InitializeTLB)(void);
72 #endif