Editing LV2 Functions and Syscalls
Jump to navigation
Jump to search
The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then publish the changes below to finish undoing the edit.
Latest revision | Your text | ||
Line 37: | Line 37: | ||
int64_t modres; | int64_t modres; | ||
uint64_t pe_func; //casted to sys_prx_entry_pe_t (see sys/prx.h) | uint64_t pe_func; //casted to sys_prx_entry_pe_t (see sys/prx.h) | ||
}; | }; | ||
</source> | </source> | ||
Line 374: | Line 362: | ||
=== LV2 Syscalls === | === LV2 Syscalls === | ||
{| class="wikitable | {| class="wikitable sortable" | ||
|- | |- | ||
! Dec | ! Dec | ||
! Hex | ! Hex | ||
! style="width: | ! style="width:100px" | <abbr title="Firmware Type Specific (CEX,DEX,..)">fw_type</abbr> | ||
! <abbr title="Additional Settings/Flags required (Control Flags,Product Mode,..)">needed_flags</abbr> | ! <abbr title="Additional Settings/Flags required (Control Flags,Product Mode,..)">needed_flags</abbr> | ||
! Name | ! Name | ||
Line 987: | Line 975: | ||
| | | | ||
| _sys_lwmutex_create | | _sys_lwmutex_create | ||
| int _sys_lwmutex_create( | | int _sys_lwmutex_create(sys_lwmutex_t *lwmutex, sys_lwmutex_attribute_t *attr) | ||
|- | |- | ||
| 96 | | 96 | ||
Line 994: | Line 982: | ||
| | | | ||
| _sys_lwmutex_destroy | | _sys_lwmutex_destroy | ||
| int _sys_lwmutex_destroy( | | int _sys_lwmutex_destroy(sys_lwmutex_t *lwmutex) | ||
|- | |- | ||
| 97 | | 97 | ||
Line 1,001: | Line 989: | ||
| | | | ||
| _sys_lwmutex_lock | | _sys_lwmutex_lock | ||
| int _sys_lwmutex_lock( | | int _sys_lwmutex_lock(sys_lwmutex_t *lwmutex, usecond_t timeout) | ||
|- | |- | ||
| 98 | | 98 | ||
Line 1,008: | Line 996: | ||
| | | | ||
| _sys_lwmutex_unlock | | _sys_lwmutex_unlock | ||
| int _sys_lwmutex_unlock( | | int _sys_lwmutex_unlock(sys_lwmutex_t *lwmutex) | ||
|- | |- | ||
| 99 | | 99 | ||
Line 1,015: | Line 1,003: | ||
| | | | ||
| _sys_lwmutex_trylock | | _sys_lwmutex_trylock | ||
| int _sys_lwmutex_trylock( | | int _sys_lwmutex_trylock(sys_lwmutex_t *lwmutex) | ||
|- | |- | ||
! colspan="6" id="sys_mutex Syscalls"|[[#sys_mutex Syscalls]] (100-104) | ! colspan="6" id="sys_mutex Syscalls"|[[#sys_mutex Syscalls]] (100-104) | ||
Line 1,105: | Line 1,093: | ||
| | | | ||
| _sys_lwcond_create | | _sys_lwcond_create | ||
| int _sys_lwcond_create( | | int _sys_lwcond_create(sys_lwcond_t *lwcond, sys_lwmutex_t *lwmutex, sys_lwcond_attribute_t *attr) | ||
|- | |- | ||
| 112 | | 112 | ||
Line 1,112: | Line 1,100: | ||
| | | | ||
| _sys_lwcond_destroy | | _sys_lwcond_destroy | ||
| int _sys_lwcond_destroy( | | int _sys_lwcond_destroy(sys_lwcond_t *lwcond) | ||
|- | |- | ||
| 113 | | 113 | ||
Line 1,119: | Line 1,107: | ||
| | | | ||
| _sys_lwcond_queue_wait | | _sys_lwcond_queue_wait | ||
| int _sys_lwcond_queue_wait( | | int _sys_lwcond_queue_wait(sys_lwcond_t lwcond, sys_lwmutex_t lwmutex, uint64_t timeout) | ||
|- | |- | ||
! colspan="6" id="sys_semaphore Syscalls"|[[#sys_semaphore Syscalls]] (90-94+114) | ! colspan="6" id="sys_semaphore Syscalls"|[[#sys_semaphore Syscalls]] (90-94+114) | ||
Line 1,135: | Line 1,123: | ||
| | | | ||
| _sys_lwcond_signal | | _sys_lwcond_signal | ||
| int _sys_lwcond_signal( | | int _sys_lwcond_signal(sys_lwcond_t lwcond, sys_lwmutex_t lwmutex, sys_ppu_thread_t ppu_thread_id, uint32_t mode) | ||
|- | |- | ||
| 116 | | 116 | ||
Line 1,142: | Line 1,130: | ||
| | | | ||
| _sys_lwcond_signal_all | | _sys_lwcond_signal_all | ||
| int _sys_lwcond_signal_all( | | int _sys_lwcond_signal_all(sys_lwcond_t lwcond, sys_lwmutex_t lwmutex, uint32_t mode) | ||
|- | |- | ||
| 117 | | 117 | ||
Line 1,149: | Line 1,137: | ||
| | | | ||
| _sys_lwmutex_unlock2 | | _sys_lwmutex_unlock2 | ||
| int _sys_lwmutex_unlock2( | | int _sys_lwmutex_unlock2(sys_lwmutex_t lwmutex) | ||
Sets a different "unlocked" flag than _sys_lwmutex_unlock. | Sets a different "unlocked" flag than _sys_lwmutex_unlock. | ||
|- | |- | ||
Line 1,966: | Line 1,954: | ||
| | | | ||
| sys_spu_thread_group_get_cooperative_information | | sys_spu_thread_group_get_cooperative_information | ||
| int sys_spu_thread_group_get_cooperative_information(sys_spu_thread_group_t id, sys_spu_thread_group_cooperative_info_t* info) | | int sys_spu_thread_group_get_cooperative_information( sys_spu_thread_group_t id, sys_spu_thread_group_cooperative_info_t* info) | ||
Only allowed for COOPERATE_WITH_SYSTEM spu thread group types. | Only allowed for COOPERATE_WITH_SYSTEM spu thread group types. | ||
|- | |- | ||
Line 2,527: | Line 2,515: | ||
| {{Root}} | | {{Root}} | ||
| sys_game_get_temperature | | sys_game_get_temperature | ||
| int sys_game_get_temperature( | | int sys_game_get_temperature(0=CELL/1=RSX,uint32_t *temperature) ( HV System Manager access - ServiceID 13 (TEMPERATURE)) | ||
2nd Byte conversion: r.shift (second_byte * 0x64 ) by 8<br> | 2nd Byte conversion: r.shift (second_byte * 0x64 ) by 8<br> | ||
Example: 195 = 0xC3 -> 0xC3 * 0x64 -> 0x4C2C ->> shift -> 0x4C -> XX.76°C | Example: 195 = 0xC3 -> 0xC3 * 0x64 -> 0x4C2C ->> shift -> 0x4C -> XX.76°C | ||
|- | |- | ||
| 384 | | 384 | ||
Line 2,542: | Line 2,524: | ||
| {{Root}} | | {{Root}} | ||
| sys_sm_get_tzpb | | sys_sm_get_tzpb | ||
| 1 Param: syscall(384,uint64_t *tzpb); (uint8_t [0x20]) Get | | 1 Param: syscall(384,uint64_t *tzpb); (uint8_t [0x20]) Get TimeZone Presence <br> HV System Manager access - ServiceID 15 | ||
|- | |- | ||
| 385 | | 385 | ||
Line 2,583: | Line 2,565: | ||
| {{Productmode}} | | {{Productmode}} | ||
| sys_sm_set_fan_policy | | sys_sm_set_fan_policy | ||
| int sys_sm_set_fan_policy (in:uint8, in:uint8, in:uint8)<!--// int sys_sm_set_fan_policy(u8 arg0, u8 arg1, u8 arg2) //--> | | int sys_sm_set_fan_policy (in:uint8, in:uint8, in:uint8)<!--// int sys_sm_set_fan_policy(u8 arg0, u8 arg1, u8 arg2) //--> | ||
|- | |- | ||
| 390 | | 390 | ||
Line 2,599: | Line 2,581: | ||
| sys_sm_request_be_count | | sys_sm_request_be_count | ||
| 4 Params | | 4 Params | ||
uint8_t * | uint8_t *, | ||
uint32_t* total_time_in_seconds, | uint32_t* total_time_in_seconds, | ||
uint32_t* power_on_counter, | uint32_t* power_on_counter, | ||
Line 2,637: | Line 2,619: | ||
| {{Root}} | | {{Root}} | ||
| sys_sm_request_scversion | | sys_sm_request_scversion | ||
| uint8_t SoftID[8],old_PatchID[8],new_PatchID[8]; lv2syscall3(394, (uint64_t)SoftID, (uint64_t)old_PatchID, (uint64_t)new_PatchID);<br />HV System Manager access - ServiceID 30 (REQUEST_SC_VERSION) [[ | | uint8_t SoftID[8],old_PatchID[8],new_PatchID[8]; lv2syscall3(394, (uint64_t)SoftID, (uint64_t)old_PatchID, (uint64_t)new_PatchID);<br />HV System Manager access - ServiceID 30 (REQUEST_SC_VERSION) [[System_Controller_Firmware#.27info0.27 SC Firmware]] | ||
|- | |- | ||
| 395 | | 395 | ||
Line 2,644: | Line 2,626: | ||
| {{Productmode}} | | {{Productmode}} | ||
| sys_sm_request_system_event_log | | sys_sm_request_system_event_log | ||
| int sys_sm_request_system_event_log(int offset(0 - 5),uint64_t *out,uint64_t *out,uint64_t *out,uint8_t buf[0x20], int flag ), 6 Params, HV System Manager access - ServiceID 32 (REQUEST_SYSTEM_EVENT_LOG) | | int sys_sm_request_system_event_log(int offset(0 - 5),uint64_t *out,uint64_t *out,uint64_t *out,uint8_t buf[0x20], int flag ), 6 Params, HV System Manager access - ServiceID 32 (REQUEST_SYSTEM_EVENT_LOG) | ||
|- | |- | ||
| 396 | | 396 | ||
Line 2,685: | Line 2,667: | ||
| {{Productmode}} | | {{Productmode}} | ||
| | | | ||
| int sys_request_system_event_log(int offset(0 - 5),uint64_t *out, int flag ) , HV System Manager access - ServiceID 32 (REQUEST_SYSTEM_EVENT_LOG) <br> sys_sm_request_system_event_log too | | int sys_request_system_event_log(int offset(0 - 5),uint64_t *out, int flag ) , HV System Manager access - ServiceID 32 (REQUEST_SYSTEM_EVENT_LOG) <br> sys_sm_request_system_event_log too | ||
|- | |- | ||
| 401 | | 401 | ||
Line 2,694: | Line 2,676: | ||
| 2 Params: uint64_t param,uint8_t * st (status?/state?) | | 2 Params: uint64_t param,uint8_t * st (status?/state?) | ||
HV System Manager access - ServiceID 40 (BOOT_PARAMETER) | HV System Manager access - ServiceID 40 (BOOT_PARAMETER) | ||
also sends the param to syscon | |||
related to 404 | |||
|- | |- | ||
! colspan="6" id="sys_tty Syscalls"|[[#sys_tty Syscalls]] (402-403) | ! colspan="6" id="sys_tty Syscalls"|[[#sys_tty Syscalls]] (402-403) | ||
Line 2,720: | Line 2,703: | ||
HV System Manager access - ServiceID 42 (BOOT_PARAMETER) | HV System Manager access - ServiceID 42 (BOOT_PARAMETER) | ||
[Network Settings for Debug] related, returns single/dual setting flag? | [Network Settings for Debug] related, returns single/dual setting flag? | ||
|- | |- | ||
| 405 | | 405 | ||
Line 2,730: | Line 2,712: | ||
HV System Manager access - ServiceID 44 | HV System Manager access - ServiceID 44 | ||
factory_process_comp (0,0), dbg_printf comp value | factory_process_comp (0,0), dbg_printf comp value | ||
|- | |- | ||
| 406 | | 406 | ||
Line 2,741: | Line 2,722: | ||
HV System Manager access - ServiceID 46 | HV System Manager access - ServiceID 46 | ||
factory_process_comp (1,x) -> OR-Operation with comp | factory_process_comp (1,x) -> OR-Operation with comp | ||
|- | |- | ||
| 407 | | 407 | ||
Line 2,751: | Line 2,731: | ||
HV System Manager access - ServiceID 48 | HV System Manager access - ServiceID 48 | ||
factory_process_comp (2,0) -> ANDC-Operation with comp=0 | factory_process_comp (2,0) -> ANDC-Operation with comp=0 | ||
|- | |- | ||
| 408 | | 408 | ||
Line 2,765: | Line 2,744: | ||
| {{Productmode}} | | {{Productmode}} | ||
| sys_sm_get_fan_policy | | sys_sm_get_fan_policy | ||
| int sys_sm_get_fan_policy(uint8_t id, uint8_t *st (status? state?), uint8_t *policy (mode), uint8_t * mode (speed), uint8_t *duty) | | int sys_sm_get_fan_policy(uint8_t id, uint8_t *st (status? state?), uint8_t *policy (mode), uint8_t * mode (speed), uint8_t *duty) | ||
|- | |- | ||
! colspan="6" id="sys_game Syscalls"|[[#sys_game Syscalls]] (372-376+410-412) | ! colspan="6" id="sys_game Syscalls"|[[#sys_game Syscalls]] (372-376+410-412) | ||
Line 2,860: | Line 2,839: | ||
| | | | ||
| sys_overlay_get_sdk_version | | sys_overlay_get_sdk_version | ||
| | | 2 Params | ||
|- | |- | ||
| 457 | | 457 | ||
Line 2,946: | Line 2,925: | ||
| {{Root}} | | {{Root}} | ||
| sys_npdrm_check_ekc | | sys_npdrm_check_ekc | ||
| int syscall 470 ( | | int syscall 470 (uint32_t type?, void* npd? [0x60]) | ||
|- | |- | ||
| 471 | | 471 | ||
Line 2,955: | Line 2,934: | ||
| int syscall_471(uint32_t type, char* titleID, void* klicensee, uint8_t* actdat, uint8_t* rif, int32_t licenseType, uint8_t* magicVersion);<!--//The function has different parameters depending if the content is debug, free or paid: | | int syscall_471(uint32_t type, char* titleID, void* klicensee, uint8_t* actdat, uint8_t* rif, int32_t licenseType, uint8_t* magicVersion);<!--//The function has different parameters depending if the content is debug, free or paid: | ||
FREE: syscall471(npd.type, &npd.titleID, freeklicensee, NULL, NULL, npd.license, &npd); | FREE: syscall471(npd.type, &npd.titleID, freeklicensee, NULL, NULL, npd.license, &npd); | ||
PAID: syscall471(npd.type, &npd.titleID, NULL, &actdat.keyTable[rif.actDatIndex], &rif.key, npd.license, &npd) | PAID: syscall471(npd.type, &npd.titleID, NULL, &actdat.keyTable[rif.actDatIndex], &rif.key, npd.license, &npd);//--> | ||
|- | |- | ||
| 472 | | 472 | ||
Line 2,983: | Line 2,961: | ||
| {{DECR}} {{DEX}} {{CEX}} | | {{DECR}} {{DEX}} {{CEX}} | ||
| {{Root}} | | {{Root}} | ||
| | | | ||
| int syscall_475( | | int syscall_475(uint32_t type, void* npd?, void* klicensee, uint8_t* actdat, uint8_t* rif, uint8_t magicVersion) | ||
|- | |- | ||
| 476 | | 476 | ||
Line 3,508: | Line 3,486: | ||
| {{DECR}} {{DEX}} {{CEX}} | | {{DECR}} {{DEX}} {{CEX}} | ||
| | | | ||
| | | | ||
| 3 Params | | 3 Params | ||
|- | |- | ||
| 559 | | 559 | ||
Line 3,640: | Line 3,618: | ||
| sys_pad_manager_.... | | sys_pad_manager_.... | ||
| int sys_pad_manager_.... (int8_t device_number?) | | int sys_pad_manager_.... (int8_t device_number?) | ||
|- | |- | ||
! colspan="6" id="sys_bluetooth Syscalls"|[[#sys_bluetooth Syscalls]] | ! colspan="6" id="sys_bluetooth Syscalls"|[[#sys_bluetooth Syscalls]] | ||
Line 3,655: | Line 3,632: | ||
| {{DECR}} {{DEX}} {{CEX}} | | {{DECR}} {{DEX}} {{CEX}} | ||
| | | | ||
| sys_bluetooth_aud_serial_unk1(0x243,0,unk1*,aud_serial*,unk2*,unk3*,unk4*) | |||
| sys_bluetooth_aud_serial_unk1(0x243,0,unk1*,aud_serial*,unk2*,unk3*,unk4*) | |0xD0044D40 00 00 00 00 / 0xD0044D44 00 82 8E 18 --> 00 7D 39 A0 --> 0x007D39A0 5F 61 75 64 5F 53 45 52 49 41 4C 00 00 00 00 00 _aud_SERIAL..... / 0xD0044D48 00 00 00 00 / 0xD0044D4C 00 00 00 00 | ||
|- | |- | ||
| 580 | | 580 | ||
Line 4,206: | Line 4,183: | ||
| | | | ||
| sys_rsxaudio_create_connection | | sys_rsxaudio_create_connection | ||
| | | 1 Params | ||
|- | |- | ||
| 655 | | 655 | ||
Line 4,213: | Line 4,190: | ||
| | | | ||
| sys_rsxaudio_close_connection | | sys_rsxaudio_close_connection | ||
| | | 1 Params | ||
|- | |- | ||
| 656 | | 656 | ||
Line 4,220: | Line 4,197: | ||
| | | | ||
| sys_rsxaudio_prepare_process | | sys_rsxaudio_prepare_process | ||
| | | 1 Params | ||
|- | |- | ||
| 657 | | 657 | ||
Line 4,227: | Line 4,204: | ||
| | | | ||
| sys_rsxaudio_start_process | | sys_rsxaudio_start_process | ||
| | | 1 Params | ||
|- | |- | ||
| 658 | | 658 | ||
Line 4,234: | Line 4,211: | ||
| | | | ||
| sys_rsxaudio_stop_process | | sys_rsxaudio_stop_process | ||
| | | 1 Params | ||
|- | |- | ||
| 659 | | 659 | ||
Line 4,240: | Line 4,217: | ||
| {{DECR}} {{DEX}} {{CEX}} | | {{DECR}} {{DEX}} {{CEX}} | ||
| | | | ||
| | | sys_rsxaudio_ | ||
| | | 3 Params | ||
|- | |- | ||
! colspan="6" id="sys_rsx Syscalls"|[[#sys_rsx Syscalls]] (666-677) | ! colspan="6" id="sys_rsx Syscalls"|[[#sys_rsx Syscalls]] (666-677) | ||
Line 5,146: | Line 5,120: | ||
| 0x364 | | 0x364 | ||
| {{DECR}} {{DEX}} {{CEX}} | | {{DECR}} {{DEX}} {{CEX}} | ||
| {{Root}} | | {{Root}} / {{Dbg}} {{Authid}} | ||
| sys_ss_individual_info_manager | | sys_ss_individual_info_manager | ||
| [[Indi_Info_Manager|indi_info_manager_if (Interface)]] <!--///* | | [[Indi_Info_Manager|indi_info_manager_if (Interface)]] <!--///* | ||
Line 5,172: | Line 5,146: | ||
| sys_ss_get_console_id | | sys_ss_get_console_id | ||
| int sys_ss_get_console_id(uint8_t *buf) //returns [[IDPS]] in buf | | int sys_ss_get_console_id(uint8_t *buf) //returns [[IDPS]] in buf | ||
|- | |- | ||
| 871 | | 871 | ||
Line 5,181: | Line 5,154: | ||
| 3 params, their types and usage depends on 'pkg_id'. | | 3 params, their types and usage depends on 'pkg_id'. | ||
(pkg_id=1,sys_pid_t,out:uint64_t) | (pkg_id=1,sys_pid_t,out:uint64_t) | ||
(pkd_id=2,out:uint64_t,0) // returns [[ | (pkd_id=2,out:uint64_t,0) // returns [[Authentication_IDs]] | ||
(pkg_id=3,out:uint64_t,0) | (pkg_id=3,out:uint64_t,0) | ||
|- | |- | ||
Line 5,727: | Line 5,700: | ||
| | | | ||
| sys_dbg_get_lwcond_information | | sys_dbg_get_lwcond_information | ||
| int sys_dbg_get_lwcond_information (sys_pid_t id, sys_lwcond_pseudo_id_t id, sys_dbg_lwcond_information_t* info ) | | int sys_dbg_get_lwcond_information (sys_pid_t id, sys_lwcond_pseudo_id_t id, sys_dbg_lwcond_information_t* info ) | ||
|- | |- | ||
| 952 | | 952 | ||
Line 5,838: | Line 5,811: | ||
| {{DECR}} | | {{DECR}} | ||
| | | | ||
| | | ys_rsx_trace_ioctl | ||
| | | | ||
|- | |- | ||
Line 6,049: | Line 6,022: | ||
!Name | !Name | ||
!Value | !Value | ||
|- | |- | ||
|BluRayEmuOff | |BluRayEmuOff | ||
|0x04L | |0x04L | ||
|- | |- | ||
| | |BluRayEmuUSB | ||
| | |0x20L | ||
|- | |- | ||
|DebugMode | |DebugMode | ||
|0x10L | |0x10L | ||
|- | |- | ||
| | |Default | ||
| | |0x00L | ||
|- | |||
|DualNIC | |||
|0x80L | |||
|- | |- | ||
| | |HDDSpeedBluRayEmu | ||
| | |0x08L | ||
|- | |- | ||
|HostFSTarget | |HostFSTarget | ||
|0x40L | |0x40L | ||
|- | |- | ||
| | |MemSizeConsole | ||
| | |0x02L | ||
|- | |||
|ReleaseMode | |||
|0x01L | |||
|- | |||
|SystemMode | |||
|0x11L | |||
|- | |- | ||
|} | |} | ||
Line 6,390: | Line 6,363: | ||
|- | |- | ||
| 8 | | 8 | ||
| lv2_lv1_peek - graf_chokolo / (4.3x peek) | | lv2_lv1_peek - graf_chokolo / (4.3x peek) | ||
| r3 is a 64 bit address to read. A 64 bit value will be returned in r3 | | r3 is a 64 bit address to read. A 64 bit value will be returned in r3 | ||
|- | |- | ||
Line 6,396: | Line 6,369: | ||
| Peek - ps3cobra | | Peek - ps3cobra | ||
| r3 is a 64 bit address to read. A 64 bit value will be returned in r3 | | r3 is a 64 bit address to read. A 64 bit value will be returned in r3 | ||
|- | |- | ||
| 8 | | 8 | ||
Line 6,469: | Line 6,441: | ||
| 203 | | 203 | ||
| lv2_peek - [[CCAPI]] | | lv2_peek - [[CCAPI]] | ||
| | | | ||
|- | |- | ||
| 204 | | 204 | ||
| lv2_poke - [[CCAPI]] | | lv2_poke - [[CCAPI]] | ||
| | | | ||
|- | |- | ||
| 1022 | | 1022 |