diff options
author | Morph <39850852+Morph1984@users.noreply.github.com> | 2022-09-26 03:20:36 +0200 |
---|---|---|
committer | Morph <39850852+Morph1984@users.noreply.github.com> | 2022-09-26 03:33:36 +0200 |
commit | 41e855bd427e07ade6b9292e12bbe5a7c4e76a69 (patch) | |
tree | a270ca94eabc45a52af899e70c1d72e8ab5b18be /src/core/hle/service/vi/vi.cpp | |
parent | service: vi: Move VI results into its own file (diff) | |
download | yuzu-41e855bd427e07ade6b9292e12bbe5a7c4e76a69.tar yuzu-41e855bd427e07ade6b9292e12bbe5a7c4e76a69.tar.gz yuzu-41e855bd427e07ade6b9292e12bbe5a7c4e76a69.tar.bz2 yuzu-41e855bd427e07ade6b9292e12bbe5a7c4e76a69.tar.lz yuzu-41e855bd427e07ade6b9292e12bbe5a7c4e76a69.tar.xz yuzu-41e855bd427e07ade6b9292e12bbe5a7c4e76a69.tar.zst yuzu-41e855bd427e07ade6b9292e12bbe5a7c4e76a69.zip |
Diffstat (limited to 'src/core/hle/service/vi/vi.cpp')
-rw-r--r-- | src/core/hle/service/vi/vi.cpp | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/src/core/hle/service/vi/vi.cpp b/src/core/hle/service/vi/vi.cpp index 0a347a0e9..f083811ec 100644 --- a/src/core/hle/service/vi/vi.cpp +++ b/src/core/hle/service/vi/vi.cpp @@ -671,19 +671,23 @@ private: IPC::RequestParser rp{ctx}; const u64 display_id = rp.Pop<u64>(); - LOG_WARNING(Service_VI, "(STUBBED) called. display_id=0x{:016X}", display_id); + LOG_DEBUG(Service_VI, "called. display_id={}", display_id); const auto vsync_event = nv_flinger.FindVsyncEvent(display_id); - if (!vsync_event) { - LOG_ERROR(Service_VI, "Vsync event was not found for display_id={}", display_id); + if (vsync_event.Failed()) { + const auto result = vsync_event.Code(); + if (result == ResultNotFound) { + LOG_ERROR(Service_VI, "Vsync event was not found for display_id={}", display_id); + } + IPC::ResponseBuilder rb{ctx, 2}; - rb.Push(ResultNotFound); + rb.Push(result); return; } IPC::ResponseBuilder rb{ctx, 2, 1}; rb.Push(ResultSuccess); - rb.PushCopyObjects(vsync_event); + rb.PushCopyObjects(*vsync_event); } void ConvertScalingMode(Kernel::HLERequestContext& ctx) { |