Commit graph

73 commits

Author SHA1 Message Date
RipleyTom 157e73b67e Add missing NotFound error handling in LeaveRoom reply 2025-02-20 07:58:03 +02:00
RipleyTom 159370446f RPCN v1.4 2025-02-12 15:00:50 +01:00
RipleyTom cd87a64621 Headers cleanup 2025-02-11 20:38:35 +01:00
Elad 575a245f8d
IDM: Implement lock-free smart pointers (#16403)
Replaces `std::shared_pointer` with `stx::atomic_ptr` and `stx::shared_ptr`.

Notes to programmers:

* This pr kills the use of `dynamic_cast`, `std::dynamic_pointer_cast` and `std::weak_ptr` on IDM objects, possible replacement is to save the object ID on the base object, then use idm::check/get_unlocked to the destination type via the saved ID which may be null. Null pointer check is how you can tell type mismatch (as dynamic cast) or object destruction (as weak_ptr locking).
* Double-inheritance on IDM objects should be used with care, `stx::shared_ptr` does not support constant-evaluated pointer offsetting to parent/child type.
* `idm::check/get_unlocked` can now be used anywhere.

Misc fixes:
* Fixes some segfaults with RPCN with interaction with IDM.
* Fix deadlocks in access violation handler due locking recursion.
* Fixes race condition in process exit-spawn on memory containers read.
* Fix bug that theoretically can prevent RPCS3 from booting - fix `id_manager::typeinfo` comparison to compare members instead of `memcmp` which can fail spuriously on padding bytes.
* Ensure all IDM inherited types of base, either has `id_base` or `id_type` defined locally, this allows to make getters such as `idm::get_unlocked<lv2_socket, lv2_socket_raw>()` which were broken before. (requires save-states invalidation)
* Removes broken operator[] overload of `stx::shared_ptr` and `stx::single_ptr` for non-array types.
2024-12-22 20:59:48 +02:00
Megamouse 2262ac1684 Qt: Replace QMap with std::map
This should reduce the amount of string conversions during list refreshes
2024-11-06 09:34:32 +01:00
Megamouse 0a57c459b6 overlays: add friends list to home menu 2024-10-06 09:57:20 +02:00
Megamouse 73fe420d09 RPCN: add overlay messages on friend requests 2024-10-06 06:35:48 +02:00
RipleyTom 3d9c8a670e Implement old matching API 2024-09-19 20:34:56 +02:00
Megamouse 4d09ba5080 sceNp: add some more rpcn array pointer checks
These probably return an error on real firmware...
2024-06-12 00:18:37 +02:00
RipleyTom b7a882f42b Split normal sockets and p2p sockets handling v2 2024-05-08 20:04:23 +03:00
RipleyTom b38ce9452d Revert "Split normal sockets and p2p sockets handling"
This reverts commit 08c3a38b67.
2024-04-27 10:45:14 +02:00
RipleyTom 08c3a38b67 Split normal sockets and p2p sockets handling 2024-04-24 14:15:17 +03:00
oltolm 59410b9d62 fix compiler warnings 2024-03-28 08:45:20 +01:00
RipleyTom 573734fab8 Send initial presence for offline friends. 2024-02-28 17:41:25 +01:00
RipleyTom ac8e914a25
improves sig_ctx handling, sys_net logging and fixes udpp2p protocol (#15235) 2024-02-24 12:40:53 +01:00
RipleyTom 26d406fec3 RPCN 1.1 2024-02-05 09:44:29 +01:00
RipleyTom 319657e815 Review fixes 2024-02-03 08:45:29 +01:00
Megamouse cdfe3ee7c8 Name some threads 2024-01-31 16:33:29 +01:00
RipleyTom af8d308a69 Terminate RPCN connection cleanly 2024-01-29 13:01:09 +01:00
RipleyTom fe9a24a1b8
RPCN 1.0 (#15045) 2024-01-14 12:36:23 +01:00
RipleyTom 4c36b80300 Misc NP fixes 2024-01-13 15:44:28 +01:00
RipleyTom 067ea68979 Fix games passing invalid npids 2024-01-09 23:06:23 +01:00
RipleyTom 485fca34b0 Misc NP fixes 2024-01-08 14:03:15 +01:00
RipleyTom 47ae192cf8 Impl sceNpBasicSendMessage 2024-01-07 13:36:27 +01:00
RipleyTom b6e9746198
RPCN 0.9 (#15002) 2024-01-05 09:43:26 +01:00
Megamouse 59c58aa3cf fix some warnings 2023-12-30 19:07:35 +01:00
RipleyTom 03761c5dd4 rpcn 0.8 2023-12-29 19:22:49 +01:00
RipleyTom f709a5747a Force sending a FIN packet on rpcn disconnect 2023-12-13 12:42:38 +02:00
Eladash 9635417ae5 Replace some utils::bless usages 2023-08-19 17:18:40 +03:00
Talkashie dabb2cc9a0
Fix typos, improve consistency
Fixes typos where spelling or grammar is objectively wrong.
Changes wording and capitalization in some areas to be more consistent with other areas.
2023-07-28 13:09:06 +03:00
Megamouse d28e3c4f08 np_handler: fix warning: check socket in discover_ip_address 2023-06-13 18:08:51 +02:00
Megamouse f8009451a9 rpcn: fix some msvc warnings 2023-05-18 09:15:49 +02:00
RipleyTom 02a53c582c Invite changes 2023-03-18 01:51:35 +01:00
RipleyTom 192f4825a2 Fix recvn high cpu usage 2023-03-17 23:50:40 +01:00
RipleyTom f7a3d45c2c Use NBIO for RPCN 2023-03-08 13:11:33 +01:00
RipleyTom 2de4c03faa Fix wolfssl connect 2023-03-03 22:51:01 +01:00
Megamouse 1d7a00666e rpcn: throw exception when using rpcn features without a proper config 2023-03-03 11:30:39 +01:00
RipleyTom 6186ac0245 rpcn: signaling handler improvements & upnp
Simplify signaling by making Matching2 a layer over normal signaling.
Implements UPNP port forwarding
Implement sceNpMatching2AbortRequest
Fix reported bw in sceNpUtil
Hack for Fat Princess binding udp on 3658
Reenable CB for sceNpBasicAddPlayersHistoryAsync
Misc fixes
2023-02-21 15:41:41 +01:00
Ani 0d929a210f
NP: Disable some logging (#13061) 2022-12-11 16:49:14 +00:00
RipleyTom 9b121a6414 sys_net: improvements
sys_net: implement reusable addr for p2p sockets
sys_net: implement getpeername for P2PS
sys_net: sockets inherit NBIO from their parent
2022-10-22 11:32:04 +02:00
RipleyTom 01c285fc4a RPCN v0.7
Bump protocol version
Improve signaling RTT calculation for client
Implement score game data functions
Various sceNpScore fixes
Verify flatbuffer buffers
Use std::variant for transaction specific data
2022-10-17 09:57:10 +02:00
RipleyTom d1a7bb0136 Fix faulty GetScoreFriendsRequest 2022-09-28 21:58:11 +02:00
RipleyTom eea73deab3 RPCN v0.6 2022-09-27 23:39:54 +03:00
Nekotekina 6ff6a4989a Implement at32() util
Works like .at() but uses source location for "exception".
2022-09-26 18:04:15 +03:00
RipleyTom e68ffdbc81 Add a message overlay 2022-05-23 08:38:02 +02:00
RipleyTom 72b2876b6a
sys_net refactor (#11740) 2022-04-09 14:51:22 +02:00
RipleyTom 6c5b8dc31c rpcn: add cookie impl to tickets 2022-02-03 13:25:15 +01:00
Nekotekina 580bd2b25e Initial Linux Aarch64 support
* Update asmjit dependency (aarch64 branch)
* Disable USE_DISCORD_RPC by default
* Dump some JIT objects in rpcs3 cache dir
* Add SIGILL handler for all platforms
* Fix resetting zeroing denormals in thread pool
* Refactor most v128:: utils into global gv_** functions
* Refactor PPU interpreter (incomplete), remove "precise"
* - Instruction specializations with multiple accuracy flags
* - Adjust calling convention for speed
* - Removed precise/fast setting, replaced with static
* - Started refactoring interpreters for building at runtime JIT
*   (I got tired of poor compiler optimizations)
* - Expose some accuracy settings (SAT, NJ, VNAN, FPCC)
* - Add exec_bytes PPU thread variable (akin to cycle count)
* PPU LLVM: fix VCTUXS+VCTSXS instruction NaN results
* SPU interpreter: remove "precise" for now (extremely non-portable)
* - As with PPU, settings changed to static/dynamic for interpreters.
* - Precise options will be implemented later
* Fix termination after fatal error dialog
2022-01-15 06:48:04 +03:00
RipleyTom c194804fec NP: Implement sceNpBasicGetFriendListEntry 2021-11-08 13:10:40 +03:00
RipleyTom d41e405420 NP: Cache Manager + improvements 2021-11-08 13:10:40 +03:00