svc: fix query/insecure names

This commit is contained in:
Michael Scire 2023-11-01 10:17:58 -07:00 committed by fincs
parent bb0ae8ac74
commit 933c5a12f0
2 changed files with 8 additions and 8 deletions

View File

@ -41,7 +41,7 @@ typedef enum {
MemType_CodeReadOnly=0x14, ///< Mapped in kernel during \ref svcControlCodeMemory. MemType_CodeReadOnly=0x14, ///< Mapped in kernel during \ref svcControlCodeMemory.
MemType_CodeWritable=0x15, ///< Mapped in kernel during \ref svcControlCodeMemory. MemType_CodeWritable=0x15, ///< Mapped in kernel during \ref svcControlCodeMemory.
MemType_Coverage=0x16, ///< Not available. MemType_Coverage=0x16, ///< Not available.
MemType_Insecure=0x17, ///< Mapped in kernel during \ref svcMapInsecureMemory. MemType_Insecure=0x17, ///< Mapped in kernel during \ref svcMapInsecurePhysicalMemory.
} MemoryType; } MemoryType;
/// Memory state bitmasks. /// Memory state bitmasks.
@ -1118,14 +1118,14 @@ Result svcQueryPhysicalAddress(PhysicalMemoryInfo *out, u64 virtaddr);
* @warning This is a privileged syscall. Use \ref envIsSyscallHinted to check if it is available. * @warning This is a privileged syscall. Use \ref envIsSyscallHinted to check if it is available.
* @warning Only exists on [10.0.0+]. For older versions use \ref svcLegacyQueryIoMapping. * @warning Only exists on [10.0.0+]. For older versions use \ref svcLegacyQueryIoMapping.
*/ */
Result svcQueryIoMapping(u64* virtaddr, u64* out_size, u64 physaddr, u64 size); Result svcQueryMemoryMapping(u64* virtaddr, u64* out_size, u64 physaddr, u64 size);
/** /**
* @brief Returns a virtual address mapped to a given IO range. * @brief Returns a virtual address mapped to a given IO range.
* @return Result code. * @return Result code.
* @note Syscall number 0x55. * @note Syscall number 0x55.
* @warning This is a privileged syscall. Use \ref envIsSyscallHinted to check if it is available. * @warning This is a privileged syscall. Use \ref envIsSyscallHinted to check if it is available.
* @warning Only exists on [1.0.0-9.2.0]. For newer versions use \ref svcQueryIoMapping. * @warning Only exists on [1.0.0-9.2.0]. For newer versions use \ref svcQueryMemoryMapping.
*/ */
Result svcLegacyQueryIoMapping(u64* virtaddr, u64 physaddr, u64 size); Result svcLegacyQueryIoMapping(u64* virtaddr, u64 physaddr, u64 size);
@ -1580,13 +1580,13 @@ void svcCallSecureMonitor(SecmonArgs* regs);
* @return Result code. * @return Result code.
* @note Syscall number 0x90. * @note Syscall number 0x90.
*/ */
Result svcMapInsecureMemory(void *address, u64 size); Result svcMapInsecurePhysicalMemory(void *address, u64 size);
/** /**
* @brief Undoes the effects of \ref svcMapInsecureMemory. [15.0.0+] * @brief Undoes the effects of \ref svcMapInsecureMemory. [15.0.0+]
* @return Result code. * @return Result code.
* @note Syscall number 0x91. * @note Syscall number 0x91.
*/ */
Result svcUnmapInsecureMemory(void *address, u64 size); Result svcUnmapInsecurePhysicalMemory(void *address, u64 size);
///@} ///@}

View File

@ -514,7 +514,7 @@ SVC_BEGIN svcQueryPhysicalAddress
ret ret
SVC_END SVC_END
SVC_BEGIN svcQueryIoMapping SVC_BEGIN svcQueryMemoryMapping
stp x0, x1, [sp, #-16]! stp x0, x1, [sp, #-16]!
svc 0x55 svc 0x55
ldp x3, x4, [sp], #16 ldp x3, x4, [sp], #16
@ -799,12 +799,12 @@ SVC_BEGIN svcCallSecureMonitor
ret ret
SVC_END SVC_END
SVC_BEGIN svcMapInsecureMemory SVC_BEGIN svcMapInsecurePhysicalMemory
svc 0x90 svc 0x90
ret ret
SVC_END SVC_END
SVC_BEGIN svcUnmapInsecureMemory SVC_BEGIN svcUnmapInsecurePhysicalMemory
svc 0x91 svc 0x91
ret ret
SVC_END SVC_END