Implement missing kernel and startup library imports #772
No reviewers
Labels
No labels
bug
documentation
duplicate
enhancement
GPU
GUI
help wanted
question
Shaders
Video
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/KytyPS5--KytyPS5!772
Loading…
Reference in a new issue
No description provided.
Delete branch "gh-pr/772/head"
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?
@tototomate123 on GitHub · 2026-09-22 19:32 UTC · original
tototomate123:fix/kernel-startup-hfw→main· +235 −0 · 8 files · 2 commits · merged 2026-09-23 11:57 UTCAdds reusable implementations for kernel filesystem and startup APIs encountered by Horizon Forbidden West and potentially other titles:
preadv,pwritev, andchmodin the shared kernel/filesystem paths, with filesystem testsVideoOutVrrStatus.HFW now runs through startup, language selection, and the intro to the title menu. Selecting Start still fails during compute shader resource tracking with
GetImageResourcereporting an invalid runtime value; gameplay loading is not fixed here.The private
VideoOutVrrStatusimport uses an inferred ABI and should be reviewed.Validation: Linux emulator and filesystem-test targets built; the focused
kernel_file_systemtest and configured clang-format hook passed. Windows and macOS were not tested locally; the PR workflow covers those platforms.Horizon Forbidden West reaching the title screen in a local development build
@coderabbitai[bot] on GitHub · 2026-09-22 19:44 UTC · original · edited 2026-09-22 19:45 UTC
Navigate logical layers of code changes, visualize relationships, and explore their blast radius.
📝 Walkthrough
Walkthrough
The change adds
KernelPreadv,KernelPwritev, andKernelChmod, including descriptor state, permission handling, error translation, and library exports. It addsVideoOutGetVrrStatusand entitlement-key access APIs with library registration. It also adds tests for validation, positioned I/O, permissions, concurrency, socket behavior, and symbol imports.Suggested reviewers:
nmzikPriority: ➖ Normal
Change: Feature
Merge Risk: 🔵 Low · up to
16122Large vectored I/O requests and some permission failures may behave incorrectly; these localized fixes should be applied before merge.
🚥 Pre-merge checks | ✅ 4 | ❌ 1
❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
Comment
@coderabbitai helpto get the list of available commands.@coderabbitai[bot] on GitHub · 2026-09-22 19:44 UTC · original
On
src/kernel/fileSystem.cppline 130 (outdated):🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win
Map
operation_not_permittedtoKERNEL_ERROR_EPERM.KernelChmodpassesstd::filesystem::permissionserrors toFileSystemErrorToKernel. This branch mapsstd::errc::operation_not_permittedtoKERNEL_ERROR_EACCES. The repository defines distinctEPERMandEACCESvalues, so a matching chmod failure reaches the guest asEACCESinstead ofEPERM.Suggested fix
@coderabbitai[bot] on GitHub · 2026-09-22 19:44 UTC · original
On
src/kernel/fileSystem.cppline 813 (outdated):🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win
🔎 Supported by static analysis
🏁 Script executed:
Repository: KytyPS5/KytyPS5
Length of output: 8210
Use
UINT_MAXfor aggregate vector-length validation.KernelPreadvandKernelPwritevare registered insrc/libs/libKernel.cppand reject aggregate lengths aboveINT_MAXbefore performing I/O. A reachable vector with total length fromINT_MAX + 1throughUINT_MAXtherefore returnsKERNEL_ERROR_EINVAL, althoughKernelIovec::iov_len,Common::File::Read/Write, and scalar positional callers support that range.Suggested fix
Apply the same change to the corresponding check in
KernelPwritev.📝 Committable suggestion
@coderabbitai[bot] on GitHub · 2026-09-22 19:44 UTC · original · reviewed
Actionable comments posted: 2
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository: KytyPS5/KytyPS5/.coderabbit.yaml
Review profile: CHILL
Plan: Advanced
Run ID:
e6a7f4fb-cb33-4c22-b062-554b6732d802📥 Commits
Reviewing files that changed from the base of the PR and between
8b095caefeand1612207d9a.📒 Files selected for processing (9)
src/graphics/presentation/videoOut.cppsrc/graphics/presentation/videoOut.hsrc/kernel/fileSystem.cppsrc/kernel/fileSystem.hsrc/libs/libKernel.cppsrc/libs/libNet.cppsrc/libs/libVideoOut.cppsrc/libs/libs.cpptests/KernelFileSystemTests.cppIncluded review availability: Your plan provides up to 10 included reviews per hour; 9 remain after this review.