Skip to content

feat(patchchecker): return not initialized from auto download stubs - #23346

Merged
oneandonlydean merged 1 commit into
boykopovar:mainfrom
Rosner3:feat/patchchecker-auto-download
Nov 23, 2026
Merged

oneandonlydean merged 1 commit into
boykopovar:mainfrom
Rosner3:feat/patchchecker-auto-download

Conversation

@Rosner3

@Rosner3 Rosner3 commented Nov 18, 2026

Copy link
Copy Markdown
Contributor

What

Return SCE_PATCH_CHECKER_ERROR_NOT_INITIALIZED (0x80182402) from scePatchCheckerDisableAutoDownload and scePatchCheckerEnableAutoDownload before initialization, matching the uninitialized behavior of the other stubs in libScePatchCheckerClient.

Tested

  • Built and ran guest unit assertions in core/libs/tests/GuestPatchCheckerClient.cpp ensuring scePatchCheckerDisableAutoDownload and scePatchCheckerEnableAutoDownload return 0x80182402 prior to initialization.
  • Verified debt fragment resolution via python tools/debt_fold.py --check.
  • Verified conventions via python tools/check_conventions.py.

Checklist

  • Based on current main; no other open PR implements the same functions
  • One topic per PR; follow-ups go in a new PR
  • No comments in code except technical debt and the licence notice of code adapted from upstream (see AGENTS.md)
  • Unimplemented paths throw (NotImplemented_nid_no_patch); silent stubs are listed under Silent stubs in their library's technical debt file
  • No notes, investigation .md files or images added to the repository (attach them to this PR)
  • New third-party code is a submodule built from source
  • Generic behaviour, not specific to one title
  • Depends on: none
  • Fixes: none
  • Unblocks: none
  • GPUs tested: n/a
  • AI-assisted: yes

@PrivacyOnion PrivacyOnion left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Verified on Linux (Ubuntu 24.04, GCC 13.3, Ninja, Release) against 1647f7dbac:

  • Conventions: tools/check_conventions.py passed.
  • Build: guest_patch_checker_client_tests built cleanly.
  • CTest (guest_patch_checker_client):
    1/1 Test #4888: guest_patch_checker_client .......   Passed    0.01 sec
    100% tests passed, 0 tests failed out of 1
    
  • Negative control: with core/libs/prx/libScePatchCheckerClient/Export.cpp reverted to main and the new tests kept, the suite fails:
    1/1 Test #4888: guest_patch_checker_client .......Subprocess aborted***Exception:   0.27 sec
    0% tests passed, 1 tests failed out of 1
    
    Restoring the change makes it pass again.
  • Code reading:
    • Verified that scePatchCheckerDisableAutoDownload and scePatchCheckerEnableAutoDownload in core/libs/prx/libScePatchCheckerClient/Export.cpp return SCE_PATCH_CHECKER_ERROR_NOT_INITIALIZED (0x80182402), matching the uninitialized behavior of all other uninitialized client exports.
    • Verified that the technical debt fragment docs/dev/debt/changes/feat-patchchecker-disable-enable-auto-download.md accurately updates 'The uninitialized answers' section with upstream firmware disassembly rationale (10 exports returning 0x80182402).
    • Verified that core/libs/tests/GuestPatchCheckerClient.cpp asserts both scePatchCheckerDisableAutoDownload and scePatchCheckerEnableAutoDownload return notInitialized (0x80182402).
    • Verified compliance with AGENTS.md rules: no code comments added, no hardcoded title IDs or special cases, and valid fragment format under docs/dev/debt/changes/.
    • Verified type safety and ABI: int APS5_VABI return type matching the 32-bit signed error code SCE_PATCH_CHECKER_ERROR_NOT_INITIALIZED across LP64 and LLP64 platforms.

Looks Good To Me

@maskym

maskym commented Nov 18, 2026

Copy link
Copy Markdown
Contributor

Windows result for head 1647f7dbac, merged alone into main 9a50e1014e (the PR's Tested section names no Windows run).

Host: Windows 11 26300, Intel i7-12700K, WinLibs GCC 15.2.0 (x86_64-ucrt-posix-seh, r6), Release, BUILD_TESTING=ON, Ninja. main itself fails to compile one test on Windows at this commit (UploadCacheReadOnlyFlush.cpp:177, setenv; #19899 fixes it), so the tree was built with ninja -k 0. This PR adds no other build failure.

guest_patch_checker_client, the test this PR adds or extends, passes 3 of 3 runs. Not run on a PS5.

AI-assisted: yes (Claude Code), the runs and the numbers above are from this machine.

@kiwe147

kiwe147 commented Nov 21, 2026

Copy link
Copy Markdown

Tested head 1647f7dbac, applied with git apply on main fd4aeed483 together with the other 29 PRs of one batch (#24470, #24601, #17439, #17546, #21117, #21261, #21741, #21995, #22067, #22398, #23111, #23864, #24377, #24475, #24556, #14106, #14109, #19966, #20050, #20161, #20622, #21237, #22215, #22764, #22884, #22938, #23745, #24399, #24460). All applied without conflicts and the whole tree built.

Setup: Windows 11 Pro 10.0.26200, Ryzen 7 9800X3D, WinLibs GCC 15.2.0 r7, Release, BUILD_TESTING=ON. GPUs: NVIDIA GeForce RTX 3080 (driver 621.24) and the AMD Radeon iGPU of the CPU (gfx1036, driver 32.0.21036.18). No validation layer. iGPU run: ANYPS5_REQUIRE_VULKAN=1 ANYPS5_NO_SHADER_CACHE=1 ANYPS5_GPU="AMD Radeon", agc_/video tests only.

tests RTX 3080 iGPU
guest_patch_checker_client (1 test, matched by name to the test file this PR changes) all pass outside the iGPU subset

Whole batch: the full ctest -j 12 (6525 tests) on the RTX 3080 has 5 failing tests; the 4 that also fail on main fd4aeed483 are agc_driver_stencil_plane_memory, agc_driver_msaa_dcc_unwatch, agc_storage_write_back_host_retile, and pr_overlap_names, which needs a newer Python than my 3.10. Traced to other PRs of the batch, each by reverting it and testing again: #21117 (guest_pad); none is in this PR's area. The 2125 agc_/video tests on the iGPU have 1 failing: agc_driver_stencil_plane_memory (agc_driver_stencil_plane_memory also fails on main).

This is one combined tree, not a run of this PR alone.

AI-assisted: yes (Claude Code)

@MarcZX10 MarcZX10 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed — looks good

The change consistently returns the uninitialized error from both auto-download exports, and the added guest assertions cover those calls.

What I ran

No commands were run. I read the prepared diff and all three changed files at head 1647f7dbac1bf4ee9bebf543f10dfd4490cca1eb using repo_read.py.

Results

Check Result Note
Changed code review passed All changed files read
Build and guest assertions not run Reported by author only
Debt and convention checks not run Reported by author only

Findings

Blocking

None.

Non-blocking

None.

Not verified

The author reports building and running guest assertions, checking debt resolution, and checking conventions; I did not run these checks. The firmware disassembly claim in the debt note was not independently verified. No files were excluded from review.

To get this to a good state

Nothing is required.

@oneandonlydean
oneandonlydean merged commit a452afa into boykopovar:main Nov 23, 2026
3 checks passed
@Rosner3
Rosner3 deleted the feat/patchchecker-auto-download branch November 23, 2026 10:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants