Commit graph

415 commits

Author SHA1 Message Date
Nekotekina
81a110f346 Fix system time wraparound
Implement utils::udiv128, utils::div128
2019-08-30 22:02:25 +03:00
Nekotekina
b3f5d6d85b Put lv2_obj::awake calls under mutex 2019-08-29 02:44:12 +03:00
Nekotekina
b6b7d7b48c sys_cond_wait fixup 2019-08-27 15:38:18 +03:00
Nekotekina
ec8c5453bc Fix sys_cond_wait
Schedule PPU thread before relocking.
Don't lock mutex in notify functions.
2019-08-27 15:13:01 +03:00
Nekotekina
fd839243ec Revert PR 6405 2019-08-27 14:05:38 +03:00
Nekotekina
7a00b5f809 Use g_fxo for patch_engine 2019-08-27 03:50:15 +03:00
Nekotekina
38a06c4b14 Use g_fxo for SysRsxConfig
Rename to lv2_rsx_config
2019-08-27 03:50:15 +03:00
Nekotekina
cf44038435 Use g_fxo for lv2_config 2019-08-27 03:50:15 +03:00
Eladash
a921fe3351 lv2: Wait for rescheduling before confirming ETIMEOUT 2019-08-27 03:44:34 +03:00
Eladash
35a3bed91a sys_cond_wait: Wait for rescheduling before relocking 2019-08-27 03:44:34 +03:00
Nekotekina
2740fafa64 Use g_fxo for page_fault_notification_entries 2019-08-22 02:13:39 +03:00
Nekotekina
54952f6ad6 Use g_fxo for LoadedNpdrmKeys_t
Rename to loaded_npdrm_keys
2019-08-22 02:13:39 +03:00
Nekotekina
a85a8796d3 Use g_fxo for page_fault_event_entries 2019-08-22 02:13:39 +03:00
Nekotekina
7db2e2537f Don't call lv2_obj::awake_all with empty list
Fixup after #5883
2019-08-22 02:13:39 +03:00
JohnHolmesII
5817e2a359 Fix mismatched enum string formats in sys_config 2019-08-18 18:39:17 +02:00
Eladash
62414cee15 Do not allow SYS_SYNC_PRIORITY_INHERIT in sys_semaphore_create (EINVAL) 2019-08-18 04:01:16 +03:00
Nekotekina
dd86aa472d Fix _sys_lwcond_queue_wait
Fixup after #5883
2019-08-18 00:19:31 +03:00
Nekotekina
6535fb0603 Fix _sys_lwcond_signal_all
Fixup after #5883
2019-08-18 00:19:31 +03:00
yahfz
1444492eab lv2: Allow sys_sync_priority_inherit 2019-08-17 23:11:08 +03:00
eladash
050339bb3e PPU/LV2: Make thread-lists scheduling atomic 2019-08-17 22:46:36 +03:00
Eladash
0d88f037ff Add new accuracy control for PUTLLUC accuracy setting (non-TSX)
With the option enabled GET commands are blocked until the current PUTLLC/PUTLLUC executer on that address finishes

Additional improvements:
- Minor race fix of sys_ppu_thread_exit (wait until the writer finishes)
- Max number of ppu threads bumped to 8
2019-08-17 00:42:46 +03:00
Eladash
d8402008dd Stub sys_process_get_number_of_object(object == SYS_SPUPORT_OBJECT) 2019-08-16 23:49:24 +03:00
Eladash
0dce6be8cb Implement lv2_spu_image
- Improved sys_spu_image_.. error checking
- sys_process SYS_SPUIMAGE_OBJECT handling implemented
2019-08-16 23:49:24 +03:00
Eladash
80827aa31a Stub sys_process_get_number_of_object(object == SYS_TRACE_OBJECT) 2019-08-16 23:49:24 +03:00
Nekotekina
f8f3067deb Always check page_allocated in vm::check_addr 2019-08-14 20:28:34 +03:00
Nekotekina
d45c743877 Remove lib_loading_type::automatic
This is former default and is now obsolete.
2019-08-14 20:28:34 +03:00
Nekotekina
cf16ee5eb5 Implement lib_loading_type::liblv2list 2019-08-14 20:28:34 +03:00
Nekotekina
ae46333e99 Implement lib_loading_type::liblv2both 2019-08-14 20:28:34 +03:00
Eladash
14ac70dfbf Avoid using _sys_ppu_thread_exit in _sys_interrupt_thread_disestablish 2019-08-13 04:56:00 +03:00
Eladash
6d3fc3a386 core config: Expose min/max ranges of integral settings and use it 2019-08-13 04:56:00 +03:00
Eladash
cd4e895c04 Use error_code in mmapper_thread_recover_page_fault 2019-08-13 04:56:00 +03:00
Eladash
629d8e3a51 Fix sys_time_get_current_time() date 2019-08-13 04:56:00 +03:00
Eladash
0a5b6ad928 Add missing EALIGN check for sys_mmapper_search_and_map 2019-08-11 21:43:13 +03:00
Eladash
a832581201 Fix sys_vm address boundary checks (fix vsize) 2019-08-11 21:43:13 +03:00
Eladash
96527eee5b idm: Fix bug in ID searching
* ID checking now checks if (id % step) == 0
* Extend possible ID range to allow UINT32_MAX (as long as base is non-zero)
2019-08-11 21:43:13 +03:00
Eladash
5c904bf3e2 Fix max allocations for DECR mode (sys_memory) 2019-08-11 21:43:13 +03:00
Eladash
cbcd06d1dc ppu: Stack size allocation improvements 2019-08-11 21:43:13 +03:00
Eladash
3ce18fd960 Implement vm::page_executable (#6330)
Fixes segfaults when attenpting to set segfaults on non-executable memory.
2019-08-11 21:04:17 +03:00
Eladash
94d33003a3 Write zero in attr->pad (sys_memory_get_page_attribute)
Its included in lv2 as well.
2019-08-10 19:47:37 +03:00
Eladash
25e47e0de0 Fix vm::check_addr memory state check 2019-08-10 19:47:37 +03:00
Eladash
c219417f62 sys_vm: Fix sys_vm_invalidate 2019-08-03 14:29:17 +01:00
Eladash
72fb3ba794 perf hotfix for sys_timer_usleep 2019-08-01 23:38:09 +03:00
eladash
e40b76b253 sys_lwcond: Extract protocol from lwmutex at creation
This is the only reason theres a need to specify lwmutex_sq id at creation. unlike sys_cond, lwcond isn't connected to lwmutex at the lv2 level.
SYS_SYNC_RETRY fix is done explicitly at the firmware level.
This fixes issues when the original lwcond and lwmutexol data got corrupted or deallocated, this can happen when the program simply memcpy the control data to somewhere else.
Or if it uses direct lv2 the lwcond conrol param can even be NULL which will make it access violate when dereferncing it. (This param is unchecked and can be anything)
2019-07-29 21:58:04 +03:00
eladash
7508ae6e65 Add EAGAIN check for sys_memory_contianer_create 2019-07-29 21:55:59 +03:00
eladash
1e5e0f3b5e make sys_fs_closedir atomic 2019-07-29 21:55:59 +03:00
Nekotekina
949f33c8a4 Fix sys_config_get_io_event syscall name 2019-07-29 21:55:59 +03:00
Eladash
997e3046e3 vm/sys_overlay Improvements
- Implement sys_overlay_load_module_by_fd.
- Implement special segment allocation when ppc_seg flag is specified.
2019-07-28 14:23:58 +03:00
Eladash
fcc75c8b0f rsx: Write atomically semaphore updates and fix zcull timestamp 2019-07-26 21:27:55 +03:00
Eladash
c53f0dd7b5 rsx: Fix gcm unmap events 2019-07-26 21:27:55 +03:00
Eladash
85b1152e29 Timers scaling and fixes 2019-07-23 00:09:01 +01:00