From 8824422cf795d825a220f30fc98696c641669c12 Mon Sep 17 00:00:00 2001 From: LotP1 Date: Mon, 20 Jan 2025 21:50:14 +0100 Subject: [PATCH 1/2] fix incorrect rusultcode value --- src/Ryujinx.HLE/HOS/Services/Spl/IGeneralInterface.cs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/Ryujinx.HLE/HOS/Services/Spl/IGeneralInterface.cs b/src/Ryujinx.HLE/HOS/Services/Spl/IGeneralInterface.cs index 4a2a910f8..ade67b9c0 100644 --- a/src/Ryujinx.HLE/HOS/Services/Spl/IGeneralInterface.cs +++ b/src/Ryujinx.HLE/HOS/Services/Spl/IGeneralInterface.cs @@ -51,6 +51,9 @@ namespace Ryujinx.HLE.HOS.Services.Spl context.ResponseData.Write(configValue); + if (result == SmcResult.Success) + return ResultCode.Success; + return (ResultCode)((int)result << 9) | ResultCode.ModuleId; } -- 2.47.1 From f0b3c99ea2a3fc3e8bedf0f06fb005785b01675c Mon Sep 17 00:00:00 2001 From: LotP1 Date: Mon, 20 Jan 2025 21:51:30 +0100 Subject: [PATCH 2/2] implement GetSerialNumber will result a custom, invalid, serial number the serial number does follow the serial number rules --- .../HOS/Services/Settings/ISystemSettingsServer.cs | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/Ryujinx.HLE/HOS/Services/Settings/ISystemSettingsServer.cs b/src/Ryujinx.HLE/HOS/Services/Settings/ISystemSettingsServer.cs index 65748be33..846c4dc4f 100644 --- a/src/Ryujinx.HLE/HOS/Services/Settings/ISystemSettingsServer.cs +++ b/src/Ryujinx.HLE/HOS/Services/Settings/ISystemSettingsServer.cs @@ -244,6 +244,15 @@ namespace Ryujinx.HLE.HOS.Services.Settings return ResultCode.Success; } + [CommandCmif(68)] + // GetSerialNumber() -> buffer + public ResultCode GetSerialNumber(ServiceCtx context) + { + context.ResponseData.Write(Encoding.ASCII.GetBytes("RYU00000000000")); + + return ResultCode.Success; + } + [CommandCmif(77)] // GetDeviceNickName() -> buffer public ResultCode GetDeviceNickName(ServiceCtx context) -- 2.47.1