aboutsummaryrefslogtreecommitdiff
path: root/Ryujinx.Core
diff options
context:
space:
mode:
authorgdkchan <gab.dark.100@gmail.com>2018-03-13 21:24:17 -0300
committergdkchan <gab.dark.100@gmail.com>2018-03-13 21:24:32 -0300
commit2ed24af756f60391dade07ac371a2cf630628eb3 (patch)
tree12aae4ef51461f908ca32384b8a8172df1025fcc /Ryujinx.Core
parent4d90d60119992556b28cde119e9a94b8ac4aebf8 (diff)
Add pl:u stub, use higher precision on CNTPCT_EL0 register tick count
Diffstat (limited to 'Ryujinx.Core')
-rw-r--r--Ryujinx.Core/OsHle/Process.cs3
-rw-r--r--Ryujinx.Core/OsHle/Services/Pl/ServicePl.cs8
-rw-r--r--Ryujinx.Core/OsHle/Services/Pl/SharedFontType.cs12
3 files changed, 23 insertions, 0 deletions
diff --git a/Ryujinx.Core/OsHle/Process.cs b/Ryujinx.Core/OsHle/Process.cs
index a8719e1c..239b1980 100644
--- a/Ryujinx.Core/OsHle/Process.cs
+++ b/Ryujinx.Core/OsHle/Process.cs
@@ -17,6 +17,8 @@ namespace Ryujinx.Core.OsHle
private const int TlsSize = 0x200;
private const int TotalTlsSlots = 32;
+ private const int TickFreq = 19_200_000;
+
private Switch Ns;
public bool NeedsHbAbi { get; private set; }
@@ -197,6 +199,7 @@ namespace Ryujinx.Core.OsHle
Thread.ThreadState.Undefined += UndefinedHandler;
Thread.ThreadState.ProcessId = ProcessId;
Thread.ThreadState.ThreadId = ThreadId;
+ Thread.ThreadState.CntfrqEl0 = TickFreq;
Thread.ThreadState.Tpidr = Tpidr;
Thread.ThreadState.X0 = (ulong)ArgsPtr;
Thread.ThreadState.X1 = (ulong)Handle;
diff --git a/Ryujinx.Core/OsHle/Services/Pl/ServicePl.cs b/Ryujinx.Core/OsHle/Services/Pl/ServicePl.cs
index bb795f3f..9a617799 100644
--- a/Ryujinx.Core/OsHle/Services/Pl/ServicePl.cs
+++ b/Ryujinx.Core/OsHle/Services/Pl/ServicePl.cs
@@ -13,6 +13,7 @@ namespace Ryujinx.Core.OsHle.IpcServices.Pl
{
m_Commands = new Dictionary<int, ServiceProcessRequest>()
{
+ { 0, RequestLoad },
{ 1, GetLoadState },
{ 2, GetFontSize },
{ 3, GetSharedMemoryAddressOffset },
@@ -20,6 +21,13 @@ namespace Ryujinx.Core.OsHle.IpcServices.Pl
};
}
+ public long RequestLoad(ServiceCtx Context)
+ {
+ SharedFontType FontType = (SharedFontType)Context.RequestData.ReadInt32();
+
+ return 0;
+ }
+
public long GetLoadState(ServiceCtx Context)
{
Context.ResponseData.Write(1); //Loaded
diff --git a/Ryujinx.Core/OsHle/Services/Pl/SharedFontType.cs b/Ryujinx.Core/OsHle/Services/Pl/SharedFontType.cs
new file mode 100644
index 00000000..29fe02b8
--- /dev/null
+++ b/Ryujinx.Core/OsHle/Services/Pl/SharedFontType.cs
@@ -0,0 +1,12 @@
+namespace Ryujinx.Core.OsHle.IpcServices.Pl
+{
+ enum SharedFontType
+ {
+ JapanUsEurope = 0,
+ SimplifiedChinese = 1,
+ SimplifiedChineseEx = 2,
+ TraditionalChinese = 3,
+ Korean = 4,
+ NintendoEx = 5
+ }
+} \ No newline at end of file