Each stream's scan is now found through a separate key table, so a
thread listing one folder never reads a scan another thread is freeing.
The read-ahead tests wait for the readers to finish instead of sleeping,
and check the thread count to prove nothing started.
Wine lists each folder with opendir(".") after fchdir, so the Steam
client's listing cache never applied to programs on the card, and the
cost there is the first cold read of each folder rather than repeats.
dircache.c now times readdir in every program. A call of 20 ms or more
on FUSE, exFAT, FAT, NTFS3 or sdcardfs, in a program that already runs
more than one thread, queues that listing's subfolders for three
background readers, and a program listing a folder that was read ahead
queues its subfolders in turn. The readers only read directories, so
nothing a program sees can be stale. DD_NO_DIR_PREFETCH=1 turns it off.
* Skip per-component link walk for plain paths in binds
Open the translated host path with O_PATH and compare /proc/self/fd
against it; when no link was crossed, return it without walking each
component. follow_guest_link reuses the result instead of rewriting the
path a second time. Cuts stat/open on deep SD-card files from about
5.7 ms to 1.4 ms.
* Test link handling and plain paths inside native binds
* Check missing paths in binds from their deepest existing folder
A path below folders that do not exist fell back to a readlink of every component, one full lookup each; on a FUSE card that cost up to 8 ms per probe. The check now climbs to the deepest folder that exists and verifies that one, so links before it are still followed and nothing below it can be a link.
* Skip the link walk for mounts on file systems that cannot hold links
A mount whose source is on vfat or exFAT, or on a FUSE volume backed by
one (Android's SD card), cannot hold symbolic links, so every path in it
is plain. Each mount checks the mount table once, then its paths skip
the link walk and the follow readlink. On the SD card this removes about
two FUSE lookups per file operation.
* Keep the link walk for truncated mount tables and non-volume FUSE mounts
* Skip the last link check for drive paths into mounts that hold no links
Wine reaches games on an SD card library through a drive link in the
prefix (dosdevices/d: -> /mnt/droiddeck-sd). Every stat, open and
access that follows links paid one more readlinkat on the card path
after the rewrite had already found the mount holds no links, and on
Android's storage layer each extra lookup of a deep path costs about a
millisecond. The rewrite now keeps the plain answer it already has, so
the check runs only where a link can exist.
* Keep the link walk when stacked mounts share the covering path
* Trace readlinkat without loading the hook into strace and match the queried path
* Start Steam offline automatically when the device has no internet
OfflineMode now reads Steam's own WantsOfflineMode as the user's choice, so going offline inside Steam shows on DroidDeck's toggle and is no longer reset on the next start. When Android has no validated internet, Steam starts in offline mode for that start only and goes back online once a connection returns, without changing the saved choice.
* Test automatic and manual Steam offline mode
* Switch Steam offline and back live when the network drops or returns mid-session
* Apply Steam offline changes after a game exits and when the session resumes
* Add an Auto offline mode toggle above Offline mode
* Keep an automatic offline automatic when Steam cannot be reached, and reconcile once when the session starts
* Keep a manual Offline choice made while a live switch is in flight
* Read the saved offline state and write it under one lock
* Check the Auto setting inside the offline state lock
* Keep Steam's current offline state when Auto is turned off
New Steam setting "Valve Proton only when needed", on by default. While it is on and DroidDeck-Proton has not been removed by the user:
- the app installs DroidDeck-Proton before the client first starts instead of seeding Valve's Proton Experimental (ARM64) (2.09 GB on disk, 398 MB download); a stop request cancels that download
- the session no longer asks the client for appid 4427310 at every start
- the live helper fetches it only once the default or a title is set to a tool built from it ("Proton Experimental ARM64 (Compatible)"), or while no DroidDeck-Proton build is installed
FEX and the Steam Linux Runtimes are still fetched as before. An installed copy of Valve's Proton is kept and updated. Off, or with DroidDeck-Proton declined, everything works as before (DD_VALVE_PROTON=1). Fresh install on a Pocket FIT: 8.28 GB after first Steam start and tool downloads, was 10.4 GB.
With targetSdk 34, Android refuses startForeground() while the app is in the background. RuntimeInstallService called it unguarded on the main thread, so the refusal (ForegroundServiceStartNotAllowedException) killed the app during first-run setup when the runtime finished while DroidDeck-Proton was still downloading (RuntimeInstallService.kt:49 via onStartCommand :22).
Both foreground starts now catch the refusal: a package hold stops the service and the downloads go on in the app, as when startForegroundService() itself is refused; a runtime install or removal still runs, without progress notifications.
* docs: DroidDeck 0.7.11 release notes
* docs: text-only highlights under a heading, images beside their entries
* docs: measured memory card start times for 0.7.11
* docs(release): 0.7.11 notes cover zero-copy, the Library rebuild and the latest fixes
* docs(release): 0.7.11 notes list the DroidDeck-Proton and DD-Turnip fixes
* docs(release): 0.7.11 notes cover run without proot by default, DroidDeck-Bionic, CurseForge, in-game menu pages and the latest fixes
* docs(release): screenshots for the 0.7.11 menu, first run, Decky, CurseForge, resolutions and on-screen controls
* docs(release): 0.7.11 community share excludes both maintainers, screenshots recaptured on current main
* docs(readme): headliner links to CD's Retro Corner's Odin 3 DroidDeck video instead of the GIF
* docs(readme): headliner is a short showcase GIF of quick wake, the Thor touchpad and the store tabs
* docs: README and 0.7.11 notes say no subscriptions, and the README drops its Limits section
* docs(readme): showcase GIF drops the store tabs and ends on scrolling Steam then the home screen
* docs(readme): showcase GIF opens on the table of devices
* docs(readme): showcase GIF keeps two sleep and wake cycles instead of three
* docs(release): 0.7.11 shows each new store's chip row and games from the Pocket FIT
* docs(release): 0.7.11 store screenshots show the cards without titles or sizes
* docs(release): 0.7.11 combines the three new stores into one bullet with a chip GIF
* docs(release): 0.7.11 new stores GIF is the full-screen Pocket FIT recording
* docs(release): 0.7.11 notes fold the three new stores into one bullet
* docs(release): 0.7.11 combines tab, Library and in-game menu customization into one bullet with screenshots
* docs(release): 0.7.11 headlines put no proot with DroidDeck-Bionic and zero-copy right after the stores
* docs(release): 0.7.11 explains no proot and DroidDeck-Bionic in plainer words
* docs(release): 0.7.11 says what no proot and DroidDeck-Bionic gain: CPU overhead, 1% lows, memory
* docs(release): 0.7.11 puts no proot and Bionic first and trims the headline, Features and Improvements wording
* docs(release): 0.7.11 folds small fixes and minor features into grouped lines and shortens the contributor table
* docs(release): 0.7.11 controller kits image is the cropped portrait set with the bottom button row
* docs(release): 0.7.11 moves the Xbox save and install work from Features to Fixed
* docs(release): 0.7.11 groups no proot, zero-copy and DroidDeck-Bionic as one new foundation at the top of Features
* docs(release): 0.7.11 summary leads with native execution and DroidDeck-Bionic
* docs(release): 0.7.11 summary names no proot again
* docs(release): 0.7.11 gets a Design and organization section, with the Features re-order
* docs(release): 0.7.11 moves frame generation, integer scaling, pens, XREAL and virtual pads lower in Features
* docs(release): 0.7.11 controller kits image shows four kits
* docs(release): 0.7.11 intro, store line and Lab builds wording
* docs: remove the unused steam-to-desktop headliner GIF
* docs(release): 0.7.11 summary wording, HDR and memory card lines, on-screen controls
* docs(release): 0.7.11 moves landscape and portrait resolutions to Improvements
* docs(release): 0.7.11 adds the latest main fixes and recounts the totals and leaderboard
* docs(release): 0.7.11 counts outside contributors as everyone but the three maintainers
* docs(release): 0.7.11 intro counts the 39 outside contributors
* docs(release): 0.7.11 intro counts 111 pull requests from outside contributors
* docs(release): 0.7.11 zero-copy and DroidDeck-Bionic charts
* docs(release): 0.7.11 no-proot speed chart
* docs(release): 0.7.11 shows one combined new-foundation chart
* docs(release): 0.7.11 new-foundation chart adds the SD card start times
* docs(release): 0.7.11 new-foundation chart drops its title and shrinks the headlines
* docs(release): 0.7.11 chart calls no proot native execution
* docs(release): 0.7.11 chart axes say whether higher or lower is better
* docs(release): 0.7.11 drops the HUD settings screenshots
* docs(release): 0.7.11 drops the first run screenshot
---------
Co-authored-by: Kurt Himebauch <136133082+xXJSONDeruloXx@users.noreply.github.com>
* Unlock ProgramData entries a stale Windows owner locked
Wine builds the user SID from /etc/machine-id and the uid it runs as.
When either changes, descriptors stored in user.wine.sd keep the old
owner, and the next DACL change maps to mode 000 because no ACE matches
the token. Wine then cannot open the entry, so programs such as
Battle.net cannot repair their own folders.
Before each launch, clear stale local user owners under ProgramData and
give owner access back to entries they locked.
* Heal a locked ProgramData itself and keep read-only folders
* Serialise the ProgramData heal per prefix
* Launch even when the ProgramData owner check fails
* Read the machine ID as bytes the way Wine does
* Parse a signed machine ID the way Wine does
* Resolve fake input's real functions before any loader lock is held
Each hooked call looked up its real function through a function-local
static, and the x86 dlsym hook opened libc the same way. A thread that
entered a hook first held the static's guard while dlsym waited for the
loader lock, and a thread inside dlopen held the loader lock while its
constructor called the same hook and waited for the guard. Steam's update
window hung that way under FEX, so x86 Steam stopped at Installing update.
The real functions now live in lock-free slots filled by the library's
constructor, and the dlsym hook resolves dlvsym and libc there too.
* Use an atomic handshake in the loader lock test
* fix(flatpak): file dialogs and forwarded descriptors work in Flatpak apps
Flatpak apps opened from the desktop could not open files: the file
chooser's result went through a document store that cannot mount on
Android, and image loaders started with flatpak-spawn --forward-fd lost
their D-Bus descriptor because the app relaunches sandboxes and only
stdio survived.
- A session document store hands picked files and folders back in place
instead of failing without a mount.
- The bwrap shim offers its inherited descriptors once over a private
socket, and the native hook puts them back on their original numbers
before the program starts.
- The native hook resolves /proc/<pid>/root paths to the other
process's sandbox, so xdg-desktop-portal reads .flatpak-info and
identifies the calling app.
* fix(flatpak): check documents against the app's view and harden fd forwarding
The document store hands a picked file back in place only when the
calling app's own sandbox can open it with the requested access, so
paths the app cannot see are refused instead of handed out broken.
/proc/<pid>/root lookups follow links inside that process's view,
duplicated root descriptors keep their mapping, and close_range drops
stale records. Forwarded descriptors survive targets at the fd limit,
truncated offers are ignored, and the shim refuses more descriptors
than one message can carry.
* fix(flatpak): match picked documents by file identity and keep O_NOFOLLOW on process roots
The document store accepts an in-place path only when the app's view
holds the same file (device and inode) as the picked descriptor, and
reads each process root once. A bare /proc/<pid>/root opened with
O_NOFOLLOW is no longer mapped, so it fails like the kernel's link.
* Keep a trailing-slash process root translated and track only directory roots
* fix(battlenet): drop the unused runtime drive and list its games under the runtime path
* fix(battlenet): read product.db paths decoded and keep alias-saved folders
* fix(battlenet): keep drives for paths that climb out of the runtime
* fix(battlenet): keep a drive referenced with any separator spelling
* fix(battlenet): check decoded config values before dropping a drive
* fix(battlenet): games installed inside the runtime stay listed after a native session
* test(battlenet): expect the shared folder for a lone Forever install
---------
Co-authored-by: Kurt Himebauch <136133082+xXJSONDeruloXx@users.noreply.github.com>
Co-authored-by: maxjivi05 <maxjividen@gmail.com>
fix(preload): keep libudev loaded while the input wrappers use it
Programs that close libudev and open it again crashed in the next wrapped
udev call: the wrappers kept function pointers into the unmapped copy.
Pin libudev with RTLD_NODELETE when it is opened so those pointers and
the stored handle stay valid.
* fix(xbox): an application element with attributes on the next line still counts
* fix(xbox): repair the patch hunk for the pretty-printed manifest test
* fix(desktop): a Kubuntu-default panel gets the SteamOS layout and launcher icon
* fix(desktop): lay out Plasma's stock panel with the SteamOS pins, once, over an older panel
* fix(desktop): keep Plasma's wide-screen cap and input-method panel in the SteamOS layout
* fix(desktop): stamp the panel layout only after the old panel is backed up, never over a backup
DroidDeck-Bionic: a Steam compatibility tool that runs the game itself on Android's libc (bionic) instead of glibc inside proot. Steam, the stores and the session stay on DroidDeck's Linux side; only the game process leaves proot.
- Listed in the Proton list only when Run without proot is on, in its own row. Its builds are pre-releases on Droid-Deck/DroidDeck-Proton (DroidDeck-Bionic-12.8-rNN, runtime built by .github/workflows/build-bionic-runtime.yml from tools/bionic-runtime); the app installs and updates them like the other extra tools and never makes one the default unless the user picks it.
- With proot on, a launch sent to a bionic tool goes to the newest DroidDeck-Proton (picks stay as set).
- ProtonExtras / ProtonMenu / ExperimentalProtons / droiddeck-proton-extra: bionic pre-releases checked and listed only without proot; updates carry the default and per-game picks over; deleting a tool never follows links out of it. ProtonDefault: picks left on an older bionic build move to the installed one.
- Components: FEX builds for bionic (bionic-stable on DroidDeck-Components); each tool is offered only the FEX builds that fit it.
- Session logs: the bionic game log and its graphics logs are part of Share logs.
Synced with main twice before the merge (latest sync fbed69ce on main 67b82ad9; Build APK and validation green); a local trial merge on main 3e1fc3e6 had no conflicts and the game-environment, Proton-extra and store-launch tests pass.
* fix(session): report the CPU cache sizes the x86 CPUID reports to Windows programs
* fix(session): clear the staged core caches without following links
* fix(session): stage CPU cache binds per session generation and per core
* fix(session): keep every start's staged CPU caches until the process ends
* fix(session): give every start its own CPU cache staging folder
* test(session): a delayed worker from a recreated service keeps its own cache folder
---------
Co-authored-by: maxjivi05 <maxjividen@gmail.com>
* fix(ea): a failed touchup is retried and its output reaches the store log
* fix(ea): bound the touchup output kept for the store log
The output goes to a temporary file and only its last 64 KiB are read back. The timeout test now checks the output is logged and the next launch retries.
* fix(ea): a touchup still runs when its output cannot be captured
* fix(gog): bind every store root for installer extraction and log its error
* fix(gog): count the extracted size before downloading an offline installer
The installer fallback only checked free space for the download, so a
game that needs the download plus its extracted files failed after
every part was fetched, with innoextract's stream error. The failure
reason now drops innoextract's warnings and bug-report trailer.
* fix(gog): keep the internal store root visible to installer extraction
* fix(games): never give an added folder the internal store guest path
An added folder named Stores was bound at /root/Games/Stores, over the
internal store install root. legacyRoots, used by bindFolder and the
games-folder migration, now gives such a folder a suffixed guest path,
so guestBinds mounts every added root again, matching guestPath and the
session binds.
* fix(games): re-path saved folder binds that hold the internal store guest path
* test(games): verify extractor binds after migrating a saved internal-guest bind
* fix(gog): keep innoextract output in the log and leave the install failure message unchanged
* fix(gog): count known installer part sizes in the free-space check when some part has no size
* fix(launcher): LT and RT keep the focus ring on the tab rail
A trigger step selected the tab like a tap on the rail, which also sent focus into the new page, and each page put it somewhere different. The step now shows the page and focuses its rail item, and for a second puts focus back on the rail if the page takes it, until another key is pressed. Dual screens, which have no rail on the main screen, keep focusing the page.
* fix(launcher): end the trigger step's rail hold when another navigation changes the page
A navigation that changed the selected page during the hold, such as opening a game from a link, was undone: the hold focused the stepped tab's rail item, and that focus switched the page back. The hold now stops as soon as the selection is no longer the one the step made.
* fix(launcher): end the trigger step's rail hold when another navigation opens a page
Opening the Components page does not change the selected tab, so a navigation there during the hold kept it running and the hold could pull focus from Components back to the rail. The hold now also tracks the page key: once the page its own step opened is showing, any other page ends the hold.
---------
Co-authored-by: Kurt Himebauch <136133082+xXJSONDeruloXx@users.noreply.github.com>
The unified input surface redrew the overlay on every stick move. Knob-only
moves now redraw through ThrottledRedraw at 33 ms and skip sub-pixel moves
away from the rim. Pad updates still go out on every event; touch down, touch
up and reaching the rim still redraw immediately.
Co-authored-by: Tapuuk <177422350+Tapuuk@users.noreply.github.com>
* fix(library): keep another program of a Steam install out of the Steam app's route
* fix(library): cover a Steam-edited target in the unrouted-program test and docs
* fix(library): keep Steam-edited targets routed and release stale Spacewar imports for other programs
* fix(library): keep Steam-edited targets adopted before the marker existed routed
A saved executable and seen revision without the adoption marker are recognised
from the Steam shortcut record (its target is the current executable and differs
from the one the app asked for), and the marker is stored.
#2958 reverted the controller redesign and its follow-ups, and #2946 was
in that list, so streaming_client lost the real libudev again. #2963
brought back #2942 but not #2946. With the session's udev answers,
SDL3 in streaming_client hands a virtual pad's handle to the real
udev_device_get_driver and crashes about a second after it starts.
streaming_client in steamrtarm64/steamrt64 keeps the real libudev again,
like the Steam client. The no-driver answer for pads that #2946 also
added is left to #2915, which covers every device call.
The nested Wayland pointer reaches wlserver as touch 0, and in the Disabled
touch click mode wlserver_touchmotion returned before moving anything.
Buttons go through wlserver_mousebutton, so they still arrived, at an X
pointer that stayed at (0,0). Steam picks Disabled for Don't Starve
Together: DroidDeck's cursor followed the mouse while every click landed
in the top-left corner. The nested pointer now warps the X pointer in
Disabled as in the other modes; real fingers are still ignored.
At the game's default monster mesh detail, slimes show only their tips.
Set the two skeletal mesh detail values in Engine.ini before each launch,
in the prefix the game profile selects, and keep the file's permissions.
The game ignores -ini: overrides and deletes a writable Engine.ini after
reading it, so a launch argument or a one-time write does not work.
* fix(desktop): Plasma draws on the system PowerVR driver
KWin lacks the Android-buffer Wayland protocol the system PowerVR driver's
swapchain needs, so every Plasma client failed with "zink: could not create
swapchain" and the desktop stayed black under the cursor. Plasma's clients now
present through DRI on that path, as the Steam session already does.
* test(desktop): the kopper override reaches Plasma's child processes
* test(desktop): check the kopper override where Plasma launches
---------
Co-authored-by: Jacob Lambert <183008808+JMLambo@users.noreply.github.com>
PRoot's link2symlink resolves /usr/bin/env to a `.l2s.env….` stub and the
guest's uutils coreutils multicall refuses that name:
Security violation: Requested utility 'env' does not match executable
name: /usr/lib/cargo/bin/coreutils/.l2s.env0001.0116
Every exec of these five scripts therefore dies with GUEST_EXIT 1 before
Python starts, 20-60 ms into the session. They are droiddeck-diagnostic-
inventory (the session's first child), droiddeck-desktop-bookmarks (the
desktop's bookmarks refresh), droiddeck-ime, droiddeck-steam-games and
droiddeck-steam-shortcuts.
The absolute interpreter is what the other payload scripts already use,
and the guest runtime installs the python3 package (tools/ubuntu/
packages-runtime.txt), so /usr/bin/python3 exists in the rootfs.
Only the tracked overlay copies change: app/src/main/assets/linuxfs is
generated by the stageSessionScripts Gradle task, so the asset copies
follow from the overlay.
Co-authored-by: Pablo González <pgm1207@users.noreply.github.com>
Co-authored-by: Kurt Himebauch <136133082+xXJSONDeruloXx@users.noreply.github.com>
* fix(native): programs started through the rootfs loader show their own command line
Without proot every dynamic guest program runs as "ld.so --preload <hook>
--library-path <dirs> --argv0 <name> <program> <args>", and the kernel's
/proc/<pid>/cmdline kept all of it. Launchers and the session match programs
by their command line, and Wine only moves its Windows command line over its
loader's name when its arguments follow each other, so the Battle.net launcher
never saw Battle.net.exe, gave up after five minutes and ended the session
with the game still running.
The hook now moves the program's own arguments to the front of that area at
start, as an exec of the program would have laid them out.
* fix(native): programs the app starts natively keep their path for /proc/<pid>/exe
* fix(native): the rewritten command line keeps AT_EXECFN naming the program
---------
Co-authored-by: Kurt Himebauch <136133082+xXJSONDeruloXx@users.noreply.github.com>
* fix(display): layer buffers are imported as AHardwareBuffers only on the phone's own Vulkan driver
* fix(display): a failed 10-bit layer pool still falls back to 8-bit linear buffers