mirror of
https://github.com/Droid-Deck/DroidDeck.git
synced 2026-11-20 13:26:02 +00:00
Auto: the Mali bridge stands in on a Vulkan 1.1 Mali driver
Auto refused both Venus and the bridge when the phone's driver reports Vulkan below 1.2, so on the G77, G78 and G610 (r32p1/r38, Vulkan 1.1) a rolled-back or missing pair left the runtime's Turnip: "failed to find physical device" (Retroid Pocket 4 Pro after the JM pair's trial, Xiaomi 13T). Only Venus needs 1.2; the bridge raises the driver for gamescope and runs on these phones. A Venus switch that cannot start on such a driver no longer counts as a route.
This commit is contained in:
1 parent
941cde30f2
commit
c2b00e1db6
2 files changed
+11
-9
No files matched your search
@@ -390,16 +390,15 @@ internal class DriverMenus(private val activity: Activity, private val ui: Handl
|
||||
* A Mali with no open driver pair to install ([missing] names the unpublished pair, or null when
|
||||
* no PanVK build covers this GPU) runs through the phone's own driver: Mali (Venus) where this
|
||||
* apk carries it (Steam runs on it from the G57 to the G1 series), the Mali bridge otherwise.
|
||||
* Both need Vulkan 1.2 from the phone's driver for gamescope, so with an older one nothing is
|
||||
* switched on. The Linux driver choice is left alone (it is the bridge's fallback), and Auto
|
||||
* Venus needs Vulkan 1.2 from the phone's driver; the bridge raises a Vulkan 1.1 driver
|
||||
* (r32p1 on the G77, G78 and G610) for gamescope itself, so there the bridge stands in.
|
||||
* The Linux driver choice is left alone (it is the bridge's fallback), and Auto
|
||||
* switches only its own choice off again once a pair is installed ([endMaliFallback]).
|
||||
*/
|
||||
private fun useMaliFallback(missing: String?): String {
|
||||
com.droiddeck.launcher.session.VenusComponent.hostVulkanTooOld(activity)?.let { api ->
|
||||
Log.i(TAG, "auto: Mali driver reports Vulkan $api; no Venus or bridge for gamescope")
|
||||
return activity.getString(R.string.drivers_mali_vulkan_too_old, missing ?: gpu.name, api)
|
||||
}
|
||||
val venus = com.droiddeck.launcher.session.VenusComponent.available(activity)
|
||||
val oldVulkan = com.droiddeck.launcher.session.VenusComponent.hostVulkanTooOld(activity)
|
||||
val venus = oldVulkan == null && com.droiddeck.launcher.session.VenusComponent.available(activity)
|
||||
if (oldVulkan != null) Log.i(TAG, "auto: Mali driver reports Vulkan $oldVulkan; Venus needs 1.2, the bridge stands in")
|
||||
if (venus && !SessionPrefs.venus(activity)) {
|
||||
SessionPrefs.setVenus(activity, true)
|
||||
SessionPrefs.setMaliFallbackByAuto(activity, "venus")
|
||||
@@ -409,13 +408,16 @@ internal class DriverMenus(private val activity: Activity, private val ui: Handl
|
||||
}
|
||||
val route = activity.getString(if (venus) R.string.drivers_route_venus else R.string.drivers_route_bridge)
|
||||
Log.i(TAG, "auto: Mali stand-in route $route (missing pair: ${missing ?: "none covers ${gpu.name}"})")
|
||||
if (oldVulkan != null) return activity.getString(R.string.drivers_mali_old_vulkan_bridge, missing ?: gpu.name, oldVulkan)
|
||||
return if (missing == null) activity.getString(R.string.drivers_mali_no_pair_auto, route)
|
||||
else activity.getString(R.string.drivers_mali_unpublished_auto, missing, route)
|
||||
}
|
||||
|
||||
/** Neither an installed open Linux driver nor Venus or the bridge: the runtime's Turnip would run. */
|
||||
private fun maliHasNoRoute(): Boolean {
|
||||
if (SessionPrefs.venus(activity) || SessionPrefs.vkBridge(activity)) return false
|
||||
if (SessionPrefs.vkBridge(activity)) return false
|
||||
// Venus on a Vulkan 1.1 driver does not start (VenusComponent.wanted), so it is no route.
|
||||
if (SessionPrefs.venus(activity) && com.droiddeck.launcher.session.VenusComponent.hostVulkanTooOld(activity) == null) return false
|
||||
val linux = SessionPrefs.linuxDriver(activity)
|
||||
return linux.isEmpty() || !LinuxVulkanDriverManager(activity).isInstalled(linux)
|
||||
}
|
||||
|
||||
@@ -1976,7 +1976,7 @@
|
||||
<string name="drivers_route_bridge">the Mali bridge</string>
|
||||
<string name="drivers_mali_no_pair_auto">No open driver covers this Mali yet: %1$s is used, on the phone\'s own driver.</string>
|
||||
<string name="drivers_mali_unpublished_auto">%1$s isn\'t published yet: %2$s is used until it is.</string>
|
||||
<string name="drivers_mali_vulkan_too_old">%1$s isn\'t available, and this phone\'s driver reports Vulkan %2$s (Venus and the Mali bridge need 1.2). Pick a PanVK pair under Driver pairs.</string>
|
||||
<string name="drivers_mali_old_vulkan_bridge">%1$s isn\'t available, and this phone\'s driver reports Vulkan %2$s (Venus needs 1.2): the Mali bridge is used.</string>
|
||||
<string name="drivers_mali_bridge_fallback">%1$s isn\'t published yet: the Mali bridge is on until it is.</string>
|
||||
<string name="cmgr_powervr_dxvk_queued">Queued: %1$s (waiting for a different runtime driver)</string>
|
||||
<string name="cmgr_powervr_dxvk_managed">DXVK is provided by the system PowerVR runtime. Other DXVK packages can be stored but are not applied with this driver.</string>
|
||||
|
||||
Reference in new issue
Block a user