From ccbdba7ee2ccb835306de89a6023134fa6b8006f Mon Sep 17 00:00:00 2001 From: Tom Englund Date: Fri, 21 Mar 2025 20:19:53 +0100 Subject: syncobj: refactor point timelines (#9689) no need to store the resource, just store the csynctimeline as a shared pointer and make the timeline own the syncobj fd. --- src/helpers/sync/SyncTimeline.hpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/helpers/sync/SyncTimeline.hpp') diff --git a/src/helpers/sync/SyncTimeline.hpp b/src/helpers/sync/SyncTimeline.hpp index bfd70416..a2422149 100644 --- a/src/helpers/sync/SyncTimeline.hpp +++ b/src/helpers/sync/SyncTimeline.hpp @@ -17,7 +17,7 @@ struct wl_event_source; class CSyncTimeline { public: static SP create(int drmFD_); - static SP create(int drmFD_, int drmSyncobjFD); + static SP create(int drmFD_, Hyprutils::OS::CFileDescriptor&& drmSyncobjFD); ~CSyncTimeline(); struct SWaiter { @@ -40,7 +40,8 @@ class CSyncTimeline { bool transfer(SP from, uint64_t fromPoint, uint64_t toPoint); void signal(uint64_t point); - int drmFD = -1; + int drmFD = -1; + Hyprutils::OS::CFileDescriptor syncobjFd; uint32_t handle = 0; WP self; -- cgit v1.2.3