diff --git a/include/mem_map.h b/include/mem_map.h index bbafe36..d62a900 100644 --- a/include/mem_map.h +++ b/include/mem_map.h @@ -90,12 +90,14 @@ -#define PDN_REGS_BASE (IO_MEM_ARM9_ARM11 + 0x40000) -#define REG_PDN_MPCORE_CFG *((vu16*)(PDN_REGS_BASE + 0x0FFC)) +#define CFG_REGS_BASE (IO_MEM_ARM9_ONLY) +#define CFG_BOOTENV *((vu32*)(CFG_REGS_BASE + 0x10000)) +#define CFG_UNITINFO *((vu8* )(CFG_REGS_BASE + 0x10010)) -#define CFG_REGS_BASE (IO_MEM_ARM9_ONLY) -#define CFG_BOOTENV *((vu32*)(CFG_REGS_BASE + 0x10000)) -#define CFG_UNITINFO *((vu8* )(CFG_REGS_BASE + 0x10010)) +#define REG_PRNG ((vu32*)(IO_MEM_ARM9_ONLY + 0x11000)) + +#define REG_PDN_MPCORE_CFG *((vu16*)(IO_MEM_ARM9_ARM11 + 0x40000 + 0x0FFC)) + /* Custom mappings */ #ifdef ARM9 diff --git a/source/arm9/main.c b/source/arm9/main.c index aa2f4b8..8dba40b 100644 --- a/source/arm9/main.c +++ b/source/arm9/main.c @@ -309,9 +309,6 @@ uiSetVerboseMode(true); } -#define PRNG_REGS_BASE (IO_MEM_ARM9_ONLY + 0x11000) -#define REG_PRNG ((vu32*)(PRNG_REGS_BASE)) - u8 rng_get_byte() { u32 tmp = REG_PRNG[0];