diff --git a/flake.nix b/flake.nix index 5a595c74..f4204234 100644 --- a/flake.nix +++ b/flake.nix @@ -58,7 +58,7 @@ # Keep in sync with CMakeLists.txt monado rev rev = builtins.readFile ./monado-rev; # Nix will output the correct hash when it doesn't match - hash = "sha256-cVXP/iveB77Sp+TArE5ZYm3Xd/PkjN0keuNJY8GU0f0="; + hash = "sha256-0ALB9eLY4NAUqNOYZMwpvYnLxVpHsQDJc1er8Txdezs="; }; }; diff --git a/monado-rev b/monado-rev index 9b23a9ec..7ca13e25 100644 --- a/monado-rev +++ b/monado-rev @@ -1 +1 @@ -1cafc3a42dafa126227b7782a04fdcb62f1e403e +06e62fc7d9c5cbcbc43405bb86dfde3bf01ce043 diff --git a/patches/monado/0001-c-multi-early-wake-of-compositor.patch b/patches/monado/0001-c-multi-early-wake-of-compositor.patch index fe99d5f3..8a8e2bbe 100644 --- a/patches/monado/0001-c-multi-early-wake-of-compositor.patch +++ b/patches/monado/0001-c-multi-early-wake-of-compositor.patch @@ -1,7 +1,7 @@ -From 104babdb5929b053824a0ac4436a4a1a25d99259 Mon Sep 17 00:00:00 2001 +From 3939fa120128ded9ff85fe23c7f5a2694a016fbe Mon Sep 17 00:00:00 2001 From: Patrick Nicolas Date: Tue, 22 Oct 2024 15:23:19 +0200 -Subject: [PATCH 1/8] c/multi: early wake of compositor +Subject: [PATCH 1/9] c/multi: early wake of compositor --- .../compositor/multi/comp_multi_compositor.c | 14 +++++++++ @@ -128,5 +128,5 @@ index cf8e2e525..94413b090 100644 //! @todo Make the clients not go from IDLE to READY before we have completed a first frame. // Make sure there is at least some sort of valid frame data here. -- -2.51.0 +2.49.1 diff --git a/patches/monado/0002-ipc-server-Always-listen-to-stdin.patch b/patches/monado/0002-ipc-server-Always-listen-to-stdin.patch index de761cee..d2d39fbd 100644 --- a/patches/monado/0002-ipc-server-Always-listen-to-stdin.patch +++ b/patches/monado/0002-ipc-server-Always-listen-to-stdin.patch @@ -1,7 +1,7 @@ -From 67ce4429a092565582c0932413b1a132e6a66ea4 Mon Sep 17 00:00:00 2001 +From edabcaa4d6723a61e01648676186a2d3b86796bd Mon Sep 17 00:00:00 2001 From: Patrick Nicolas Date: Tue, 2 Apr 2024 17:14:42 +0200 -Subject: [PATCH 2/8] ipc/server: Always listen to stdin +Subject: [PATCH 2/9] ipc/server: Always listen to stdin --- src/xrt/ipc/server/ipc_server_mainloop_linux.c | 2 +- @@ -21,5 +21,5 @@ index d364fbed3..ad6b473b7 100644 // default. // This polls stdin. -- -2.51.0 +2.49.1 diff --git a/patches/monado/0003-Use-extern-socket-fd.patch b/patches/monado/0003-Use-extern-socket-fd.patch index 3fbbd656..65b3974c 100644 --- a/patches/monado/0003-Use-extern-socket-fd.patch +++ b/patches/monado/0003-Use-extern-socket-fd.patch @@ -1,7 +1,7 @@ -From 9a4aee03233c05306e252c6cf33543d3a64fff6d Mon Sep 17 00:00:00 2001 +From e399684882d5c76e71a11d3ea4075f89457a0e57 Mon Sep 17 00:00:00 2001 From: Patrick Nicolas Date: Tue, 8 Oct 2024 22:13:15 +0200 -Subject: [PATCH 3/8] Use extern socket fd +Subject: [PATCH 3/9] Use extern socket fd --- src/xrt/ipc/server/ipc_server_mainloop_linux.c | 8 ++++++++ @@ -34,5 +34,5 @@ index ad6b473b7..ea6fad65b 100644 // We may have been launched with socket activation int num_fds = sd_listen_fds(0); -- -2.51.0 +2.49.1 diff --git a/patches/monado/0004-change-environment-blend-mode-selection-logic.patch b/patches/monado/0004-change-environment-blend-mode-selection-logic.patch index e3f1227e..27d607a1 100644 --- a/patches/monado/0004-change-environment-blend-mode-selection-logic.patch +++ b/patches/monado/0004-change-environment-blend-mode-selection-logic.patch @@ -1,7 +1,7 @@ -From 4435e995c0ced6d670167256cad69b0de1f72e16 Mon Sep 17 00:00:00 2001 +From 780d6f00025c4499008f4acfffb63475b52657c2 Mon Sep 17 00:00:00 2001 From: galister <85970-galister@users.noreply.gitlab.freedesktop.org> Date: Sat, 23 Nov 2024 02:42:12 +0900 -Subject: [PATCH 4/8] change environment blend mode selection logic +Subject: [PATCH 4/9] change environment blend mode selection logic --- src/xrt/compositor/multi/comp_multi_system.c | 26 +++++++++++++------- @@ -53,5 +53,5 @@ index 94413b090..0d958c3af 100644 } -- -2.51.0 +2.49.1 diff --git a/patches/monado/0005-st-oxr-forward-0-refresh-rate.patch b/patches/monado/0005-st-oxr-forward-0-refresh-rate.patch index 2ffae083..c5966d0d 100644 --- a/patches/monado/0005-st-oxr-forward-0-refresh-rate.patch +++ b/patches/monado/0005-st-oxr-forward-0-refresh-rate.patch @@ -1,7 +1,7 @@ -From cb1191f81a027972d050f9f30a0e418a31b35f5a Mon Sep 17 00:00:00 2001 +From 2d431f95802fad68a2fb38ddcae91766751a63a8 Mon Sep 17 00:00:00 2001 From: Patrick Nicolas Date: Sat, 15 Mar 2025 22:19:48 +0100 -Subject: [PATCH 5/8] st/oxr: forward 0 refresh rate +Subject: [PATCH 5/9] st/oxr: forward 0 refresh rate --- src/xrt/state_trackers/oxr/oxr_api_session.c | 6 +----- @@ -29,5 +29,5 @@ index 9c5889f12..c4cdaf8c3 100644 if ((int)(displayRefreshRate * 100.0f) == (int)(sess->sys->xsysc->info.refresh_rates_hz[i] * 100.0f)) { found = true; -- -2.51.0 +2.49.1 diff --git a/patches/monado/0006-Replace-distortion-with-foveation.patch b/patches/monado/0006-Replace-distortion-with-foveation.patch index a4c9c873..fce8489c 100644 --- a/patches/monado/0006-Replace-distortion-with-foveation.patch +++ b/patches/monado/0006-Replace-distortion-with-foveation.patch @@ -1,7 +1,7 @@ -From e22cf0edf3abedc59e98416ac4d62e9253d6ddd8 Mon Sep 17 00:00:00 2001 +From 97400e9b24957b88a75a1e79b59bcbba0e22fc7f Mon Sep 17 00:00:00 2001 From: Patrick Nicolas Date: Wed, 11 Sep 2024 22:56:29 +0200 -Subject: [PATCH 6/8] Replace distortion with foveation +Subject: [PATCH 6/9] Replace distortion with foveation --- src/xrt/compositor/CMakeLists.txt | 4 +- @@ -41,7 +41,7 @@ index 1ba5ec438..eb068f5fc 100644 render/render_interface.h render/render_resources.c diff --git a/src/xrt/compositor/main/comp_renderer.c b/src/xrt/compositor/main/comp_renderer.c -index c5ec9e7de..fecc368a8 100644 +index 9cc7b63cc..6d08db7da 100644 --- a/src/xrt/compositor/main/comp_renderer.c +++ b/src/xrt/compositor/main/comp_renderer.c @@ -936,7 +936,8 @@ dispatch_compute(struct comp_renderer *r, @@ -623,7 +623,7 @@ index d5d2bc4cb..d74ec78dd 100644 diff --git a/src/xrt/compositor/render/render_resources.c b/src/xrt/compositor/render/render_resources.c -index 6e8cece0d..95cd86b37 100644 +index fba654902..c0824108e 100644 --- a/src/xrt/compositor/render/render_resources.c +++ b/src/xrt/compositor/render/render_resources.c @@ -184,14 +184,15 @@ init_mesh_ubo_buffers(struct vk_bundle *vk, struct render_buffer ubo[XRT_MAX_VIE @@ -1288,5 +1288,5 @@ index 4e20b32f0..69429dc97 100644 d->do_timewarp); // } -- -2.51.0 +2.49.1 diff --git a/patches/monado/0007-Limit-foveation-samples-per-pixel.patch b/patches/monado/0007-Limit-foveation-samples-per-pixel.patch index 61413a14..51c10df4 100644 --- a/patches/monado/0007-Limit-foveation-samples-per-pixel.patch +++ b/patches/monado/0007-Limit-foveation-samples-per-pixel.patch @@ -1,7 +1,7 @@ -From 6d3a2857d6495e89b4e85adc752f31c4d1ef9665 Mon Sep 17 00:00:00 2001 +From 295a815dfd6654db06f17f41ef1d0068ea88c439 Mon Sep 17 00:00:00 2001 From: Patrick Nicolas Date: Sun, 31 Aug 2025 17:05:49 +0200 -Subject: [PATCH 7/8] Limit foveation samples per pixel +Subject: [PATCH 7/9] Limit foveation samples per pixel --- src/xrt/compositor/shaders/distortion.comp | 12 +++++++++--- @@ -42,5 +42,5 @@ index cd1828ac9..41de849e6 100644 imageStore(luma, ivec3(offset.x + ix, offset.y + iy, 0), vec4(colour.x)); -- -2.51.0 +2.49.1 diff --git a/patches/monado/0008-ipc-Add-callbacks-and-unify-main-functions.patch b/patches/monado/0008-ipc-Add-callbacks-and-unify-main-functions.patch index 854ac1fe..8025a0b7 100644 --- a/patches/monado/0008-ipc-Add-callbacks-and-unify-main-functions.patch +++ b/patches/monado/0008-ipc-Add-callbacks-and-unify-main-functions.patch @@ -1,7 +1,7 @@ -From e6a73b6e07465ea7efc9d7c39ed7e817a4de4242 Mon Sep 17 00:00:00 2001 +From aeae876d61ac0883f974d9cee6a6f54b14536ec3 Mon Sep 17 00:00:00 2001 From: Jakob Bornecrantz Date: Fri, 15 Nov 2024 22:51:32 +0000 -Subject: [PATCH 8/8] ipc: Add callbacks and unify main functions +Subject: [PATCH 8/9] ipc: Add callbacks and unify main functions --- src/xrt/ipc/server/ipc_server_interface.h | 58 +++++++++---- @@ -308,5 +308,5 @@ index 45877803d..71c581da6 100644 struct ipc_server *server = NULL; -- -2.51.0 +2.49.1 diff --git a/patches/monado/0009-d-steamvr_lh-prevent-crash-on-vive-pro2-WiVRn.patch b/patches/monado/0009-d-steamvr_lh-prevent-crash-on-vive-pro2-WiVRn.patch index bd432f0a..7aee4423 100644 --- a/patches/monado/0009-d-steamvr_lh-prevent-crash-on-vive-pro2-WiVRn.patch +++ b/patches/monado/0009-d-steamvr_lh-prevent-crash-on-vive-pro2-WiVRn.patch @@ -1,4 +1,4 @@ -From 9c8627778ec263f6443fe726de88ca84bace3b00 Mon Sep 17 00:00:00 2001 +From 095b92d70604164000e4d0a90d08827c39fa9d3e Mon Sep 17 00:00:00 2001 From: no name Date: Sun, 28 Sep 2025 11:33:10 +0200 Subject: [PATCH 9/9] d/steamvr_lh: prevent crash on vive pro2/WiVRn @@ -21,5 +21,5 @@ index 8a4c55ed4..723cbb196 100644 } -- -2.51.0 +2.49.1 diff --git a/server/driver/wivrn_comp_target.cpp b/server/driver/wivrn_comp_target.cpp index 7573c134..cc456034 100644 --- a/server/driver/wivrn_comp_target.cpp +++ b/server/driver/wivrn_comp_target.cpp @@ -305,7 +305,7 @@ static bool comp_wivrn_init_post_vulkan(struct comp_target * ct, uint32_t prefer cn->wivrn_bundle->device, { .flags = vk::CommandPoolCreateFlagBits::eResetCommandBuffer, - .queueFamilyIndex = vk->main_queue.family_index, + .queueFamilyIndex = vk->main_queue->family_index, }); cn->wivrn_bundle->name(cn->command_pool, "comp target command pool"); } @@ -545,7 +545,7 @@ static VkResult comp_wivrn_present(struct comp_target * ct, if (cn->c->base.layer_accum.layer_count == 0 or not cn->cnx.get_offset()) { - scoped_lock lock(vk->queue_mutex); + scoped_lock lock(vk->main_queue->mutex); cn->wivrn_bundle->queue.submit(submit_info); cn->psc.images[index].status = pseudo_swapchain::status_t::free; return VK_SUCCESS; @@ -588,8 +588,8 @@ static VkResult comp_wivrn_present(struct comp_target * ct, .dstAccessMask = vk::AccessFlagBits::eMemoryWrite, .oldLayout = vk::ImageLayout::eTransferSrcOptimal, .newLayout = vk::ImageLayout::eVideoEncodeSrcKHR, - .srcQueueFamilyIndex = vk->main_queue.family_index, - .dstQueueFamilyIndex = vk->encode_queue.family_index, + .srcQueueFamilyIndex = vk->main_queue->family_index, + .dstQueueFamilyIndex = vk->encode_queue->family_index, .image = psc_image.image, .subresourceRange = {.aspectMask = vk::ImageAspectFlagBits::eColor, .baseMipLevel = 0, @@ -611,7 +611,7 @@ static VkResult comp_wivrn_present(struct comp_target * ct, submit_info.setCommandBuffers(*command_buffer); { - scoped_lock lock(vk->queue_mutex); + scoped_lock lock(vk->main_queue->mutex); cn->wivrn_bundle->queue.submit(submit_info, *cn->psc.fence); for (auto & encoder: cn->encoders) { @@ -715,7 +715,7 @@ static void comp_wivrn_flush(struct comp_target * ct) }; { - scoped_lock lock(vk->queue_mutex); + scoped_lock lock(vk->main_queue->mutex); cn->wivrn_bundle->queue.submit(submit_info); } } diff --git a/server/utils/wivrn_vk_bundle.cpp b/server/utils/wivrn_vk_bundle.cpp index 088f77c3..425787fa 100644 --- a/server/utils/wivrn_vk_bundle.cpp +++ b/server/utils/wivrn_vk_bundle.cpp @@ -89,11 +89,11 @@ wivrn::wivrn_vk_bundle::wivrn_vk_bundle(vk_bundle & vk, std::span .vulkanApiVersion = VK_MAKE_VERSION(1, 3, 0), // FIXME: sync with wivrn_session.cpp }, vk.has_EXT_debug_utils), - queue(device, vk.main_queue.family_index, vk.main_queue.index), - queue_family_index(vk.main_queue.family_index), + queue(device, vk.main_queue->family_index, vk.main_queue->index), + queue_family_index(vk.main_queue->family_index), #ifdef VK_KHR_video_encode_queue - encode_queue(make_queue(device, vk.encode_queue.queue, vk.encode_queue.family_index, vk.encode_queue.index)), - encode_queue_family_index(vk.encode_queue.family_index), + encode_queue(make_queue(device, vk.encode_queue->queue, vk.encode_queue->family_index, vk.encode_queue->index)), + encode_queue_family_index(vk.encode_queue->family_index), #else encode_queue(nullptr), encode_queue_family_index(vk::QueueFamilyIgnored),