Commit Graph
2904 Commits
Author SHA1 Message Date
LunaDL e04e38b44c Feat:Add a setting to hide the Smart Glasses shortcut (#3564)
* Add persistent Smart Glasses shortcut preference

* Add Smart Glasses shortcut visibility setting

* Respect Smart Glasses shortcut visibility preference

* Add Smart Glasses shortcut setting strings

* Observe shortcut preference in Smart Glasses settings

* Test Smart Glasses shortcut visibility preference

* Keep shortcut toggle in session settings only

* Expose shortcut preference in global Smart Glasses setup

* Label Smart Glasses shortcut setting

* Verify shortcut setting is available without connected glasses

* Mark new Smart Glasses shortcut labels as English-only

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Add Smart Glasses shortcut translations

* Keep Smart Glasses shortcut labels translatable
2026-12-02 14:44:24 -05:00
LunaDL 90c7dece92 feat(ui): Add dedicated Frame Generation tab and better engine selection ( left side menu ) (#3549)
* feat(ui): add dedicated frame generation drawer tab

* fix(ui): keep frame limit label in display settings

* fix(ui): focus display controls on a stable setting

* feat(ui): simplify frame generation engine and multiplier selection

* chore(ui): clean up frame generation selector imports

* fix(ui): restore controller support in frame generation menu

* refactor(ui): keep frame generation controls always visible

* refactor(ui): show frame generation controls inline

* chore(ui): remove obsolete frame generation focus import

* fix(ui): register frame generation engine focus

* fix(ui): remove obsolete frame generation menu host

* fix(ui): update frame generation menu call sites

* fix(ui): stack frame generation controls and restore focus

* fix(ui): gate legacy frame generation card menu

* fix(ui): gate legacy frame generation sheet menu

* Fix FrameGenMenu call signature

* Show frame generation controls only when opened

* ci: trigger checks

* feat(ui): add always-visible frame generation off option

* feat(ui): keep frame generation controls visible

* feat(ui): add custom frame generation vector icon

* feat(ui): use custom icon for frame generation tab

* fix(ui): restore adaptive LSFG target picker

* fix(ui): remove excess top spacing in frame generation menu

* Fix FrameGenMenu disabled-state handling

* Format FrameGenMenu multiplier row

* Add tighter Frame Generation control spacing

* Tighten Frame Generation drawer spacing

* Replace Frame Generation icon with new vector

* Keep legacy Frame Generation buttons available

* Use legacy Frame Generation buttons outside drawer

* chore: trigger CI
2026-12-02 14:32:24 -05:00
Kurt Himebauch 6d78142a67 fix(gamescope): SDR games keep their brightness while Steam's overlays are composited over them (#3590) 2026-12-02 14:28:03 -05:00
5cd6fe8864 feat(session): run the session outside Android's child-process count (#3338)
* docs: research Android's child-process limit without developer options

* docs: confirm the child-process gaps on the Thor

* feat(session): start long-lived daemons in uncounted worker processes

* feat(nativeguest): hand long-lived programs to uncounted worker processes

* test(session): run the session bus block with dd_spawn

* test(nativeguest): cover the exec handoff's wait and kill

* feat(session): run the session root, its jobs and the gamescope chain outside the child-process count

* feat(setup): the child-process limit no longer blocks Steam while the session runs in workers

* feat(audio): run PulseAudio outside the child-process count

* feat(nativeguest): hand off posix_spawn children and keep handed-off daemons alive

* fix(nativeguest): let Steam end a handed-off game and keep process-group signals

* perf(session): exec a worker as soon as its reply is in and keep two bound ahead; fix review findings

* fix(nativeguest): address review findings in handoff waits, signals and spawn errors

* fix(session): commit each worker launch explicitly and keep workers with the session that asked

* fix(session): let a worker wait for its launch commit on the main thread

* fix(session): confirm handoffs, honour wait selectors and stop spawns at teardown

* fix(session): one owner per handoff exit, worker launch answers and spawn edge cases

* fix(session): send a working directory outside the program's root by its real path

* fix(session): recheck a taken exit's child and commit a launch only on a whole go line

* fix(session): three-step launch, tagged exit reports and lock-free popen and system children

* test(native): popen test shell is static, as the other hook fixtures

* test(native): run the popen test program with a clean environment

* test(native): skip the popen test where a spawn child cannot exec aarch64

* fix(session): confirm the hook before the worker runs, prefer a late report and free a reused pid

* fix(session): tell a reused pid's old entry by start time, not the reaped flag

* fix(session): silent failed launches, bounded spawn requests and held check-gone writes

* test(native): check the unlisted child's status only where a child can exec aarch64

* fix(session): every exit-only waitid goes through the handoff wait

* fix(handoff): exact waitid events, safe exit timer, bounded request receipt

* feat(handoff): hand off shell children near Android's process limit

* fix(agent): tag handed-off game windows outside the reaper

* fix(handoff): a handed-off program's getppid() is its forking process

* fix(handoff): exact waitid selection, kept Steam and pipe readers, held reports

* fix(handoff): getppid() gives init for an exited or replaced parent

* fix(handoff): keep __WALL waitid calls on the handoff path

* test(handoff): require a zombie parent in the unreaped-parent case

* fix(handoff): honor __WNOTHREAD and check every argument for Steam

* fix(handoff): stop waiting on a held entry once its parent has exited

* fix(handoff): __WNOTHREAD on waits for a pid, flags on every shim reap

* fix(handoff): keep the forking thread of each child in the parent

* fix(handoff): a wait that finds no child rechecks live handoffs

* fix(handoff): keep a child's forking thread until its end is taken

* fix(handoff): the thread selector applies to claims in progress too

* fix(handoff): controlling-terminal check via /dev/tty, owned records only

* fix(handoff): a child whose forking thread ended is any thread's

* fix(handoff): a parent /proc cannot read is checked with kill(), then given up

* fix(handoff): one-word fork records, changed only by compare-and-swap

* fix(handoff): watch the forking parent through a pidfd opened at start

* fix(handoff): fork records by pid, a gone thread's children go to the main one

* fix(handoff): keep the parent pidfd through dup2 and check it before use

* fix(handoff): no handoff without fork records, unknown thread state keeps the owner

* fix(handoff): undo a pidfd move when dup fails, recheck it after the poll

* fix(handoff): fresh fork records in a forked child, heir is the first live thread

* fix(handoff): one lock over a pidfd move, its dup and the undo

* fix(handoff): liveness check under the pidfd lock, forget only a reaped pid's record

* fix(handoff): lock only dups onto the pidfd, with signals blocked

* fix(handoff): fork record generations, no pidfd restore after a failed move

* fix(handoff): every dup in a pidfd process locks, fork prep blocks signals

* test(semaphores): tell a child hung in qemu-user from a guest deadlock

* fix(handoff): fork records matched by the child's start time, never removed

* test(semaphores): count only reaped children, only futex waits as emulator stalls

* fix(handoff): a known-start bit in fork records

* fix(handoff): dup bookkeeping before the pidfd lock, newer fork records kept

* fix(handoff): a fork record stays only for the pid's current process

* fix(handoff): keep a pending child's fork record when an older fork records late

* fix(handoff): an unknown-start fork record never replaces a pending one

* fix(handoff): self-recorded forks, ELF and wait option checks, both nofile limits

* test(handoff): find the module in the namespace run under discover too

* fix(handoff): a spare parent pidfd made at start, so a dup2 onto it makes no fd

* test(handoff): require ENOEXEC for an ELF stub; skip the namespace run without binfmt

* fix(hook): change the kept fd list under a sequence lock; readers take a copy

* fix(handoff): one report per handed-off child; stops keep a claim; nested waits keep their selector

* fix(hook): a table made at runtime outlives closes begun before it; unknown-start fork records kept

* fix(handoff): waits look before they reap, so a handed-off fork's child is never reported

* fix(hook): settle waits out earlier epochs; unknown-start fork records kept for any handoff under way

* fix(handoff): generation-checked reap marks, stops taken as stops, close counts reset in a fork

* fix(handoff): one given-up table at most, whole stop codes and rusage, WNOWAIT exits rechecked

* fix(handoff): requests name their session; stops of handed-off programs reported; cancellable look

* fix(handoff): table setup not cancellable; test spawner never runs what it cannot end

* fix(handoff): job-control jobs stay counted; unnamed requests refused; cancel-safe setup

* docs(phantom): job-control jobs stay counted; listed programs report no stops

* fix(handoff): a listed program a shell runs as a job-control job stays counted

* refactor(hook): kept descriptors in their own part, a handoff matched by another program

The descriptors close(), close_range() and closefrom() leave open move from
privileged.c to hook/kept.c (unchanged), so the bionic runtime's exec shim can
build the handoff with them. ddh_try_as() matches DD_HANDOFF against one
program and sends another: the bionic shim sends "/system/bin/linker64 PROGRAM
ARGS" and lists it by PROGRAM. ddh_try() is ddh_try_as() with both the same.

* feat(bionic): hand the bionic runtime's Wine programs to the app's workers

The glibc session's hook never sees DroidDeck-Bionic's processes (Wine on
Android's libc), so a bionic game's Wine programs all stayed counted under the
worker running the tool's launch.sh. The handoff is now built into the
runtime's exec shim (tools/bionic-runtime/handoff.c, part of libexecshim.so):

- hook/handoff.c and hook/kept.c with what the native hook's other parts do
  around them: fork(), close(), close_range(), dup2(), dup3(), and exit() for
  the on_exit() bionic lacks
- bionic's execv(), execvp(), execl*() reach the execve system call inside
  libc, past execshim's execve(); Wine starts its preloader with execv(), so
  the shim defines them on top of its execve()
- a linker64 start is listed by its program
- the app starts a handed-off program from the glibc root's bash, which cannot
  load the runtime's LD_PRELOAD/LD_LIBRARY_PATH: they go as arguments of
  /system/bin/env, which puts them back for the program
- launch.sh keeps DD_SPAWN, DD_SPAWN_SESSION, DD_HANDOFF*, DDH_* and
  DDNATV_ROOT, and its /proc/N/environ reads no longer print "Permission
  denied" for idle workers (2>/dev/null before the redirect)

Pocket FIT, DroidDeck-Bionic 14.1-r67 with this shim and launcher, handoff on:
counted during Brawlhalla 25 -> 17, DiRT Showdown 24-27 -> 16, whole run
28 -> 19-20; with Android's limit on no DroidDeck process and no other app's
process was killed (before: Discord, BatteryLog helpers); DiRT 75 fps either
way. docs/phantom-processes.md: "The bionic runtime".

* fix(bionic): hand off only starts that would succeed here; bionic's execvp fallbacks

Review follow-ups on the bionic runtime's handoff (tools/bionic-runtime/handoff.c):

- A start is handed to a worker only when it would get past execve() in this process: the file is a
  regular executable outside the app's data (Android refuses execve() there), and for a linker64 start
  the program it loads is a readable regular file. A start that failed in the worker failed where the
  caller could not see it, so Wine never tried its next candidate. The hook's own check looked at
  /system/bin/env, not the program.
- A start whose argv[0] is not its file stays here: env starts FILE with FILE as argv[0]. linker64 and
  interpreter starts are unaffected (their argv[0] is the file). An empty argv stays here too.
- Nothing is built for the handoff without DD_SPAWN and DD_HANDOFF.
- execvp()/execvpe()/execlp() follow bionic's: an unset PATH is libc's default, an empty PATH or entry
  is the current directory, and a file the kernel cannot start (ENOEXEC) runs under /system/bin/sh.
- close_range() refuses first > last and unknown flags before it splits the range or unshares the table.
- The debug line reads the table's owner only once the table is seen published.

* fix(bionic): hand off app-data starts only where SELinux lets them run; bare names stay here

Follow-up to 7d95564f7 (review, and a Pocket FIT test of its pack):

- 7d95564f7 kept every start of a file in the app's data here. Wine's preloader is one (a static ELF,
  so execshim.c cannot make it a linker64 start), and where SELinux is permissive, as on AYANEO's
  firmware, it runs: Wine then never reached its loader, and its programs ran here, counted again
  (Pocket FIT: Brawlhalla 26-28 counted vs 16-17 before). Where SELinux enforces, Android refuses the
  exec, here and in a worker alike, and Wine falls back to its loader, which goes as a linker64 start.
  Such a start is now handed off when /sys/fs/selinux/enforce reads 0, and stays here otherwise
  (also when the setting cannot be read).
- The program a start would run is checked with the hook's own ddh_startable() (an ELF the kernel
  loads with its interpreter there, or a script with its interpreter): for a linker64 start, the
  program it loads.
- A file name without '/' stays here: env would look it up in PATH, the exec here in the caller's
  working directory.
- execvpe() skips a PATH entry whose candidate exceeds PATH_MAX (ENAMETOOLONG) instead of copying
  it onto the stack.

* fix(handoff): spawn blocks signals and cancellation across the fork; root flag stored under the stop lock

* fix(handoff): a thread that unshares its fd table keeps its own copy of the kept fds

* fix(handoff): register the kept list's fork handlers before a split takes its lock

* test(handoff): cover WNOHANG with a held forked child, early reaps, blocked waitid and pidfd parents; keep the counted-process exception in translations

* test(handoff): exited-entry precondition, atomic checkpoints, a pidfd-only zombie check; validate the shim hold fd

* test(handoff): WNOHANG with two handed-off children and for a group; a program's exit while its entry is held

* test(handoff): a held exit with no free fd, with and without the parent's pidfd

* test(handoff): held-exit tests require the program's own exit status

* test(handoff): time held exits from the run, and only once the program is at its exit

* perf(handoff): keep the asker's priority, quick tools local, workers bound ahead of a game (#3582)

Three fixes that bring handoff-on speed to within 1-2 % of handoff off
(AIO D3D11 same session: 3196 -> 3520 fps, 1 % low 444 -> 637) with the
same counted processes (benchmark mean 18.5, peak 23):

- A handed-off program keeps its asker's priority. Workers are bound
  from the top app with BIND_IMPORTANT, so Android boosts their main
  thread to THREAD_PRIORITY_TOP_APP_BOOST (-10); the program the worker
  execs inherited it. The asker's nice value is sent with the request and
  set before execve, and a watcher resets it if Android boosts it again.
- Quick script tools (awk, sed, grep, cat, ...) stay where they are when
  the count is near the limit. Sent to a worker, the forked child waits
  (counted) while a worker starts; run locally it is counted for a few ms.
- Workers are bound ahead when a Steam game is queued (16 for 20 s), so
  Wine's services do not wait on zygote forks at game start.

---------

Co-authored-by: The412Banner <[email protected]>
Co-authored-by: The412Banner <[email protected]>
2026-12-02 14:02:55 -05:00
Kurt Himebauch 186bae8f3e feat(native): run the desktop, its apps and shells as an ordinary user instead of fake root (#3587)
* feat(native): run the desktop, its apps and shells as an ordinary user instead of fake root

* fix(native): a script's interpreter takes DDNATV_BECOME, so sudo runs scripts as root

* fix(desktop): keep the Plasma start line the pipewire tests slice the script at
2026-12-02 13:50:06 -05:00
Kurt Himebauch 3bb22dc92b fix(native): terminals use the ioctls Android allows on an app's pseudo-terminal (#3585)
* fix(native): terminals use the ioctls Android allows on an app's pseudo-terminal

* fix(native): leave a terminal request alone when its register is read before the high half
2026-12-02 13:47:59 -05:00
LunaDL f3f410059d Feat:Add separate orientation settings for Steam and desktop sessions (#3567)
* Add per-session orientation preferences

* Apply orientation preference for active session

* Use session-specific orientation for output following

* Test independent session orientation preferences

* Map run sessions to Steam orientation preference

* Add separate Steam and desktop orientation controls

* Cover session mode orientation mapping

* Persist in-session orientation by session mode

* Refresh inherited orientation settings after global change

* Resolve window and portrait orientation by session mode

* Use session orientation for output sizing and window behavior

* Test mode-specific window and portrait orientation

* Refresh session orientation choices on resume

* Refresh session orientation choices on resume

* Use Compose lifecycle owner import

* Trigger CI
2026-12-02 12:29:52 -05:00
MaxsTechReview 6e7908ed81 fix(display): copy the game and the window above it in one GPU submit (#3583)
* fix(display): copy the game and the window above it in one GPU submit

When a game's frames go on the layer-copy path and a window sits above
the game, each scene copied the game frame and then the window above it
with two separate submits and two CPU waits. Each wait queued behind
the game's own GPU work, so a GPU-bound game lost on-screen frames to
the second wait.

Record both copies in one command buffer, merge their release fences,
and wait once per scene. The zero-copy path and the single-layer copy
path are unchanged.

* Check overlay eligibility against the frame's own game geometry and keep both release waits when a fence merge fails
2026-12-02 12:12:08 -05:00
LunaDL 9ca6fa064e fix(bionic): the WSI layer uses its normal bypass check, and zero-copy fallbacks log their reason (#3487)
The Bionic launcher no longer forces the WSI layer's XWayland bypass; the layer runs its normal eligibility check, cached for 100 ms. The compositor logs, rate-limited, why a frame or layer candidate leaves the zero-copy path: no registered gralloc buffer, a failed direct present, or a rejected candidate draw.

Tested on a 60 Hz Adreno handheld with the forced bypass on and off and with two driver versions: every run stayed on the zero-copy path at about 60 fps.
2026-12-02 04:04:53 -05:00
MaxsTechReview aab15f3146 fix(display): copy zero-copy frames that carry no acquire fence (#3427)
When a frame's acquire fence cannot be exported from its dma-buf, the frame takes the layer-copy path instead of reaching the display unfenced. Fixes #3410.
2026-12-02 03:29:48 -05:00
Kurt Himebauch 11af78340a fix(gamescope): keep forwarded buffers alive while waiting for scanout, and composite at full rate (#3560)
* fix(gamescope): a pending scanout wait keeps its forwarded buffer alive

Patch 0147 waits for scanout on a forwarded client buffer with a raw
pointer to its CWaylandFb. If the buffer was shown again and the next host
release found scanout already over, that release dropped the last
reference while the earlier wait was still queued, and the wait then
called OnScanoutDone on a freed buffer. The wait now holds a reference
until it finishes.

* fix(gamescope): composite every frame when the host releases buffers before scanout

Holding a forwarded client buffer until scanout ends (0147) costs a three-buffer
client a third of the refresh rate: Steam's UI ran at 80 fps on a 120 Hz screen.
Once the backend sees a forwarded buffer released while it is still being
scanned out, it composites every frame into its own output images, which 0146
reuses at latch. The Steam UI runs at 120 fps again on the Pocket FIT.

* Pin the gamescope build with the scanout wait reference and full-rate compositing
2026-12-02 00:54:29 -05:00
MaxsTechReview 2c95ebd22d fix(input): the middle of a crossed on-screen D-pad presses the nearest arm (#3558)
* fix(input): the middle of a crossed on-screen D-pad presses the nearest arm

Four direction buttons laid out as a cross left an empty square in the
middle, so a touch there fell through to the mouse. A touch inside the
cross now picks the arm on that side, for the stock pad and any custom
layout with the same shape.

* fix(input): take the D-pad middle for hand-placed arms that are not exactly centred

* fix(input): limit the D-pad fallback to its middle and find the cross among duplicate arms

* fix(input): D-pad middle picks the nearest arm and needs overlapping opposite arms

* fix(input): D-pad middle measures the distance to each arm itself

* fix(input): D-pad middle weighs every matching arm set
2026-12-01 22:15:02 -05:00
MaxsTechReview 7ce53ccbed fix(tabs): keep More on the bar so tabs can always be edited (#3556)
Edit tabs only opens from the More page, and More left the bar once no
tab was shelved in it. Hiding or moving every shelved tab therefore
removed the only way back into the tab editor. More now always stays on
the bar; with nothing shelved it opens to the Edit tabs button.
2026-12-01 20:33:08 -05:00
Kurt Himebauch 1b4aaf8a3b feat(drawer): fold session menu groups into summarized sections and regroup pages (#3550)
* feat(drawer): fold session menu groups into summarized sections and regroup pages

* chore(drawer): drop unused strings

* fix(drawer): observe controller state, drop stale achievements, stable section keys
2026-12-01 20:26:14 -05:00
Kurt Himebauch 4793d1df62 fix(display): the Game Mode FPS override caps the frames the guest draws (#3388)
fix(display): the Game Mode FPS override caps the frames the guest draws, not only the ones shown
2026-12-01 20:10:34 -05:00
Kurt Himebauch 9dfbc05933 fix(droiddeckctl): gamepad and pen input on Android 13 and 14 QPR1 (#3530)
* fix(droiddeckctl): gamepad and pen input on Android 13 and 14 QPR1

* fix(droiddeckctl): read the pen's codes before its bus so Android 14 QPR1 retries numerically
2026-12-01 10:32:06 -05:00
MaxsTechReview 8ec6e646d9 fix(effects): CAS addresses the scene with its pushed input size (#3519)
CAS derives texel centres from the input size in its push constants instead of textureSize on the imported scene image, as the previous CAS shader did. Fixes the grid of black marks with CAS on 10-bit game images on Adreno 8xx.
2026-12-01 10:11:30 -05:00
Kurt Himebauch 41412450fd feat(bottom): Steam menu and Quick Access side by side on the bottom screen (#3501) 2026-12-01 09:52:13 -05:00
MaxsTechReview bf772b7c55 ci(desktop): build KWin 6.8.3 to match the Arch Linux ARM package (#3526) 2026-12-01 09:09:51 -05:00
MaxsTechReview 29b04b66eb fix(gamescope): hold forwarded client buffers until the display finished scanning them out (#3516)
* Return a forwarded client buffer to its client only after the display finished scanning it out

* Test that a forwarded client buffer waits for scanout and composite images do not

* Pin the gamescope build that holds forwarded client buffers until scanout ends
2026-12-01 06:02:16 -05:00
MaxsTechReview 044c8ee475 fix(gamescope): a composited cursor no longer forwards the default arrow to the host (#3510) 2026-12-01 03:55:33 -05:00
MaxsTechReview ca499115ac fix(zero-copy): merge a second release fence into the pending fence wait (#3509)
When the kernel cannot attach a display release fence to the buffer, the
compositor waits on the fence itself. A second release of the same buffer
before that fence signalled overwrote the pending wait, so the first wait
removed the second one and then fired again with no source to remove,
crashing the compositor and losing the session.

A second unsignalled fence is now merged into the pending wait, and a
signalled or attached one leaves the pending wait in charge of the
deferred release.
2026-12-01 02:55:37 -05:00
The412BannerandThe412Banner d7898360e3 fix(input): keep the glibc-only __chk_fail out of the bionic build (#3492)
DroidDeck-Bionic preloads libfakeinput.so into its Wine processes
(tools/bionic-runtime/build.sh builds fakeinput_steam.cpp for bionic). The
fortified read/poll/ppoll entry points (#2916) call glibc's __chk_fail, which
bionic does not export, so the bionic build of the library cannot be loaded:
"CANNOT LINK EXECUTABLE .../wine: cannot locate symbol "__chk_fail"" and no
Wine program starts. Every DroidDeck-Bionic pack built from main since #2916 is
affected (r67 predates it).

The bounds failures now go through fakeinput_chk_fail(): abort() on bionic,
__chk_fail() as before on glibc. tools/tests/test_fakeinput_bionic.py fails if
__chk_fail is named outside the non-bionic branch again.

Co-authored-by: The412Banner <[email protected]>
2026-11-30 19:48:33 -05:00
LunaDL fcd197934a test: fix effects source cache harness initialization (#3490) 2026-11-30 18:15:04 -05:00
FryMcNuggetandFryMcNugget 768661928e feat(agent): connect the agent on Quest, which has no pairing screen (#3445)
* feat(agent): connect the agent on Quest, which has no pairing screen

Quest hides Android's Wireless debugging pairing, so the agent's connection
step could not be completed there. On a Quest the step's action is now Allow:
DroidDeck connects to adbd on 127.0.0.1:5555 (after a one-time `adb tcpip 5555`
from a computer) and the headset asks "Allow debugging?" for DroidDeck's key.
Wireless debugging accepts a key allowed that way, so the saved loopback
connection then works like a pairing.

DroidDeck also declares WRITE_SECURE_SETTINGS. When it is granted over adb,
DroidDeck turns Wireless debugging on itself before looking for its port.

* fix(agent): keep the Quest setup hint visible and report a declined prompt correctly

A late connection lookup no longer overwrites an Allow that is running.
On a Quest, the connection row shows its status above the full hint, which
holds the one-time commands. The failure message no longer claims port 5555
was silent, since a declined or unanswered prompt fails the same way.

* fix(agent): connection checks from before an Allow no longer overwrite it

A check started before Allow could land after it and mark the step as not
done, or replace the prompt instructions while Allow was still waiting.
Each Allow now starts a new generation, and older connection results are
dropped, as are results that land while Allow is running.

* ci: rerun after the Maven 429 rate limit

* fix(quest): turn Wireless debugging on by itself only on Quest

Other devices keep exactly their pairing flow even if WRITE_SECURE_SETTINGS
is granted. Once connected, the Quest agent row shows its usual short hint
instead of the setup instructions.

* fix(quest): connect after a reboot without a second Allow

After a reboot, turning Wireless debugging on makes the Quest ask again to
allow it on this network, and the 2 s wait ran out before that was
answered, so the row showed Allow. Allow then failed, since port 5555 is
closed after a reboot. The lookup now keeps trying for up to 30 s after
turning Wireless debugging on, and Allow first tries the already-trusted
key over Wireless debugging before asking on port 5555.

* ci: rerun after download timeouts in the Python tests

---------

Co-authored-by: FryMcNugget <[email protected]>
2026-11-30 15:10:08 -05:00
LunaDLandmaxjivi05 18cd1cf07f Fix: reclaim DD-FG scratch resources on rebuild (#3456)
* Prepare FrameGen for instance-owned scratch lifecycle

* Make DD-FG rebuild and teardown completion-aware

* Restore DD-FG namespace boundary

* Isolate DD-FG scratch state and reclaim resources on rebuild

* Declare per-instance scratch builder before recording code

* Make DD-FG ring teardown report unsafe GPU completion

* Retain DD-FG input ring until GPU completion is confirmed

* Add DD-FG lifecycle and resource-isolation tests

* Cover DD-FG teardown and rebuild failure cases

* Document DD-FG scratch ownership and teardown semantics

* Guard DD-FG teardown when GPU completion cannot be queried

* docs: clarify DD-FG device-loss teardown

* fix: define DD-FG scratch state before resize

* fix: define DD-FG scratch state before resize

* fix(ddfg): wait for the GPU before replacing the input ring on resize

* Fix DD-FG ring cleanup after device loss

* Propagate DD-FG device-loss status

* Retain DD-FG resources when GPU completion is unknown

* Retain DD-FG resources when GPU completion is unknown

* Retain DD-FG resources when GPU completion is unknown

* Retain DD-FG resources when GPU completion is unknown

* Retain DD-FG resources when GPU completion is unknown

* Retry DD-FG cleanup after an idle-wait failure

* Test DD-FG cleanup retry after GPU wait failure

---------

Co-authored-by: maxjivi05 <[email protected]>
2026-11-30 15:04:16 -05:00
LunaDL 41f15b03bb feat(framegen): add spatial post-upscale per presentation (#3454)
* feat(framegen): add spatial post-upscale per presentation

* Fix framegen post-upscale expectations

* test: run framegen post-upscale assertions

* test: verify framegen postprocessing image handles

* test: capture framegen screen blit source
2026-11-30 15:03:52 -05:00
LunaDL 5c887bfc59 Perf: Create screen-effect pipelines on demand (#3453)
* perf: create screen-effect pipelines on demand

* fix: prepare screen-effect fallback pipelines

* docs: describe lazy screen-effect pipelines

* test: guard lazy screen-effect pipeline setup
2026-11-30 15:03:30 -05:00
LunaDL 430d777c5c Fix: Fix right stick highlights and preserve zoom bindings (#3440)
* fix(input): stop stale right-stick page scrolling

* fix(input): preserve other bindings when saving an action

* test(input): cover zoom commands on same control category

* test(input): remove unnecessary zoom binding cases

* style(input): remove added inline comment
2026-11-30 15:02:30 -05:00
MaxsTechReview 5f129fb4db fix(native): allocated getcwd and realpath results name the guest mount (#3481)
getcwd(NULL, ...) and realpath(path, NULL) returned the host path of a
session mount whenever its guest path was longer than the host path,
because the translation had to fit the buffer the C library allocated.
Shells export that host path as PWD, and Wine prefers a valid PWD, so a
program started from an added game folder on a removable card got a
working directory it could not open and started in the Windows folder.
Grow the allocated result to fit the guest path.
2026-11-30 14:24:10 -05:00
MaxsTechReview 7404fba5a3 fix(battlenet): an install folder chosen in Battle.net on the library's drive is kept (#3479)
* fix(battlenet): an install folder chosen in Battle.net on the library's drive is kept

Every open set Battle.net's default install folder back to the library folder whenever the two differed, so a folder the user picked in Battle.net on the same drive was replaced on the next open. The folder is now only moved to the library when it is unset, missing, or on another drive.

* fix(battlenet): check the trimmed folder against the rootfs drives
2026-11-30 14:24:05 -05:00
MaxsTechReview 54ca518553 fix(storage): a card library the session cannot open by its raw path is opened by its storage path (#3475)
A game storage folder saved as a raw volume path is opened through the volume's /storage path when only that one is usable, and its private directories are kept under either path. Battle.net is only given a library folder when the configured one is attached, so a missing card no longer moves its install folder to internal storage.
2026-11-30 12:00:05 -05:00
MaxsTechReview 72c8b8426d fix(input): Windows games see the gamepad again when the pad is not read through SDL (#3469)
Since each pad was described to Wine's udev backend with the identity its
SDL backend sees, the udev backend left every pad to SDL. Where SDL does
not open the pad, such as a session without proot, Windows games lost both
the gamepad and the on-screen controls.

The udev backend owns the pads again with the Steam Input identity it had
before. SDL inside Wine's bus driver now reads the same identity for those
pads and skips them as it skips any Steam Input pad, so each pad is still
listed once and both triggers keep reading together.
2026-11-30 08:53:12 -05:00
xlulx 6dc3d01674 fix(display): apply a client's commit only after its GPU has finished writing the buffer (#3004) 2026-11-30 04:23:04 -05:00
MaxsTechReview df2cfa40b3 test(xbox): cover device-limit diagnostic routing (#3458) 2026-11-30 01:38:08 -05:00
MaxsTechReview e101a78791 fix(stores): the front end no longer crashes on start when the Steam engine starts on the refresh thread (#3457)
Keep the Steam install picker state out of the Steam engine object

The picker state lived on SteamStore, which is first touched from the
background stores refresh thread. On the Compose runtime in use, a state
object created outside a snapshot while the composition holds an open
snapshot is unreadable inside it, so the front end crashed on startup
with "Reading a state that was created after the snapshot was taken".
The state now lives on StoresState next to the other UI-facing store
state, and SteamStore holds no Compose state.
2026-11-30 00:02:07 -05:00
The412Banner aaa9fb129c fix(nativeguest): programs on a mount kept at its host path start as guest programs (#3211) 2026-11-29 23:58:32 -05:00
MaxsTechReview 23d7e639ca fix(steam): mark ARM64-uninstallable tool dependencies installed (#3443)
* fix(steam): mark ARM64-uninstallable tool dependencies installed

The ARM64 client cannot install Proton EasyAntiCheat Runtime (1826330),
which it refuses as an invalid platform, or that tool's Steam Linux
Runtime 1.0 (scout) dependency (1070560), which has no ARM64 depot. After
the EULA hand-off the client starts the dependency install and aborts in
glibc's smallbin check.

Write the bare installed manifest DroidDeck already uses for adopted games
for those two tools before the client starts: only on the ARM64 client,
only when appinfo shows no ARM64 depot, and never over a fully installed
manifest.

Refs: ValveSoftware/steam-for-linux#13937, DroidDeck #2313

* fix(steam): seed a tool only when no library has it installed, and write manifests atomically

A partial manifest in the first library no longer hides a full install in
another one, and a failed write leaves no truncated or stray manifest.

* fix(steam): publish tool manifests without replacing concurrent installs
2026-11-29 23:38:39 -05:00
MaxsTechReview 4ef23ed0e9 Return to the DroidDeck UI when logging out of the desktop (#3374)
* fix(desktop): Log Out returns to DroidDeck, Return to Gaming Mode opens Steam

Both ended Plasma through the same logout call and the desktop script always
started Steam afterwards. Return to Gaming Mode now leaves a request that the
script reads; a plain Log Out ends the desktop. The app ships the shortcut
with the script so both always change together.

* Wait for the logout reply so a cold Shutdown service still gets the request

* Forget the return to gaming mode when the logout request fails
2026-11-29 23:04:31 -05:00
ff35cce127 fix(steam): GTA III on Steam starts a new game (full x87 precision for app 12100) (#3197)
The Steam copy (AppID 12100) died on "Start new game" at 0042A703: FEX's reduced x87 precision turns a float into a bad pointer. GameEnvironment.knownGames sets FEX_X87REDUCEDPRECISION=0 for it, above the shared settings and below the game's own, and picking a FEX preset for the game keeps the fix.

Co-authored-by: Unixcision <[email protected]>
Co-authored-by: Kurt Himebauch <[email protected]>
2026-11-29 22:51:35 -05:00
Tamim KabirandKurt Himebauch 0951b602b7 fix(input): programs built with _FORTIFY_SOURCE read the virtual pads (#2916)
* fix(input): programs built with _FORTIFY_SOURCE read the virtual pads

Fortified builds, Flatpak runtimes among them, call __read_chk, __poll_chk
and __ppoll_chk in place of read, poll and ppoll, and glibc's versions go
straight to the kernel. Such programs opened a pad through the shim but read
its backing ring file instead of events, so they never saw input: Marathon
Recompiled's SDL reads the pad through __read_chk.

The shim now provides all three, with glibc's bounds checks, on the same
paths as read, poll and ppoll.

* fix(input): keep glibc's __read_chk for descriptors that are not pads

Only pad descriptors take the shim's read path; the rest go to the next
__read_chk, so fortified reads keep libc's cancellation point. The test
also polls the empty ring with a zero timeout, which a __poll_chk that
bypasses the shim would report as ready.

---------

Co-authored-by: Kurt Himebauch <[email protected]>
2026-11-29 22:51:30 -05:00
LarzVaderandKurt Himebauch 57055be6fb fix(ci): Robolectric's jar cache is saved again, and a Maven 429 runs the unit tests again (#3418)
* fix(ci): Robolectric's jar cache is saved again, and a Maven 429 runs the unit tests again

* fix(ci): retry Gradle artifact download rate limits too

* fix(ci): restrict Maven retry to dependency download exceptions

---------

Co-authored-by: Kurt Himebauch <[email protected]>
2026-11-29 21:13:54 -05:00
MaxsTechReview c6743730aa Keep a signed-in store's Library tab when its game list is empty or failed to load (#3449) 2026-11-29 20:24:34 -05:00
MaxsTechReview 780c5658d0 fix(input): each pad is listed once in Windows games so both triggers read together (#3436)
* fix(input): each pad is listed once in Windows games so both triggers read together

A pad that Wine's SDL backend also reads was described to Wine's udev
backend as a Steam Input virtual pad, so Wine built two devices for one
pad. SDL RawInput games could not match the two and read held triggers as
released. The pad now keeps the identity the SDL backend sees unless that
backend is told to skip it.

Rumble that Wine starts through SDL is now held until the next update,
matching the udev path, instead of stopping after one second.

* fix(input): hold only the rumble Wine starts through SDL, not later SDL rumble in the same process

* fix(input): read @file SDL ignore lists when choosing the pad identity

SDL reads the ignore and except lists from a file when the value starts
with @. Match the ring pad ID against that file's contents too.

* fix(input): parse SDL controller ID lists the way SDL does when choosing the pad identity
2026-11-29 20:24:20 -05:00
MaxsTechReview a9e8a01bb6 fix(native): prepare the rootfs before a helper starts outside a session (#3447)
Prepare the rootfs before a native program starts outside a session

The linker and libc are patched for Android's seccomp filter only when a
session starts. A helper started between sessions, after a runtime
update and before the first session, ran the unpatched linker and died
of SIGSYS (exit code 159). The shared native process builder now
prepares the rootfs itself when no session is running.
2026-11-29 19:44:11 -05:00
MaxsTechReview 861121144c fix(xbox): try the next listed executable when one is missing (#3446)
A package can list several PC executables while shipping only some of them. Try each listed executable in order and fail only when none of them exist.
2026-11-29 19:33:55 -05:00
d7fcea74b4 fix(mali): Auto respects Venus turned off and picks the bridge on Mali-G2-Ultra (#3198)
* fix(mali): Auto respects Venus turned off and picks the bridge on Mali-G2-Ultra

With GPU drivers on Auto, Mali (Venus) was turned back on after the user turned it off. Auto now respects that choice, and picks the bridge on Mali-G2-Ultra, where Steam's web helper dies on its first window through Venus (#2879). When Auto itself turns Venus off it clears the stored key, so its own decision does not read as the user's later.

* fix(mali): clear Auto-owned Venus preference when fallback ends

---------

Co-authored-by: Unixcision <[email protected]>
Co-authored-by: Kurt Himebauch <[email protected]>
2026-11-29 17:17:51 -05:00
sergeymetallicandsergeymetallic 44b429ca20 fix(game-env): resolve store launcher executable from sidecar (#3288)
* fix(game-env): resolve store launcher executable from sidecar

Store titles launched through .droiddeck-launch.bat passed the wrapper
path directly into engine_fixes and other exe-based checks, so stem
checks saw .droiddeck-launch and game_files scanned from the install
root rather than the executable's folder. For Epic's Batman: Arkham
City, Binaries/Win32/BatmanAC.exe sat one level deeper than game_files
scans, so arkham_city_x87 never set FEX_X87REDUCEDPRECISION=0.

Resolve .droiddeck-launch.bat to the validated exe entry from
.droiddeck-store.json when inspecting the game, while keeping the
launcher path in the Proton command.

* fix(game-env): reject parent segments before normpath in store_game_exe

os.path.normpath lexically collapses symlink/../file before the
filesystem is consulted, which could validate a different file than a
symlinked subdirectory path denotes. Reject any ".." path component
after separator normalization before calling os.path.normpath.

---------

Co-authored-by: sergeymetallic <[email protected]>
2026-11-29 16:18:43 -05:00
Dhiman SealandKurt Himebauch c91b100bc1 fix(game-env): run Inno Setup installers with the FEX Stability settings (#3069)
* fix(game-env): run Inno Setup installers with the FEX Stability settings

An Inno Setup installer added as a game stops with Wine's "Path not
fpund." dialog under the default FEX preset. The 32-bit setup stub
corrupts its own paths before it opens its archive (#1277, #3067). #1174
avoids the stub only for GOG installs, by extracting them natively.

droiddeck-game-env now finds the stub by the setup loader's offset-table
ID in its resources, or the "Inno" marker older loaders keep at 0x30, and
launches it with the Stability preset's FEX settings. A FEX preset chosen
for the game itself still wins.

Fixes #3067

* fix(game-env): name only the preset seen to corrupt Inno Setup paths

The launch note and the docs said the faster presets corrupt the setup
stub. Only the default Performance + TSO preset was seen doing it.

* fix(game-env): give Inno Setup installers started with run the Stability settings

The run verb skips engine_fixes and gets only the sync settings, so an installer started that way kept the inherited Performance + TSO preset. Apply the Stability values on that path too; explicit game settings still win in apply_config.

* fix(game-env): keep the game's own FEX settings for installers started with run

The run path filtered the game entry down to sync keys, so a FEX preset
chosen for the game was replaced by the installer's Stability settings,
and a null could not unset a preset key. Copy the game's Stability FEX
keys into the synced config before applying it, so the game's own
settings still win on every launch path.

---------

Co-authored-by: Kurt Himebauch <[email protected]>
2026-11-29 16:18:35 -05:00
LarzVader 90df30f4d7 fix(venus): OpenGL quads no longer crash Mali's shader compiler through Zink (#3283)
* fix(venus): OpenGL quads no longer crash Mali's shader compiler through Zink

The Mali-G610's driver crashes compiling Zink's geometry shaders
(SIGSEGV at 0x40 in cmpbe_v2_compile_multiple_shaders), and the render
server and the application die with it. A plain geometry shader that
only passes triangles on does not crash it, but draws nothing. Zink
draws GL_QUADS through a geometry shader when the device has the
feature, so OpenGL programs died on their first quad.

The Mali layer now reports no geometryShader to Zink on ARM GPUs.
Mesa then splits quads into triangles itself. DXVK keeps the feature,
which it needs for D3D10 and 11. DROIDDECK_MALI_COMPAT_NO_GS=0 keeps
it for Zink, =1 hides it from every application.

* test(venus): clear DROIDDECK_MALI_COMPAT_NO_GS before the layer tests

The geometry shader test checks the default first. With the variable
exported in the shell, it failed before it reached its own settings.

* test(venus): check that other ARM applications keep the geometry shader
2026-11-29 16:18:27 -05:00