aboutsummaryrefslogtreecommitdiff
path: root/src/Ryujinx.HLE/HOS/Services/Spl
diff options
context:
space:
mode:
Diffstat (limited to 'src/Ryujinx.HLE/HOS/Services/Spl')
-rw-r--r--src/Ryujinx.HLE/HOS/Services/Spl/IGeneralInterface.cs14
-rw-r--r--src/Ryujinx.HLE/HOS/Services/Spl/IRandomInterface.cs6
-rw-r--r--src/Ryujinx.HLE/HOS/Services/Spl/ResultCode.cs6
-rw-r--r--src/Ryujinx.HLE/HOS/Services/Spl/Types/ConfigItem.cs34
-rw-r--r--src/Ryujinx.HLE/HOS/Services/Spl/Types/DramId.cs4
-rw-r--r--src/Ryujinx.HLE/HOS/Services/Spl/Types/HardwareState.cs4
-rw-r--r--src/Ryujinx.HLE/HOS/Services/Spl/Types/HardwareType.cs2
-rw-r--r--src/Ryujinx.HLE/HOS/Services/Spl/Types/SmcResult.cs23
8 files changed, 46 insertions, 47 deletions
diff --git a/src/Ryujinx.HLE/HOS/Services/Spl/IGeneralInterface.cs b/src/Ryujinx.HLE/HOS/Services/Spl/IGeneralInterface.cs
index aa350b73..951ed530 100644
--- a/src/Ryujinx.HLE/HOS/Services/Spl/IGeneralInterface.cs
+++ b/src/Ryujinx.HLE/HOS/Services/Spl/IGeneralInterface.cs
@@ -58,8 +58,10 @@ namespace Ryujinx.HLE.HOS.Services.Spl
{
configValue = default;
- SystemVersion version = context.Device.System.ContentManager.GetCurrentFirmwareVersion();
- MemorySize memorySize = context.Device.Configuration.MemoryConfiguration.ToKernelMemorySize();
+#pragma warning disable IDE0059 // Remove unnecessary value assignment
+ SystemVersion version = context.Device.System.ContentManager.GetCurrentFirmwareVersion();
+#pragma warning restore IDE0059
+ MemorySize memorySize = context.Device.Configuration.MemoryConfiguration.ToKernelMemorySize();
switch (configItem)
{
@@ -80,9 +82,9 @@ namespace Ryujinx.HLE.HOS.Services.Spl
configValue = (ulong)DramId.IcosaSamsung4GiB;
}
break;
- case ConfigItem.SecurityEngineInterruptNumber:
+ case ConfigItem.SecurityEngineInterruptNumber:
return SmcResult.NotImplemented;
- case ConfigItem.FuseVersion:
+ case ConfigItem.FuseVersion:
return SmcResult.NotImplemented;
case ConfigItem.HardwareType:
configValue = (ulong)HardwareType.Icosa;
@@ -93,7 +95,7 @@ namespace Ryujinx.HLE.HOS.Services.Spl
case ConfigItem.IsRecoveryBoot:
configValue = 0;
break;
- case ConfigItem.DeviceId:
+ case ConfigItem.DeviceId:
return SmcResult.NotImplemented;
case ConfigItem.BootReason:
// This was removed in firmware 4.0.0.
@@ -123,4 +125,4 @@ namespace Ryujinx.HLE.HOS.Services.Spl
return SmcResult.Success;
}
}
-} \ No newline at end of file
+}
diff --git a/src/Ryujinx.HLE/HOS/Services/Spl/IRandomInterface.cs b/src/Ryujinx.HLE/HOS/Services/Spl/IRandomInterface.cs
index db224163..922fd34a 100644
--- a/src/Ryujinx.HLE/HOS/Services/Spl/IRandomInterface.cs
+++ b/src/Ryujinx.HLE/HOS/Services/Spl/IRandomInterface.cs
@@ -5,9 +5,7 @@ namespace Ryujinx.HLE.HOS.Services.Spl
[Service("csrng")]
class IRandomInterface : DisposableIpcService
{
- private RandomNumberGenerator _rng;
-
- private readonly object _lock = new();
+ private readonly RandomNumberGenerator _rng;
public IRandomInterface(ServiceCtx context)
{
@@ -35,4 +33,4 @@ namespace Ryujinx.HLE.HOS.Services.Spl
}
}
}
-} \ No newline at end of file
+}
diff --git a/src/Ryujinx.HLE/HOS/Services/Spl/ResultCode.cs b/src/Ryujinx.HLE/HOS/Services/Spl/ResultCode.cs
index 4f61998a..fe77c753 100644
--- a/src/Ryujinx.HLE/HOS/Services/Spl/ResultCode.cs
+++ b/src/Ryujinx.HLE/HOS/Services/Spl/ResultCode.cs
@@ -2,11 +2,11 @@ namespace Ryujinx.HLE.HOS.Services.Spl
{
enum ResultCode
{
- ModuleId = 26,
+ ModuleId = 26,
ErrorCodeShift = 9,
Success = 0,
- InvalidArguments = (101 << ErrorCodeShift) | ModuleId
+ InvalidArguments = (101 << ErrorCodeShift) | ModuleId,
}
-} \ No newline at end of file
+}
diff --git a/src/Ryujinx.HLE/HOS/Services/Spl/Types/ConfigItem.cs b/src/Ryujinx.HLE/HOS/Services/Spl/Types/ConfigItem.cs
index f08bbeaa..6822ad13 100644
--- a/src/Ryujinx.HLE/HOS/Services/Spl/Types/ConfigItem.cs
+++ b/src/Ryujinx.HLE/HOS/Services/Spl/Types/ConfigItem.cs
@@ -3,22 +3,22 @@
enum ConfigItem
{
// Standard config items.
- DisableProgramVerification = 1,
- DramId = 2,
+ DisableProgramVerification = 1,
+ DramId = 2,
SecurityEngineInterruptNumber = 3,
- FuseVersion = 4,
- HardwareType = 5,
- HardwareState = 6,
- IsRecoveryBoot = 7,
- DeviceId = 8,
- BootReason = 9,
- MemoryMode = 10,
- IsDevelopmentFunctionEnabled = 11,
- KernelConfiguration = 12,
- IsChargerHiZModeEnabled = 13,
- QuestState = 14,
- RegulatorType = 15,
- DeviceUniqueKeyGeneration = 16,
- Package2Hash = 17
+ FuseVersion = 4,
+ HardwareType = 5,
+ HardwareState = 6,
+ IsRecoveryBoot = 7,
+ DeviceId = 8,
+ BootReason = 9,
+ MemoryMode = 10,
+ IsDevelopmentFunctionEnabled = 11,
+ KernelConfiguration = 12,
+ IsChargerHiZModeEnabled = 13,
+ QuestState = 14,
+ RegulatorType = 15,
+ DeviceUniqueKeyGeneration = 16,
+ Package2Hash = 17,
}
-} \ No newline at end of file
+}
diff --git a/src/Ryujinx.HLE/HOS/Services/Spl/Types/DramId.cs b/src/Ryujinx.HLE/HOS/Services/Spl/Types/DramId.cs
index 422c8d69..05a46557 100644
--- a/src/Ryujinx.HLE/HOS/Services/Spl/Types/DramId.cs
+++ b/src/Ryujinx.HLE/HOS/Services/Spl/Types/DramId.cs
@@ -30,6 +30,6 @@
IowaMicron1y4GiB,
HoagMicron1y4GiB,
AulaMicron1y4GiB,
- AulaSamsung1y8GiBX
+ AulaSamsung1y8GiBX,
}
-} \ No newline at end of file
+}
diff --git a/src/Ryujinx.HLE/HOS/Services/Spl/Types/HardwareState.cs b/src/Ryujinx.HLE/HOS/Services/Spl/Types/HardwareState.cs
index 414d0f11..8ab0ba9b 100644
--- a/src/Ryujinx.HLE/HOS/Services/Spl/Types/HardwareState.cs
+++ b/src/Ryujinx.HLE/HOS/Services/Spl/Types/HardwareState.cs
@@ -3,6 +3,6 @@
enum HardwareState
{
Development,
- Production
+ Production,
}
-} \ No newline at end of file
+}
diff --git a/src/Ryujinx.HLE/HOS/Services/Spl/Types/HardwareType.cs b/src/Ryujinx.HLE/HOS/Services/Spl/Types/HardwareType.cs
index 491eb943..82d73330 100644
--- a/src/Ryujinx.HLE/HOS/Services/Spl/Types/HardwareType.cs
+++ b/src/Ryujinx.HLE/HOS/Services/Spl/Types/HardwareType.cs
@@ -9,4 +9,4 @@
Calcio,
Aula
}
-} \ No newline at end of file
+}
diff --git a/src/Ryujinx.HLE/HOS/Services/Spl/Types/SmcResult.cs b/src/Ryujinx.HLE/HOS/Services/Spl/Types/SmcResult.cs
index d5f424a6..ade0378c 100644
--- a/src/Ryujinx.HLE/HOS/Services/Spl/Types/SmcResult.cs
+++ b/src/Ryujinx.HLE/HOS/Services/Spl/Types/SmcResult.cs
@@ -2,19 +2,18 @@
{
enum SmcResult
{
- Success = 0,
- NotImplemented = 1,
- InvalidArgument = 2,
- Busy = 3,
- NoAsyncOperation = 4,
+ Success = 0,
+ NotImplemented = 1,
+ InvalidArgument = 2,
+ Busy = 3,
+ NoAsyncOperation = 4,
InvalidAsyncOperation = 5,
- NotPermitted = 6,
- NotInitialized = 7,
+ NotPermitted = 6,
+ NotInitialized = 7,
- PsciSuccess = 0,
- PsciNotSupported = -1,
+ PsciNotSupported = -1,
PsciInvalidParameters = -2,
- PsciDenied = -3,
- PsciAlreadyOn = -4
+ PsciDenied = -3,
+ PsciAlreadyOn = -4,
}
-} \ No newline at end of file
+}