Changes

Jump to navigation Jump to search
429 bytes added ,  18:28, 6 November 2012
no edit summary
Line 274: Line 274:  
| QueryDebugProcessMemory(MemoryInfo*, PageInfo*, Handle, unsigned int)
 
| QueryDebugProcessMemory(MemoryInfo*, PageInfo*, Handle, unsigned int)
 
|-
 
|-
| 0x6a
+
| 0x6A
 
| ReadProcessMemory(void*, Handle, unsigned int, unsigned int)
 
| ReadProcessMemory(void*, Handle, unsigned int, unsigned int)
 
|-
 
|-
| 0x6b
+
| 0x6B
 
| WriteProcessMemory(Handle, void const*, unsigned int, unsigned int)
 
| WriteProcessMemory(Handle, void const*, unsigned int, unsigned int)
 
|-
 
|-
| 0x6c
+
| 0x6C
 
| SetHardwareBreakPoint(int, unsigned int, unsigned int)
 
| SetHardwareBreakPoint(int, unsigned int, unsigned int)
 
|-
 
|-
| 0x6d
+
| 0x6D
 
| GetDebugThreadParam(long long *, int *, nn::Handle, unsigned int, nn::dmnt::DebugThreadParam) (Disabled on regular kernel)
 
| GetDebugThreadParam(long long *, int *, nn::Handle, unsigned int, nn::dmnt::DebugThreadParam) (Disabled on regular kernel)
 
|-
 
|-
Line 290: Line 290:  
|-
 
|-
 
| 0x71
 
| 0x71
| (Handle KProcess, unsigned int StartAddr, unsigned int EndAddr)
+
| MapProcessMemory(Handle KProcess, unsigned int StartAddr, unsigned int EndAddr)
 
|-
 
|-
 
| 0x72
 
| 0x72
| (Handle KProcess, unsigned int StartAddr, unsigned int EndAddr)
+
| UnmapProcessMemory(Handle KProcess, unsigned int StartAddr, unsigned int EndAddr)
 
|-
 
|-
 
| 0x73
 
| 0x73
Line 316: Line 316:  
| ?
 
| ?
 
|-
 
|-
| 0x7a
+
| 0x7A
 
| DisableExecuteNever(unsigned int Addr, unsigned int size) (Stubbed for regular kernel)
 
| DisableExecuteNever(unsigned int Addr, unsigned int size) (Stubbed for regular kernel)
 
|-
 
|-
| 0x7c
+
| 0x7C
 
| ?
 
| ?
 
|-
 
|-
| 0x7d
+
| 0x7D
 
| ?
 
| ?
 
|}
 
|}
Line 328: Line 328:  
Calling svcBreak on retail will only terminate the process which called this SVC.
 
Calling svcBreak on retail will only terminate the process which called this SVC.
   −
ControlMemory and MapMemoryBlock can be used to map memory pages, these two SVCs only support mapping execute-never R/W pages. The input permissions parameter for these SVCs must be <=3, where value zero is used when un-mapping memory. Bitmask 0xf00 for ControlMemory parameter MemoryType is the memory-type, when this is zero the memory-type is loaded from the kernel flags stored in the exheader ARM11 kernel descriptors, for the process using the SVC. The low 8-bits are the type: 1 is for un-mapping memory, 3 for mapping memory. Addr1 is not used for type1 and type3.
+
ControlMemory and MapMemoryBlock can be used to map memory pages, these two SVCs only support mapping execute-never R/W pages. The input permissions parameter for these SVCs must be <=3, where value zero is used when un-mapping memory. Bitmask 0xf00 for ControlMemory parameter MemoryType is the memory-type, when this is zero the memory-type is loaded from the kernel flags stored in the exheader ARM11 kernel descriptors, for the process using the SVC. The low 8-bits are the type: 1 is for un-mapping memory, 3 for mapping memory. Addr1 is not used for type1 and type3. Address 0x08000000 for ControlMemory is used for mapping the heap.
 +
 
 +
MapProcessMemory maps RW memory starting at address 0x00100000 in the specified KProcess, at the specified StartAddr in the current process. MapProcessMemory then maps 0x08000000 in the specified process, to StartAddr+0x7f00000 in the current process. UnmapProcessMemory unmaps the memory which was mapped by MapProcessMemory.
    
DebugActiveProcess is used to attach to a process for debugging. This SVC can only be used when the target process' ARM11 descriptors stored in the exheader have the kernel flag for "Enable debug" set. Otherwise when that flag is clear, the kernel flags for the process using this SVC must have the "Force debug" flag set.
 
DebugActiveProcess is used to attach to a process for debugging. This SVC can only be used when the target process' ARM11 descriptors stored in the exheader have the kernel flag for "Enable debug" set. Otherwise when that flag is clear, the kernel flags for the process using this SVC must have the "Force debug" flag set.

Navigation menu