summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorGravatar mailwl2019-09-04 18:43:04 +0300
committerGravatar bunnei2019-09-04 11:43:04 -0400
commita1d48b5f529156c7ab35f1b3e2a15af66e58b15b (patch)
tree2ce1e79689b28d63e249ed9c7c534a8278b66b50 /src
parentMerge pull request #2829 from Morph1984/audio (diff)
downloadyuzu-a1d48b5f529156c7ab35f1b3e2a15af66e58b15b.tar.gz
yuzu-a1d48b5f529156c7ab35f1b3e2a15af66e58b15b.tar.xz
yuzu-a1d48b5f529156c7ab35f1b3e2a15af66e58b15b.zip
AM: Stub IApplicationFunctions::GetGpuErrorDetectedSystemEvent (#2827)
* AM: Implement IApplicationFunctions::GetGpuErrorDetectedSystemEvent * Remove unneeded event clear * Fix event name
Diffstat (limited to 'src')
-rw-r--r--src/core/hle/service/am/am.cpp13
-rw-r--r--src/core/hle/service/am/am.h3
2 files changed, 16 insertions, 0 deletions
diff --git a/src/core/hle/service/am/am.cpp b/src/core/hle/service/am/am.cpp
index a192a1f5f..111633ba3 100644
--- a/src/core/hle/service/am/am.cpp
+++ b/src/core/hle/service/am/am.cpp
@@ -1057,6 +1057,7 @@ IApplicationFunctions::IApplicationFunctions() : ServiceFramework("IApplicationF
1057 {120, nullptr, "ExecuteProgram"}, 1057 {120, nullptr, "ExecuteProgram"},
1058 {121, nullptr, "ClearUserChannel"}, 1058 {121, nullptr, "ClearUserChannel"},
1059 {122, nullptr, "UnpopToUserChannel"}, 1059 {122, nullptr, "UnpopToUserChannel"},
1060 {130, &IApplicationFunctions::GetGpuErrorDetectedSystemEvent, "GetGpuErrorDetectedSystemEvent"},
1060 {500, nullptr, "StartContinuousRecordingFlushForDebug"}, 1061 {500, nullptr, "StartContinuousRecordingFlushForDebug"},
1061 {1000, nullptr, "CreateMovieMaker"}, 1062 {1000, nullptr, "CreateMovieMaker"},
1062 {1001, nullptr, "PrepareForJit"}, 1063 {1001, nullptr, "PrepareForJit"},
@@ -1064,6 +1065,10 @@ IApplicationFunctions::IApplicationFunctions() : ServiceFramework("IApplicationF
1064 // clang-format on 1065 // clang-format on
1065 1066
1066 RegisterHandlers(functions); 1067 RegisterHandlers(functions);
1068
1069 auto& kernel = Core::System::GetInstance().Kernel();
1070 gpu_error_detected_event = Kernel::WritableEvent::CreateEventPair(
1071 kernel, Kernel::ResetType::Manual, "IApplicationFunctions:GpuErrorDetectedSystemEvent");
1067} 1072}
1068 1073
1069IApplicationFunctions::~IApplicationFunctions() = default; 1074IApplicationFunctions::~IApplicationFunctions() = default;
@@ -1285,6 +1290,14 @@ void IApplicationFunctions::GetSaveDataSize(Kernel::HLERequestContext& ctx) {
1285 rb.Push(size.journal); 1290 rb.Push(size.journal);
1286} 1291}
1287 1292
1293void IApplicationFunctions::GetGpuErrorDetectedSystemEvent(Kernel::HLERequestContext& ctx) {
1294 LOG_WARNING(Service_AM, "(STUBBED) called");
1295
1296 IPC::ResponseBuilder rb{ctx, 2, 1};
1297 rb.Push(RESULT_SUCCESS);
1298 rb.PushCopyObjects(gpu_error_detected_event.readable);
1299}
1300
1288void InstallInterfaces(SM::ServiceManager& service_manager, 1301void InstallInterfaces(SM::ServiceManager& service_manager,
1289 std::shared_ptr<NVFlinger::NVFlinger> nvflinger, Core::System& system) { 1302 std::shared_ptr<NVFlinger::NVFlinger> nvflinger, Core::System& system) {
1290 auto message_queue = std::make_shared<AppletMessageQueue>(); 1303 auto message_queue = std::make_shared<AppletMessageQueue>();
diff --git a/src/core/hle/service/am/am.h b/src/core/hle/service/am/am.h
index 6cb582483..cbc9da7b6 100644
--- a/src/core/hle/service/am/am.h
+++ b/src/core/hle/service/am/am.h
@@ -242,6 +242,9 @@ private:
242 void BeginBlockingHomeButton(Kernel::HLERequestContext& ctx); 242 void BeginBlockingHomeButton(Kernel::HLERequestContext& ctx);
243 void EndBlockingHomeButton(Kernel::HLERequestContext& ctx); 243 void EndBlockingHomeButton(Kernel::HLERequestContext& ctx);
244 void EnableApplicationCrashReport(Kernel::HLERequestContext& ctx); 244 void EnableApplicationCrashReport(Kernel::HLERequestContext& ctx);
245 void GetGpuErrorDetectedSystemEvent(Kernel::HLERequestContext& ctx);
246
247 Kernel::EventPair gpu_error_detected_event;
245}; 248};
246 249
247class IHomeMenuFunctions final : public ServiceFramework<IHomeMenuFunctions> { 250class IHomeMenuFunctions final : public ServiceFramework<IHomeMenuFunctions> {