Skip to content

Gamescope payload 20261029.1: glamor Mesa from upstream 26.2.6, no Xwayland fd leak on kernels before 6.0 - #2273

Merged
utkarshdalal merged 1 commit into
masterfrom
gamescope-payload-20261029-glamor-upstream
Oct 29, 2026
Merged

utkarshdalal merged 1 commit into
masterfrom
gamescope-payload-20261029-glamor-upstream

Conversation

@utkarshdalal

@utkarshdalal utkarshdalal commented Oct 29, 2026 •

Copy link
Copy Markdown
Owner

Description

Under gamescope, Xwayland composites with glamor on zink. The payload's glamor Mesa came from a local build of a 25.0-devel fork that no CI built. Its zink leaks one fd per composited frame on kernels older than 6.0 (the DMA_BUF_IOCTL_EXPORT_SYNC_FILE failure path returns without closing the fd). Xwayland reaches the fd limit and the game freezes. This froze Gravity Circuit on the Retroid Pocket Flip 2 (kernel 4.19), and it affects composited windows on any Adreno device with a kernel older than 6.0. Upstream Mesa 26.2.6 has the fix.

GameNative/gamescope#17 builds the glamor Mesa in gamescope CI from the pinned upstream 26.2.6 tarball plus two patches (android/mesa-glamor/).

This PR:

  • GamescopePayload.VERSION 20261028.4 -> 20261029.1.
  • Payload 20261029.1 = 20261028.4 with the glamor Mesa files replaced by the mesa-glamor-stage artifact of the gamescope CI run on the Update with cmod #17 head (run 40815961107; its tree 5c06a1b is identical to the merge commit 0cefd22): lib/libEGL_mesa.so.0, lib/libgbm.so.1, lib/libgbm.so, lib/gbm/dri_gbm.so, lib/dri/libdril_dri.so, and lib/libgallium-25.0.0-devel.so -> lib/libgallium-26.2.6.so. lib/libglapi.so.0 is removed (upstream folded glapi into libgallium). 50_mesa.json and every other file, bin/gamescope included, are unchanged.
  • Archive 14319163 B, sha256 047264c6b365a44dc470a043b61c39efa8d55742f6a428dac808518aacfc12e6, at the CDN root (download checked against the local file).
  • check-no-libandroid.sh: 76 ELFs, none NEEDs libandroid.so. check-payload-closure.sh: the only unresolved name is libnativewindow.so (a dlopen in libadrenotools_gamescope.so), the same as in 20261028.4. All ELFs have 16 KB alignment.
  • No daemon or jniLibs change.

Xwayland fd count on the Galaxy Tab S7 (SM-T875, Android 11, kernel 4.19), wrapper test GL window held 150 s then two GDI windows held 150 s under gamescope:

payload Xwayland fds
shipped 20261028.4 climbs about 300/s, 32767 within 113 s, then the game freezes
test payload: 20261028.4 + the #17 CI stage (pre-merge build aa304b1) start 49, GL hold 75-88, GDI hold 98-101, stable over 300 s; suite 12/12, 52 fps

The test payload was made the same way as 20261029.1, from the CI stage of #17 one commit before the head (that commit changed only check-payload-closure.sh). The release payload 20261029.1 itself was not re-run on a device.

device build payload result
Galaxy Tab S7, Adreno 650, Android 11, kernel 4.19 Legacy shipped 20261028.4 Xwayland at 32767 fds within 113 s, freeze
Galaxy Tab S7 Legacy 20261028.4 + #17 CI stage (aa304b1) fds 75-101 over 300 s, suite 12/12
Retroid Pocket Flip 2, Adreno 650, kernel 4.19 - - not tested

Recording

None. The fix shows in the fd counts above; the visible output does not change.

Type of Change

  • Bug fix
  • Performance / stability improvement
  • Compatibility improvements
  • Other (requires prior approval)

Checklist

  • If I have access to #code-changes, I have discussed this change there and it has been green-lighted. If I do not have access, I have still provided clear context in this PR. If I skip both, I accept that this change may face delays in review, may not be reviewed at all, or may be closed.
  • This change aligns with the current project scope (core functionality, stability, or performance). If not, it has been explicitly approved beforehand.
  • I have attached a recording of the change.
  • I have read and agree to the contribution guidelines in CONTRIBUTING.md.

Summary by cubic

Replaces the payload's glamor Mesa with an upstream 26.2.6 build, fixing an Xwayland fd leak on kernels before 6.0. The old 25.0-devel fork's zink leaked one fd per composited frame, pushing Xwayland to the fd limit and freezing games such as Gravity Circuit on the Retroid Pocket Flip 2 (kernel 4.19). Upstream 26.2.6 contains the fix.

Bug Fixes

  • Bumps GamescopePayload.VERSION to 20261029.1, whose glamor Mesa files come from the upstream 26.2.6 build in gamescope CI.
  • On a Galaxy Tab S7, Xwayland fds stayed at 75-101 over 300 s, versus climbing about 300/s to 32767 and freezing within 113 s before.

Written for commit 28b7895. Summary will update on new commits.

View guided diff Turn on auto-fix

Summary by CodeRabbit

  • Maintenance
    • Updated the Gamescope payload version identifier from 20261028.4 to 20261029.1. This is a metadata update; no changes to user-facing features or app behavior are described in this release.

@coderabbitai

coderabbitai Bot commented Oct 29, 2026 •

Copy link
Copy Markdown
Contributor

Review in Change Stack →

No actionable comments were generated in the recent review.

Recent review info
Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 54805605-facc-4bd5-bf86-0c1f7630c34a
Commits

Reviewing files that changed from the base of the PR and between 94b3940 and 28b7895.

Files selected for processing: 1
  • app/src/main/java/app/gamenative/display/GamescopePayload.kt

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review.

Walkthrough

The Gamescope payload version constant changes from 20261028.4 to 20261029.1.

Changes: Gamescope payload version

Layer / File(s) Summary
Update payload version
app/src/main/java/app/gamenative/display/GamescopePayload.kt
GamescopePayload.VERSION changes from 20261028.4 to 20261029.1.

Priority: Normal

Estimated code review effort: 1 (Trivial) | ~2 minutes

Change: Bug fix

Possibly related PRs

Suggested reviewers: joshuatam

Merge Risk: Minimal · up to 28b78

No actionable merge-blocking risk was identified in this version-only update.

Pre-merge checks: Passed 5
Check name Status Explanation
Title check Passed The title clearly identifies the payload version and the main Mesa and Xwayland file-descriptor leak fixes described in the pull request.
Description check Passed The description includes all required sections, explains the change and validation results, identifies the change type, and completes the checklist. It explicitly notes that no recording is available,…
Docstring Coverage Passed No eligible functions found in the changed files. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentat…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Description check

Explanation

The description includes all required sections, explains the change and validation results, identifies the change type, and completes the checklist. It explicitly notes that no recording is available, but this is a non-critical omission because the fix has no visible output change.

Full details: Docstring Coverage

Explanation

No eligible functions found in the changed files. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentation-only edits and deletions within surviving functions are included; unchanged diff context and fully deleted functions are excluded. Analyzed 0 functions across 1 files.

Finishing Touches
📝 Generate docstrings
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@cubic-dev-ai cubic-dev-ai Bot 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.

No issues found across 1 file

View guided diff | Turn on auto-fix | Re-trigger cubic

@utkarshdalal
utkarshdalal merged commit f4c631a into master Oct 29, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant