Commit graph

103 commits

Author SHA1 Message Date
clienthax 6837370a62 Handle SYS_NET_IPPROTO_IP get/setsockopt
Improve net logging.

Should allow latest vsh to load (Depending on windows version apparantly..)
2021-12-27 20:58:09 +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
RipleyTom 516cb959cb rpcn: new allocator + refactoring of np_handler 2021-11-08 13:10:40 +03:00
Nick Renieris b70f08d850 The Velocity Improvements: RoomData/RoomMemberData commands & fixes
modules/np2: Correct some SceNpMaching2 ptr type endianness
np/handler: Use STL .contains() method
Ignore USECRYPTO & USESIGNATURE in recvfrom/sendto
Implement RoomData/RoomMemberData commands
2021-11-08 13:10:40 +03:00
RipleyTom 683c061e60 sys_net: getsockname on unbound p2p socket fix 2021-10-16 11:41:20 +02:00
RipleyTom 0e625e193e sys_net: redirects 0.0.0.0 packets on windows 2021-10-16 11:41:20 +02:00
RipleyTom ea9dc9317d rpcn v0.4.0 2021-10-11 22:20:20 +02:00
Eladash fe0c164de2 sys_net: Anti-log spam enhancement 2021-09-04 11:58:59 +02:00
Megamouse 0debcfed0a Silence some warnings 2021-09-02 19:39:42 +02:00
Justin Lewis c13a46b07b
Fix warnings about using deprecated inet_ntoa function (#10698)
* Replaced inet_ntoa with inet_ntop.

The warning in question is: "Warning	C4996	'inet_ntoa': Use
inet_ntop() or InetNtop() instead or define
_WINSOCK_DEPRECATED_NO_WARNINGS"
2021-08-18 07:16:38 +03:00
Megamouse 430fd759fe sys_net: add missing range checks 2021-08-08 21:06:07 +02:00
Nekotekina 86d2316089 sys_net/NP: set some init dependencies
Ensure finalization order of network threads.
This should prevent some crashes.
2021-08-06 10:41:40 +03:00
Eladash 0aed00a758
Improve thread aborting mechanism (#10490)
Call pseudo-virtual operator=(thread_state) of thread context.
2021-06-27 11:43:48 +03:00
Nekotekina 19763f8973 Remove unnecessary default:breaks 2021-04-15 15:23:59 +03:00
Megamouse a16d8ba3ea More random changes 2021-04-11 14:01:51 +03:00
Nekotekina c22e1e71f0 Continue fixing strict aliasing warnings 2021-03-13 18:02:37 +03:00
Nekotekina 87af905018 Enable -Wunused-parameter 2021-03-06 18:07:08 +03:00
Nekotekina ea5e837bd6 fixed_typemap.hpp: return reference 2021-03-02 16:08:14 +03:00
RipleyTom 81270f3142 Remove now useless code from sys_bnet_connect 2021-02-21 18:04:55 +03:00
Eladash f43260bd58
Atomic waiting refactoring (#9208)
* Use atomic waitables instead instead of global thread wait as often as possible.
* Add ::is_stopped() and and ::is_paued() which can be used in atomic loops and with atomic wait. (constexpr cpu flags test functions)
* Fix notification bug of sys_spu_thread_group_exit/terminate. (old bug, enhanced by #9117)
* Function time statistics at Emu.Stop() restored. (instead of current "X syscall failed with 0x00000000 : 0")
2021-02-13 17:50:07 +03:00
Nekotekina db8e6fe7a7 Enable -Wunused-variable 2021-01-12 14:34:14 +03:00
Nekotekina fb29933d3d Add usz alias for std::size_t 2020-12-18 12:23:53 +03:00
Nekotekina 6e05dcadb6 Reduce std::numeric_limits dependency
Please, stop pretending...
You need these templates for generic code.
In other words, in another templates.
Stop increasing compilation time for no reason.
2020-12-12 12:35:18 +03:00
Nekotekina aa3aef4beb std::chrono cleanup: always use steady_clock 2020-12-11 19:01:56 +03:00
Nekotekina 36c8654fb8 Remove HERE macro
Some cleanup.
Add location to some functions.
2020-12-10 12:30:22 +03:00
Nekotekina e055d16b2c Replace verify() with ensure() with auto src location.
Expression ensure(x) returns x.
Using comma operator removed.
2020-12-09 15:43:38 +03:00
RipleyTom af8c661a64 Remove BOM markers 2020-12-06 15:30:12 +03:00
RipleyTom debfae06a8 Improve disconnected state handling of dns queries 2020-11-13 07:05:06 +03:00
RipleyTom a83df01bfd
rpcn 0.3.5 (#9227) 2020-11-10 08:55:49 +00:00
Nekotekina 34fa010601 Improve cond_var notifiers
But nobody uses it anyway, so clean up includes.
2020-11-06 00:10:16 +03:00
Bevan Weiss f4070731a8 NET: Add SO_RCVBUF / SO_SNDBUF defaults to .._bnet_socket
The OS defaults for SO_RCVBUF / SO_SNDBUF may not match what the defaults for the PS3 are.
And the code may be happy with the PS3 defaults, so may not set this explicitly.
So we'll do it when we establish the socket.
It also looks like the Windows recv behaviour is different for the MSG_PEEK option (and possibly in all situations where a smaller buffer is provided). I believe other platforms will return the size of the data received into the socket buffer, even if the supplied user buffer is smaller. Windows returns WSAEMSGSIZE instead. For the length of '1' MSG_PEEK request that is currently seen, we just mask this and return the full size of the buffer. This might need to be the case in all situations, I assume there will be applications that will supply an artificially small buffer and resize it as necessary based on the size of the received packet.
Add some additional translations from native->PS3 error codes

Rewrote handling of MSG_PEEK to just be a copy of what GalCiv suggested
Added WSAESHUTDOWN, and WSASetLastError as done by Cygwin
2020-10-28 20:54:29 +03:00
RipleyTom 9e14d240a8 Implement ethernet address determination 2020-10-16 22:53:48 +03:00
RipleyTom 1393bb2caf Fix getsockname on windows for unbound sockets 2020-10-16 22:53:48 +03:00
RipleyTom e9914f3004 Add sys_net error for EISCONN 2020-10-16 22:53:48 +03:00
RipleyTom 073772a801 Fixes setsockopt 2020-10-16 22:53:48 +03:00
RipleyTom 2babe4c236 Add better handling of RTT for STREAM_P2P 2020-10-16 22:53:48 +03:00
RipleyTom bbda618beb Improve poll for p2p sockets 2020-10-16 22:53:48 +03:00
RipleyTom 676fed7cfc Only bind 3658 with RPCN 2020-09-09 23:56:25 +02:00
RipleyTom d9d354c981 Makes DNS processing more consistent 2020-09-09 23:56:25 +02:00
RipleyTom 10820fa135
Implement sceNpSignaling & signaling improvements (#8836) 2020-09-07 22:50:17 +01:00
RipleyTom 4317291827
tcp_timeout_monitor deadlock fix (#8783) 2020-08-28 01:06:01 +01:00
RipleyTom 190822c2b2
RPCN Client (#8663) 2020-08-27 20:47:04 +01:00
Eladash d9750e8f9f SPU/PPU reservations: Optimizations for reservation locks and check_state() (non-TSX) 2020-07-09 03:17:35 +01:00
Derrik Touve cb08c53f2f
sys_net: Use np_handler dns if possible for sys_net_infoctl (#8557)
Without this, cellHttpSendRequest will use the hardcoded dns 192.168.1.1, which won't work if you're not on that network.
2020-07-07 08:25:29 +02:00
Eladash e1f8573c68 sys_net: Fix sys_net_bnet_setsockopt page faults 2020-06-12 22:39:13 +03:00
Eladash 4bc157881d sys_net: Stub sys_net_infoctl command 9 2020-06-12 22:39:13 +03:00
Eladash 6892399699 kernel_explorer: More Improvements 2020-06-12 09:28:23 +02:00
Nekotekina 3d7c38ff9d Remove lambda in sys_net_bnet_poll 2020-06-07 22:44:07 +03:00
Ani 9657b3f1d4
Fix sys_net_bnet_poll regression (#8337)
Co-authored-by: Eladash <elad3356p@gmail.com>
2020-06-04 17:30:11 +01:00