fix(libSceGnmDriver): guard workload output pointers #18212
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/18212"
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 DonRyuzaki on 2026-11-10T21:25:43Z.
What
Current main merged #18235, which already exports the regular GNM workload lifecycle functions. This PR now guards the output pointers in
sceGnmCreateWorkloadStreamandsceGnmBeginWorkloadwithGuestCopyOut_nid_no_patch. An invalid guest output address returns the existing code 3 instead of being dereferenced. Valid outputs, stream boundaries, andsceGnmEndWorkloadbehavior stay as implemented on main. The NeoMode provider already usesGuestCopyOut_nid_no_patch.The existing
guest_gnm_drivertest now checks invalid output addresses for both functions, including the invalid-stream path. This is a pointer-safety fix; no new exports are added.Tested
Head
8c362ff625287d52b6096239da42bd2facce8e40, merged with upstream main1a4e8ab22c2f050cbaa177480fe98e11d187e9c1. The patch against that main changes onlycore/libs/prx/libSceGnmDriver/Export.cppandcore/libs/tests/GuestGnmDriver.cpp.BUILD_TESTING=ON:cmake --build build --target guest_gnm_driver_tests --parallel 8passed on the merged tree.ctest --test-dir build --no-tests=error --output-on-failure -R '^guest_gnm_driver$': 1/1 passed on that tree.git diff --check upstream/main HEADandpython3 -B tools/check_conventions.py --base upstream/main: passed on the committed head.Checklist
main; no other open PR implements this pointer-safety fixNotImplemented_nid_no_patch); silent stubs are listed under Silent stubs in their library's technical debt file.mdfiles or images added to the repository (attach them to this PR)Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-12T21:16:02Z.
Review: COMMENTED
Workload lifecycle exports for the regular GNM driver — no blocking findings
Nothing blocks this; the points below are optional.
What I ran
c1d72b98d982407ab3a7649d24cb7bddbce7eaa2, basemain.diff.patch. Read the head ofcore/libs/tests/GuestGnmDriver.cpp(lines 1–30) through the reader.Results
Findings
Blocking: none.
Non-blocking: none found in the changed lines.
Not verified
5udAm+6boVg,ihxrbsoSKWcandFa3x75OOLRA. The repository has no text match for them, and the NID mapping comes from build tooling that I did not check.Export.cpp(both providers),Api.hpp, the rest ofGuestGnmDriver.cppand the debt file. I read only the diff hunks of these.To get this to a good state
Nothing is required.