mirror of
https://github.com/d0k3/GodMode9.git
synced 2025-06-26 05:32:47 +00:00
- maps a regular ARM-style exception vector table instead of using the bootrom vector redirection features a ton of bugs because I'm missing something, it actually manages to boot fb3DS v1.2 and BAX fine, but fails to boot itself
16 lines
440 B
C
Executable File
16 lines
440 B
C
Executable File
#pragma once
|
|
|
|
#define DEF_SECT_(n) extern u32 __##n##_pa, __##n##_va, __##n##_len; static const u32 n##_pa = (u32)&__##n##_pa, n##_va = (u32)&__##n##_va;
|
|
DEF_SECT_(vector)
|
|
DEF_SECT_(text)
|
|
DEF_SECT_(data)
|
|
DEF_SECT_(rodata)
|
|
DEF_SECT_(bss)
|
|
#undef DEF_SECT_
|
|
|
|
#define SECTION_VA(n) n##_va
|
|
#define SECTION_PA(n) n##_pa
|
|
#define SECTION_LEN(n) ((u32)&__##n##_len)
|
|
|
|
#define SECTION_TRI(n) SECTION_VA(n), SECTION_PA(n), SECTION_LEN(n)
|