Repository navigation
K2GO-598 fix(proot-builder): 32-bit Go futex_time64 under the Android 8 to 10 app filter - #831
Merged
Merged
Conversation
… 8 to 10 app filter One translate_futex_time64() for the sysenter and the SIGSYS paths: futex runs in place of the trapped futex_time64, with the wait timeout in the 32-bit layout. The SIGSYS of the call that proot runs only to fail (no NT_ARM_SYSTEM_CALL, arm64 Linux 3.18) is swallowed.
… library tests in the kernel matrix The probe gets a 3 x 0.9 s futex_time64 wait. The matrix runs futex_time64 under the app filter, the timeout tests, and the arm64 proot with a 32-bit library (seccomp on and off).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changes
build_static.sh: onetranslate_futex_time64()in PRoot for the sysenter path and the SIGSYS of the Android 8 to 10 app filter. futex runs in place of futex_time64, and the timeout of the wait operations is copied in the 32-bit layout.build_static.sh: PRoot swallows the SIGSYS of the call that it runs only to fail when it cannot change the syscall number (arm64 Linux older than 3.19 with a 32-bit program).arm64-lib32pass (the arm64 proot with a 32-bit library, seccomp on and off).Why
32-bit Go programs in the box (Forgejo, maps pmtiles) crashed under the Android 8 to 10 app filter, and a Go wait with a timeout returned at once (busy loop, 113% CPU). Jira: K2GO-598.
Steps to QA
Baseline: binaries-2026-11-26_11-23 on the LG K8 (Android 8.1, 32-bit). Forgejo crashes (SIGSEGV, port 3300 closed); the 3 x 0.9 s wait probe returns after 0 ms.
Change: a bundle with this proot. Forgejo listens on 3300,
/api/healthzpasses, the PID stays the same; the probe waits 2.9 s. Same with a 32-bit library on a 64-bit phone (Nokia 6, OnePlus 7T).Verifications
Notes
The Nokia 6 case (arm64 3.18, no NT_ARM_SYSTEM_CALL) does not show in QEMU: 3.16 has no seccomp filters and 4.4 can change the syscall number. Check it on a real phone.