diff options
author | Fernando Sahmkow <fsahmkow27@gmail.com> | 2019-06-19 02:53:21 +0200 |
---|---|---|
committer | FernandoS27 <fsahmkow27@gmail.com> | 2019-07-05 21:49:32 +0200 |
commit | d20ede40b1e9cd0539982fb1feb3b13af3501ea2 (patch) | |
tree | a084fedd90a6a3cc3e11b099f4ddfe194d49c8ea /src/video_core/gpu.h | |
parent | NVFlinger: Correct GCC compile error (diff) | |
download | yuzu-d20ede40b1e9cd0539982fb1feb3b13af3501ea2.tar yuzu-d20ede40b1e9cd0539982fb1feb3b13af3501ea2.tar.gz yuzu-d20ede40b1e9cd0539982fb1feb3b13af3501ea2.tar.bz2 yuzu-d20ede40b1e9cd0539982fb1feb3b13af3501ea2.tar.lz yuzu-d20ede40b1e9cd0539982fb1feb3b13af3501ea2.tar.xz yuzu-d20ede40b1e9cd0539982fb1feb3b13af3501ea2.tar.zst yuzu-d20ede40b1e9cd0539982fb1feb3b13af3501ea2.zip |
Diffstat (limited to 'src/video_core/gpu.h')
-rw-r--r-- | src/video_core/gpu.h | 18 |
1 files changed, 7 insertions, 11 deletions
diff --git a/src/video_core/gpu.h b/src/video_core/gpu.h index 94afc91f8..334dec48c 100644 --- a/src/video_core/gpu.h +++ b/src/video_core/gpu.h @@ -168,20 +168,16 @@ public: /// Returns a reference to the GPU DMA pusher. Tegra::DmaPusher& DmaPusher(); - void IncrementSyncPoint(const u32 syncpoint_id); + void IncrementSyncPoint(u32 syncpoint_id); - u32 GetSyncpointValue(const u32 syncpoint_id) const; + u32 GetSyncpointValue(u32 syncpoint_id) const; - void RegisterSyncptInterrupt(const u32 syncpoint_id, const u32 value); + void RegisterSyncptInterrupt(u32 syncpoint_id, u32 value); - bool CancelSyncptInterrupt(const u32 syncpoint_id, const u32 value); + bool CancelSyncptInterrupt(u32 syncpoint_id, u32 value); - void Guard(bool guard_set) { - if (guard_set) { - sync_mutex.lock(); - } else { - sync_mutex.unlock(); - } + std::unique_lock<std::mutex> LockSync() { + return std::unique_lock{sync_mutex}; } bool IsAsync() const { @@ -253,7 +249,7 @@ public: virtual void FlushAndInvalidateRegion(CacheAddr addr, u64 size) = 0; protected: - virtual void TriggerCpuInterrupt(const u32 syncpoint_id, const u32 value) const = 0; + virtual void TriggerCpuInterrupt(u32 syncpoint_id, u32 value) const = 0; private: void ProcessBindMethod(const MethodCall& method_call); |