diff options
| author | bunnei <bunneidev@gmail.com> | 2020-05-16 12:39:58 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-05-16 12:39:58 -0400 |
| commit | 65010607b7a474e677360a5a465a3169fec41ba0 (patch) | |
| tree | 1e101dc9ecbfcfdf1da6f848e002dc21df0b3a96 /src/core/hle/service/filesystem/fsp_srv.cpp | |
| parent | 3c378a31b5ed9b6e8c8b5dd1861a81c8e55e75ae (diff) | |
| parent | 47b97b95773e1cf1c4acd387ce4011b34cb67180 (diff) | |
Merge pull request #3665 from bunnei/device-save
FS: Improve emulation of device saves
Diffstat (limited to 'src/core/hle/service/filesystem/fsp_srv.cpp')
| -rw-r--r-- | src/core/hle/service/filesystem/fsp_srv.cpp | 38 |
1 files changed, 37 insertions, 1 deletions
diff --git a/src/core/hle/service/filesystem/fsp_srv.cpp b/src/core/hle/service/filesystem/fsp_srv.cpp index f6503fe2f..20c331b77 100644 --- a/src/core/hle/service/filesystem/fsp_srv.cpp +++ b/src/core/hle/service/filesystem/fsp_srv.cpp @@ -767,7 +767,7 @@ FSP_SRV::FSP_SRV(FileSystemController& fsc, const Core::Reporter& reporter) {1014, nullptr, "OutputMultiProgramTagAccessLog"}, {1100, nullptr, "OverrideSaveDataTransferTokenSignVerificationKey"}, {1110, nullptr, "CorruptSaveDataFileSystemBySaveDataSpaceId2"}, - {1200, nullptr, "OpenMultiCommitManager"}, + {1200, &FSP_SRV::OpenMultiCommitManager, "OpenMultiCommitManager"}, {1300, nullptr, "OpenBisWiper"}, }; // clang-format on @@ -988,4 +988,40 @@ void FSP_SRV::GetAccessLogVersionInfo(Kernel::HLERequestContext& ctx) { rb.Push(access_log_program_index); } +class IMultiCommitManager final : public ServiceFramework<IMultiCommitManager> { +public: + explicit IMultiCommitManager() : ServiceFramework("IMultiCommitManager") { + static const FunctionInfo functions[] = { + {1, &IMultiCommitManager::Add, "Add"}, + {2, &IMultiCommitManager::Commit, "Commit"}, + }; + RegisterHandlers(functions); + } + +private: + FileSys::VirtualFile backend; + + void Add(Kernel::HLERequestContext& ctx) { + LOG_WARNING(Service_FS, "(STUBBED) called"); + + IPC::ResponseBuilder rb{ctx, 2}; + rb.Push(RESULT_SUCCESS); + } + + void Commit(Kernel::HLERequestContext& ctx) { + LOG_WARNING(Service_FS, "(STUBBED) called"); + + IPC::ResponseBuilder rb{ctx, 2}; + rb.Push(RESULT_SUCCESS); + } +}; + +void FSP_SRV::OpenMultiCommitManager(Kernel::HLERequestContext& ctx) { + LOG_DEBUG(Service_FS, "called"); + + IPC::ResponseBuilder rb{ctx, 2, 0, 1}; + rb.Push(RESULT_SUCCESS); + rb.PushIpcInterface<IMultiCommitManager>(std::make_shared<IMultiCommitManager>()); +} + } // namespace Service::FileSystem |
