| Commit message (Collapse) | Author | Files | Lines |
|
Prior to PR, Yuzu did not restore memory to RW-
on unmap of mirrored memory or unloading of NRO.
(In fact, in the NRO case, the memory was unmapped
instead of reprotected to --- on Load, so it was
actually lost entirely...)
This PR addresses that, and restores memory to RW-
as it should.
This fixes a crash in Super Smash Bros when creating
a World of Light save for the first time, and possibly
other games/circumstances.
|
|
These can be generified together by using a concept type to designate
them. This also has the benefit of not making copies of potentially very
large arrays.
|
|
Updates function tables based off information from SwitchBrew.
|
|
This doesn't modify instance state, so it can be made const.
|
|
The initial two words indicate a process ID. Also UnloadNro only
specifies one address, not two.
|
|
Makes it more evident that one is for actual code and one is for actual
data. Mutable and static are less than ideal terms here, because
read-only data is technically not mutable, but we were mapping it with
that label.
|
|
In all cases that these functions are needed, the VMManager can just be
retrieved and used instead of providing the same functions in Process'
interface.
This also makes it a little nicer dependency-wise, since it gets rid of
cases where the VMManager interface was being used, and then switched
over to using the interface for a Process instance. Instead, it makes
all accesses uniform and uses the VMManager instance for all necessary
tasks.
All the basic memory mapping functions did was forward to the Process'
VMManager instance anyways.
|
|
We don't need to specify all of the ARM interfaces explicitly.
|
|
The first word is just a padding byte, it's not an actual entry
instruction. Also renames the rest of the entries according to
SwitchBrew.
|
|
The padding after the magic signature value should be 12 bytes rather
than 28 bytes. The other 16 should be placed after the title ID pattern.
|
|
|
|
The separate enum isn't particularly necessary here, and the values can
just be directly put into the ResultCode instances, given the names are
also self-documenting here.
|
|
|
|
Includes actual unmapping and address error checking.
|
|
Includes NRO and BSS error checking, maximum loaded NRO check, NRR hash check, and proper remapping of BSS data.
|
|
Includes initialization check, proper address check, alignment check, and actual unloading of a loaded NRR.
|
|
Includes parameter error checking, hash enforcement, initialization check, and max NRR load check.
|
|
- This is an incomplete implementation. It was tested with Super Mario Party.
|
|
Adds the skeleton for the ldr-related services based off the information
provided on Switch Brew.
|