mirror of
https://github.com/LumaTeam/Luma3DS.git
synced 2026-02-22 01:44:38 +00:00
This commit adds all the changes made to the 3GX plugin loader fork of Luma3DS. The most important features are:
- Add 3GX plugin loader support. New service added to rosalina: plg:ldr
- Add svcControlProcess, svcControlMemoryUnsafe and improve svcMapProcessMemoryEx (breaking change)
- Allow applications to override certain configurations depending on their needs:
- Disable core2 thread redirection
- Disable game patching for the next app
- Force New 3DS speedup
- Force next application in a specific memory mode
- Block the opening of the Rosalina menu
- Add GDB commands to list all process handles and catch all SVC (latter is for IDA Pro as gdb client supports it)
- Other changes necessary for plugins to work properly. Please check changed files in this PR for more details.
---------
Co-authored-by: PabloMK7 <hackyglitch@gmail.com>
Co-authored-by: Nanquitas <nath.doidi@gmail.com>
Co-authored-by: TuxSH <1922548+TuxSH@users.noreply.github.com>
37 lines
660 B
ArmAsm
37 lines
660 B
ArmAsm
.section .data
|
|
.balign 4
|
|
.arm
|
|
|
|
.global gamePatchFunc
|
|
.type gamePatchFunc, %function
|
|
gamePatchFunc:
|
|
stmfd sp!, {r0-r12}
|
|
mrs r0, cpsr
|
|
stmfd sp!, {r0}
|
|
adr r0, g_savedGameInstr
|
|
ldr r1, =0x00100000
|
|
ldr r2, [r0]
|
|
str r2, [r1]
|
|
ldr r2, [r0, #4]
|
|
str r2, [r1, #4]
|
|
svc 0x92
|
|
svc 0x94
|
|
|
|
startplugin:
|
|
adr r0, g_savedGameInstr
|
|
push {r0}
|
|
ldr r5, =0x07000100
|
|
blx r5
|
|
add sp, sp, #4
|
|
|
|
exit:
|
|
ldmfd sp!, {r0}
|
|
msr cpsr, r0
|
|
ldmfd sp!, {r0-r12}
|
|
ldr lr, =0x00100000
|
|
mov pc, lr
|
|
|
|
.global g_savedGameInstr
|
|
g_savedGameInstr:
|
|
.word 0, 0
|