diff options
| author | 2018-04-14 21:21:34 -0400 | |
|---|---|---|
| committer | 2018-04-14 21:21:34 -0400 | |
| commit | 778be45103b43d3f08018201461c05aba442db3d (patch) | |
| tree | 0d42bcb90faa3838f3e8b7e1dfdccc95faef3490 /src | |
| parent | Merge pull request #329 from bunnei/shader-gen-part-1 (diff) | |
| parent | fsp_srv: Implement IFile::Flush. (diff) | |
| download | yuzu-778be45103b43d3f08018201461c05aba442db3d.tar.gz yuzu-778be45103b43d3f08018201461c05aba442db3d.tar.xz yuzu-778be45103b43d3f08018201461c05aba442db3d.zip | |
Merge pull request #331 from bunnei/fsp-flush
fsp_srv: Implement IFile::Flush.
Diffstat (limited to 'src')
| -rw-r--r-- | src/core/hle/service/filesystem/fsp_srv.cpp | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/core/hle/service/filesystem/fsp_srv.cpp b/src/core/hle/service/filesystem/fsp_srv.cpp index 48c45b1b4..458210a55 100644 --- a/src/core/hle/service/filesystem/fsp_srv.cpp +++ b/src/core/hle/service/filesystem/fsp_srv.cpp | |||
| @@ -73,7 +73,7 @@ public: | |||
| 73 | : ServiceFramework("IFile"), backend(std::move(backend)) { | 73 | : ServiceFramework("IFile"), backend(std::move(backend)) { |
| 74 | static const FunctionInfo functions[] = { | 74 | static const FunctionInfo functions[] = { |
| 75 | {0, &IFile::Read, "Read"}, {1, &IFile::Write, "Write"}, | 75 | {0, &IFile::Read, "Read"}, {1, &IFile::Write, "Write"}, |
| 76 | {2, nullptr, "Flush"}, {3, &IFile::SetSize, "SetSize"}, | 76 | {2, &IFile::Flush, "Flush"}, {3, &IFile::SetSize, "SetSize"}, |
| 77 | {4, &IFile::GetSize, "GetSize"}, {5, nullptr, "OperateRange"}, | 77 | {4, &IFile::GetSize, "GetSize"}, {5, nullptr, "OperateRange"}, |
| 78 | }; | 78 | }; |
| 79 | RegisterHandlers(functions); | 79 | RegisterHandlers(functions); |
| @@ -152,6 +152,14 @@ private: | |||
| 152 | rb.Push(RESULT_SUCCESS); | 152 | rb.Push(RESULT_SUCCESS); |
| 153 | } | 153 | } |
| 154 | 154 | ||
| 155 | void Flush(Kernel::HLERequestContext& ctx) { | ||
| 156 | LOG_DEBUG(Service_FS, "called"); | ||
| 157 | backend->Flush(); | ||
| 158 | |||
| 159 | IPC::ResponseBuilder rb{ctx, 2}; | ||
| 160 | rb.Push(RESULT_SUCCESS); | ||
| 161 | } | ||
| 162 | |||
| 155 | void SetSize(Kernel::HLERequestContext& ctx) { | 163 | void SetSize(Kernel::HLERequestContext& ctx) { |
| 156 | IPC::RequestParser rp{ctx}; | 164 | IPC::RequestParser rp{ctx}; |
| 157 | const u64 size = rp.Pop<u64>(); | 165 | const u64 size = rp.Pop<u64>(); |