Skip to content

fix(android): fall back to stock Vulkan driver on Adreno 8xx (Snapdragon 8 Elite / S25-S26) - #24

Open
KLCLAU wants to merge 1 commit into
fadi-labib:mainfrom
KLCLAU:android-adreno-8xx-stock-driver
Open

fix(android): fall back to stock Vulkan driver on Adreno 8xx (Snapdragon 8 Elite / S25-S26)#24
KLCLAU wants to merge 1 commit into
fadi-labib:mainfrom
KLCLAU:android-adreno-8xx-stock-driver

Conversation

@KLCLAU

@KLCLAU KLCLAU commented Sep 1, 2026

Copy link
Copy Markdown

Problem

On an Adreno 840 (Snapdragon 8 Elite Gen 5 — Galaxy S26 / S26+ Ultra, and the same applies to Adreno 830 / 8 Elite on S25), the app dies on launch:

I/GeneralsX: INFO: Turnip: staged driver -> .../vulkan.ad07xx.so
I/GeneralsX: info:  Vulkan: opening Turnip via adrenotools (... driver=vulkan.ad07xx.so)
I/GeneralsX: info:  Vulkan: Found vkGetInstanceProcAddr in adrenotools/Turnip libvulkan
I/GeneralsX: ERROR: TheDisplay->init() threw exception: DxvkInstance::enumAdapters: Failed to enumerate adapters

The bundled Turnip package is vulkan.ad07xx.so — an Adreno 6xx/7xx build. It loads on an a8xx part but enumerates zero physical devices, so DxvkInstance throws and TheDisplay->init() aborts.

Per ANDROID_RENDERER_RESEARCH_2026-07.md §5, Adreno 8xx is explicitly the stock-driver rung: the stock Qualcomm driver on a8xx already reports Vulkan 1.3 and textureCompressionBC, so Turnip is neither needed nor usable there. That fallback just isn't wired up yet.

Fix

gxAdrenoSeries() reads /sys/class/kgsl/kgsl-3d0/gpu_model (e.g. Adreno840v2acd) and parses the series. For series ≥ 8, gxSetupTurnipDriver() returns early — it doesn't stage the driver or set the GENERALSX_ADRENOTOOLS_* env vars, so vulkan_loader.cpp falls through to the stock libvulkan.so (its existing, already-implemented path).

GENERALSX_NO_TURNIP=1 forces the same behaviour on any device — useful for debugging, or for a future a8xx part whose gpu_model string this parser doesn't recognise.

No change for Adreno 6xx/7xx: they still get Turnip exactly as before.

Testing

Galaxy S26+ (Adreno 840, Android 16, 4 KB-page kernel). With this patch + a companion DXVK presenter fix (VK_SUBOPTIMAL_KHR handling — separate PR to the dxvk fork), the port boots to the main menu and plays a skirmish at ~30 FPS. Without it, it crashes at enumAdapters every launch.

Related: #23

The bundled Turnip driver (vulkan.ad07xx.so) only supports Adreno 6xx/7xx
and enumerates zero physical devices on an Adreno 840 (Snapdragon 8 Elite
Gen 5, Galaxy S25/S26). DXVK then throws

  DxvkInstance::enumAdapters: Failed to enumerate adapters

and the app dies at TheDisplay->init().

The stock Qualcomm driver on Adreno 8xx already exposes Vulkan 1.3 and
textureCompressionBC, so Turnip is neither needed nor usable there (this
is the 'rung 1' path from the renderer-research doc). Parse the Adreno
model number from /sys/class/kgsl/kgsl-3d0/gpu_model and, for series >= 8,
skip staging the Turnip driver and setting the adrenotools env vars so the
DXVK loader (vulkan_loader.cpp) falls through to the stock libvulkan.so.

GENERALSX_NO_TURNIP=1 forces the same path on any device (useful for
debugging or for a8xx parts the sysfs parse doesn't recognise).

Tested on Galaxy S26+ (Adreno 840): boots to the main menu and plays a
skirmish at ~30 FPS where the stock build crashed on launch.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
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