diff options
author | mailwl <mailwl@gmail.com> | 2016-11-20 06:50:48 +0100 |
---|---|---|
committer | mailwl <mailwl@gmail.com> | 2016-11-30 07:51:14 +0100 |
commit | 5b136aa21198dc98296bde3dd393bfc5468d7703 (patch) | |
tree | 49e48570abc750b3f51e4e5c57ec98fba52c3229 /src/core/hle/service/fs | |
parent | Merge pull request #2233 from Subv/warnings (diff) | |
download | yuzu-5b136aa21198dc98296bde3dd393bfc5468d7703.tar yuzu-5b136aa21198dc98296bde3dd393bfc5468d7703.tar.gz yuzu-5b136aa21198dc98296bde3dd393bfc5468d7703.tar.bz2 yuzu-5b136aa21198dc98296bde3dd393bfc5468d7703.tar.lz yuzu-5b136aa21198dc98296bde3dd393bfc5468d7703.tar.xz yuzu-5b136aa21198dc98296bde3dd393bfc5468d7703.tar.zst yuzu-5b136aa21198dc98296bde3dd393bfc5468d7703.zip |
Diffstat (limited to 'src/core/hle/service/fs')
-rw-r--r-- | src/core/hle/service/fs/fs_user.cpp | 24 |
1 files changed, 14 insertions, 10 deletions
diff --git a/src/core/hle/service/fs/fs_user.cpp b/src/core/hle/service/fs/fs_user.cpp index 00edc7622..9ec17b395 100644 --- a/src/core/hle/service/fs/fs_user.cpp +++ b/src/core/hle/service/fs/fs_user.cpp @@ -763,23 +763,27 @@ static void CreateLegacySystemSaveData(Service::Interface* self) { * FS_User::InitializeWithSdkVersion service function. * Inputs: * 0 : 0x08610042 - * 1 : Unknown - * 2 : Unknown - * 3 : Unknown + * 1 : Used SDK Version + * 2 : ProcessId Header + * 3 : placeholder for ProcessId * Outputs: * 1 : Result of function, 0 on success, otherwise error code */ static void InitializeWithSdkVersion(Service::Interface* self) { u32* cmd_buff = Kernel::GetCommandBuffer(); - u32 unk1 = cmd_buff[1]; - u32 unk2 = cmd_buff[2]; - u32 unk3 = cmd_buff[3]; + const u32 version = cmd_buff[1]; + self->SetVersion(version); - cmd_buff[1] = RESULT_SUCCESS.raw; - - LOG_WARNING(Service_FS, "(STUBBED) called unk1=0x%08X, unk2=0x%08X, unk3=0x%08X", unk1, unk2, - unk3); + if (cmd_buff[2] == IPC::CallingPidDesc()) { + LOG_WARNING(Service_FS, "(STUBBED) called, version: 0x%08X", version); + cmd_buff[1] = RESULT_SUCCESS.raw; + } else { + LOG_ERROR(Service_FS, "ProcessId Header must be 0x20"); + cmd_buff[1] = ResultCode(ErrorDescription::OS_InvalidBufferDescriptor, ErrorModule::OS, + ErrorSummary::WrongArgument, ErrorLevel::Permanent) + .raw; + } } /** |