aboutsummaryrefslogtreecommitdiff
path: root/Ryujinx.Core/OsHle/Services
diff options
context:
space:
mode:
authoremmauss <emmausssss@gmail.com>2018-04-14 04:02:24 +0300
committergdkchan <gab.dark.100@gmail.com>2018-04-13 22:02:24 -0300
commitbbcad307bdb8edca121ef6e3d2b13196fdd96a2d (patch)
treefc67010d2fc210fe041829f894659e30d48ac4b8 /Ryujinx.Core/OsHle/Services
parent435f9ffad8b87ae29f1735a200a5838e961163bd (diff)
Add logclass, made changes to logging calls (#79)
* add logclass, made changes to logging calls * made enum parsing case insensitive * enable logclass on partial or complete match
Diffstat (limited to 'Ryujinx.Core/OsHle/Services')
-rw-r--r--Ryujinx.Core/OsHle/Services/Am/IApplicationFunctions.cs2
-rw-r--r--Ryujinx.Core/OsHle/Services/Aud/IAudioOut.cs4
-rw-r--r--Ryujinx.Core/OsHle/Services/Bsd/IClient.cs2
-rw-r--r--Ryujinx.Core/OsHle/Services/IpcService.cs2
-rw-r--r--Ryujinx.Core/OsHle/Services/Lm/ILogger.cs10
-rw-r--r--Ryujinx.Core/OsHle/Services/Nv/INvDrvServices.cs14
-rw-r--r--Ryujinx.Core/OsHle/Services/Vi/NvFlinger.cs6
7 files changed, 20 insertions, 20 deletions
diff --git a/Ryujinx.Core/OsHle/Services/Am/IApplicationFunctions.cs b/Ryujinx.Core/OsHle/Services/Am/IApplicationFunctions.cs
index 29e363be..ba41727e 100644
--- a/Ryujinx.Core/OsHle/Services/Am/IApplicationFunctions.cs
+++ b/Ryujinx.Core/OsHle/Services/Am/IApplicationFunctions.cs
@@ -58,7 +58,7 @@ namespace Ryujinx.Core.OsHle.Services.Am
int Module = ErrorCode & 0xFF;
int Description = (ErrorCode >> 9) & 0xFFF;
- Logging.Info($"({(ErrorModule)Module}){2000 + Module}-{Description}");
+ Logging.Info(LogClass.ServiceAm, $"({(ErrorModule)Module}){2000 + Module}-{Description}");
return 0;
}
diff --git a/Ryujinx.Core/OsHle/Services/Aud/IAudioOut.cs b/Ryujinx.Core/OsHle/Services/Aud/IAudioOut.cs
index b194e76c..527b6532 100644
--- a/Ryujinx.Core/OsHle/Services/Aud/IAudioOut.cs
+++ b/Ryujinx.Core/OsHle/Services/Aud/IAudioOut.cs
@@ -124,14 +124,14 @@ namespace Ryujinx.Core.OsHle.Services.Aud
public long AppendAudioOutBufferEx(ServiceCtx Context)
{
- Logging.Warn("Not implemented!");
+ Logging.Warn(LogClass.ServiceAudio, "Not implemented!");
return 0;
}
public long GetReleasedAudioOutBufferEx(ServiceCtx Context)
{
- Logging.Warn("Not implemented!");
+ Logging.Warn(LogClass.ServiceAudio, "Not implemented!");
return 0;
}
diff --git a/Ryujinx.Core/OsHle/Services/Bsd/IClient.cs b/Ryujinx.Core/OsHle/Services/Bsd/IClient.cs
index 199ea113..ccfb9147 100644
--- a/Ryujinx.Core/OsHle/Services/Bsd/IClient.cs
+++ b/Ryujinx.Core/OsHle/Services/Bsd/IClient.cs
@@ -428,7 +428,7 @@ namespace Ryujinx.Core.OsHle.Services.Bsd
Reader.ReadByte().ToString() + "." +
Reader.ReadByte().ToString();
- Logging.Debug($"Try to connect to {IpAddress}:{Port}");
+ Logging.Debug(LogClass.ServiceBsd, $"Try to connect to {IpAddress}:{Port}");
Sockets[SocketId].IpAddress = IPAddress.Parse(IpAddress);
Sockets[SocketId].RemoteEP = new IPEndPoint(Sockets[SocketId].IpAddress, Port);
diff --git a/Ryujinx.Core/OsHle/Services/IpcService.cs b/Ryujinx.Core/OsHle/Services/IpcService.cs
index 963c7022..f39adb7a 100644
--- a/Ryujinx.Core/OsHle/Services/IpcService.cs
+++ b/Ryujinx.Core/OsHle/Services/IpcService.cs
@@ -81,7 +81,7 @@ namespace Ryujinx.Core.OsHle.Services
{
Context.ResponseData.BaseStream.Seek(IsDomain ? 0x20 : 0x10, SeekOrigin.Begin);
- Logging.Trace($"{Service.GetType().Name}: {ProcessRequest.Method.Name}");
+ Logging.Trace(LogClass.KernelIpc, $"{Service.GetType().Name}: {ProcessRequest.Method.Name}");
long Result = ProcessRequest(Context);
diff --git a/Ryujinx.Core/OsHle/Services/Lm/ILogger.cs b/Ryujinx.Core/OsHle/Services/Lm/ILogger.cs
index 9a0b1aa3..6d3de79b 100644
--- a/Ryujinx.Core/OsHle/Services/Lm/ILogger.cs
+++ b/Ryujinx.Core/OsHle/Services/Lm/ILogger.cs
@@ -129,11 +129,11 @@ namespace Ryujinx.Core.OsHle.Services.Lm
switch((Severity)iSeverity)
{
- case Severity.Trace: Logging.Trace(LogString); break;
- case Severity.Info: Logging.Info(LogString); break;
- case Severity.Warning: Logging.Warn(LogString); break;
- case Severity.Error: Logging.Error(LogString); break;
- case Severity.Critical: Logging.Fatal(LogString); break;
+ case Severity.Trace: Logging.Trace(LogClass.ServiceLm, LogString); break;
+ case Severity.Info: Logging.Info(LogClass.ServiceLm, LogString); break;
+ case Severity.Warning: Logging.Warn(LogClass.ServiceLm, LogString); break;
+ case Severity.Error: Logging.Error(LogClass.ServiceLm, LogString); break;
+ case Severity.Critical: Logging.Fatal(LogClass.ServiceLm, LogString); break;
}
return 0;
diff --git a/Ryujinx.Core/OsHle/Services/Nv/INvDrvServices.cs b/Ryujinx.Core/OsHle/Services/Nv/INvDrvServices.cs
index abda5b86..cc5f95cd 100644
--- a/Ryujinx.Core/OsHle/Services/Nv/INvDrvServices.cs
+++ b/Ryujinx.Core/OsHle/Services/Nv/INvDrvServices.cs
@@ -228,7 +228,7 @@ namespace Ryujinx.Core.OsHle.Services.Nv
if (Map == null)
{
- Logging.Warn($"Trying to use invalid NvMap Handle {Handle}!");
+ Logging.Warn(LogClass.ServiceNv, $"Trying to use invalid NvMap Handle {Handle}!");
return -1; //TODO: Corrent error code.
}
@@ -634,7 +634,7 @@ namespace Ryujinx.Core.OsHle.Services.Nv
Context.Memory.WriteInt32(Position + 4, Map.Handle);
- Logging.Info($"NvMap {Map.Id} created with size {Size:x8}!");
+ Logging.Info(LogClass.ServiceNv, $"NvMap {Map.Id} created with size {Size:x8}!");
return 0;
}
@@ -649,7 +649,7 @@ namespace Ryujinx.Core.OsHle.Services.Nv
if (Map == null)
{
- Logging.Warn($"Trying to use invalid NvMap Id {Id}!");
+ Logging.Warn(LogClass.ServiceNv, $"Trying to use invalid NvMap Id {Id}!");
return -1; //TODO: Corrent error code.
}
@@ -676,7 +676,7 @@ namespace Ryujinx.Core.OsHle.Services.Nv
if (Map == null)
{
- Logging.Warn($"Trying to use invalid NvMap Handle {Handle}!");
+ Logging.Warn(LogClass.ServiceNv, $"Trying to use invalid NvMap Handle {Handle}!");
return -1; //TODO: Corrent error code.
}
@@ -702,7 +702,7 @@ namespace Ryujinx.Core.OsHle.Services.Nv
if (Map == null)
{
- Logging.Warn($"Trying to use invalid NvMap Handle {Handle}!");
+ Logging.Warn(LogClass.ServiceNv, $"Trying to use invalid NvMap Handle {Handle}!");
return -1; //TODO: Corrent error code.
}
@@ -727,7 +727,7 @@ namespace Ryujinx.Core.OsHle.Services.Nv
if (Map == null)
{
- Logging.Warn($"Trying to use invalid NvMap Handle {Handle}!");
+ Logging.Warn(LogClass.ServiceNv, $"Trying to use invalid NvMap Handle {Handle}!");
return -1; //TODO: Corrent error code.
}
@@ -757,7 +757,7 @@ namespace Ryujinx.Core.OsHle.Services.Nv
if (Map == null)
{
- Logging.Warn($"Trying to use invalid NvMap Handle {Handle}!");
+ Logging.Warn(LogClass.ServiceNv, $"Trying to use invalid NvMap Handle {Handle}!");
return -1; //TODO: Corrent error code.
}
diff --git a/Ryujinx.Core/OsHle/Services/Vi/NvFlinger.cs b/Ryujinx.Core/OsHle/Services/Vi/NvFlinger.cs
index 4ab64e2a..3ba4a45f 100644
--- a/Ryujinx.Core/OsHle/Services/Vi/NvFlinger.cs
+++ b/Ryujinx.Core/OsHle/Services/Vi/NvFlinger.cs
@@ -112,7 +112,7 @@ namespace Ryujinx.Core.OsHle.Services.Android
if (Commands.TryGetValue((InterfaceName, Code), out ServiceProcessParcel ProcReq))
{
- Logging.Debug($"{InterfaceName} {ProcReq.Method.Name}");
+ Logging.Debug(LogClass.ServiceNv, $"{InterfaceName} {ProcReq.Method.Name}");
return ProcReq(Context, Reader);
}
@@ -412,7 +412,7 @@ namespace Ryujinx.Core.OsHle.Services.Android
break;
}
- Logging.Debug("Waiting for a free BufferQueue slot...");
+ Logging.Debug(LogClass.ServiceNv, "Waiting for a free BufferQueue slot...");
if (Disposed)
{
@@ -426,7 +426,7 @@ namespace Ryujinx.Core.OsHle.Services.Android
}
while (!Disposed);
- Logging.Debug($"Found free BufferQueue slot {Slot}!");
+ Logging.Debug(LogClass.ServiceNv, $"Found free BufferQueue slot {Slot}!");
return Slot;
}