mirror of
https://github.com/Atmosphere-NX/Atmosphere.git
synced 2025-05-24 19:54:22 -04:00
os: remove ManagedHandle, refactor to use NativeHandle typename
This commit is contained in:
parent
a774833790
commit
6f76066d24
71 changed files with 473 additions and 397 deletions
|
@ -24,7 +24,7 @@ namespace ams::ro::impl {
|
|||
|
||||
}
|
||||
|
||||
Result MapNro(u64 *out_base_address, Handle process_handle, u64 nro_heap_address, u64 nro_heap_size, u64 bss_heap_address, u64 bss_heap_size) {
|
||||
Result MapNro(u64 *out_base_address, os::NativeHandle process_handle, u64 nro_heap_address, u64 nro_heap_size, u64 bss_heap_address, u64 bss_heap_size) {
|
||||
map::MappedCodeMemory nro_mcm(ResultInternalError{});
|
||||
map::MappedCodeMemory bss_mcm(ResultInternalError{});
|
||||
u64 base_address;
|
||||
|
@ -67,7 +67,7 @@ namespace ams::ro::impl {
|
|||
return ResultSuccess();
|
||||
}
|
||||
|
||||
Result SetNroPerms(Handle process_handle, u64 base_address, u64 rx_size, u64 ro_size, u64 rw_size) {
|
||||
Result SetNroPerms(os::NativeHandle process_handle, u64 base_address, u64 rx_size, u64 ro_size, u64 rw_size) {
|
||||
const u64 rx_offset = 0;
|
||||
const u64 ro_offset = rx_offset + rx_size;
|
||||
const u64 rw_offset = ro_offset + ro_size;
|
||||
|
@ -79,7 +79,7 @@ namespace ams::ro::impl {
|
|||
return ResultSuccess();
|
||||
}
|
||||
|
||||
Result UnmapNro(Handle process_handle, u64 base_address, u64 nro_heap_address, u64 bss_heap_address, u64 bss_heap_size, u64 code_size, u64 rw_size) {
|
||||
Result UnmapNro(os::NativeHandle process_handle, u64 base_address, u64 nro_heap_address, u64 bss_heap_address, u64 bss_heap_size, u64 code_size, u64 rw_size) {
|
||||
/* First, unmap bss. */
|
||||
if (bss_heap_size > 0) {
|
||||
R_TRY(svcUnmapProcessCodeMemory(process_handle, base_address + code_size + rw_size, bss_heap_address, bss_heap_size));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue