fix(libkernel): translate pending connection errors #2080
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/2080"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from boykopovar/AnyPS5. Originally posted by STUPIDCONTEM on 2026-10-09T07:10:05Z.
Evidence review (2026-10-09)
Game/title evidence has not been established. Validation below is host regression/build evidence only; it does not establish title compatibility. Older checked items and test results describe their stated revisions, not current merge readiness.
Game/title ID: none verified. No PS5 title execution is claimed.
What
Nonblocking connect now translates a pending host connection to guest EINPROGRESS (36), and a repeated pending connection to EALREADY (37). Previously Windows WSAEWOULDBLOCK became EAGAIN (35), while POSIX EINPROGRESS/EALREADY fell through to EIO (5). Applications checking the expected pending status could incorrectly treat an ordinary connection attempt as failure.
Translation is specific to connect, preserving ordinary send/receive would-block behavior and existing fallback errors. The contracts are FreeBSD stable/11 connect(2) and Microsoft Winsock connect. Windows WSAEINPROGRESS describes a separate blocking Winsock operation; it is not reclassified as a pending nonblocking connect.
Tested
Windows 10 Pro 19045, WinLibs GCC 15.2.0 UCRT posix SEH r7, Release, BUILD_TESTING=ON; independent branch from main
f145139676.An earlier fourteen-proposal integration passed full Linux verification with SPIRV Tools and lavapipe enabled: run 37898813460, exact head 8740893d8db1f13169cb0923d0445dec0a21ba42, 479 tests passed three times and 25 graphics feature tests were skipped (504 registered tests, zero failures). Two unrelated graphics tests exceeded the project 30-second target on their cold run; no timeout occurred. No title run was performed. The repeated-pending case is covered at the mapper level; loopback timing is not used to force a second connection attempt to remain pending.
Open #2079 fixes accepted socket mode in the same runtime and test file; both TCP regression blocks are retained in the integration. #1091 implements readiness events and #1832 descriptor polling. No duplicate pending-connect fix was found.
Current Windows integration, based on upstream
d70b89989473ba1f6ae13e44e079e67f1f8a44b0, contains the 19 still-open proposals and excludes the three declined changes and the superseded build fix. Default and explicit libs builds passed at8f0190c793c6dfa2b7a3a3f33f3d2cbe2509937c; 513 tests passed and one was skipped (514 registered, 52.66 seconds). Five affected I/O and socket tests each passed ten repetitions. Removing only the production ConnectError call reproduced the public TCP pending-error failure on this Windows host; restoring it gave ten passes. Loopback may complete immediately on other hosts, so this is Windows call-site evidence rather than a guarantee that every Linux run exercises the pending path.The complete external #1091 (f94f0300 and exact tip 7f5f456585e9a112ac468726c43df636d711a1d8), #1832 (
f782e4ad17), and #1676 (942a105c39) were also combined locally, preserving their authors. With the separate local SCE clock bridge and retained interaction fixtures, default/libs builds and 515 tests passed with one skip (516 registered, 38.46 seconds), ate44f3ca62d9ae7c34df5e988e1fe981be79c4806. Seven affected socket, polling, timer, and clock tests passed five repetitions each. This is integration evidence for the named tests; no title execution is claimed.Checklist
Pull request closed