fix(libSceAmpr): copy guest command buffer objects instead of dereferencing them #21552
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/21552"
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 Gruzzberry on 2026-11-16T11:39:28Z.
What
libSceAmpr command-buffer exports read and wrote the guest
CommandBufferObjectthrough raw pointers (buffer->base,->offset,->recording,->type,&buffer->offset) and calledstrlenon a guest name in_Cnd_init_with_name. Every access now goes through a staged local copy usingGuestCopyIn_nid_no_patch/GuestCopyOut_nid_no_patch(the existingCopyGuestIn/CopyGuestOuthelpers) andCopyGuestString_nid_no_patch. A fault returnsSCE_KERNEL_ERROR_EFAULT.tools/guest_pointer_audit.py libSceAmprgoes from 12 findings to 0.Tested
Windows host. Ran
tools/guest_pointer_audit.py libSceAmpr(12 to 0) andtools/check_conventions.py --base upstream/main(passes). Not built and not run: no compile and no title or homebrew test.Checklist
main; no other open PR implements the same functionsNotImplemented_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)🤖 Generated with Claude Code
Pull request closed