Address comments
This commit is contained in:
parent
410e401e64
commit
5f447247dd
2 changed files with 5 additions and 6 deletions
|
@ -9,7 +9,7 @@ namespace Ryujinx.HLE.HOS.Services.Bpc
|
||||||
|
|
||||||
[Command(0)]
|
[Command(0)]
|
||||||
// GetRtcTime() -> u64
|
// GetRtcTime() -> u64
|
||||||
public static ResultCode GetRtcTime(ServiceCtx context)
|
public ResultCode GetRtcTime(ServiceCtx context)
|
||||||
{
|
{
|
||||||
ResultCode result = GetExternalRtcValue(out ulong rtcValue);
|
ResultCode result = GetExternalRtcValue(out ulong rtcValue);
|
||||||
|
|
||||||
|
@ -24,9 +24,9 @@ namespace Ryujinx.HLE.HOS.Services.Bpc
|
||||||
public static ResultCode GetExternalRtcValue(out ulong rtcValue)
|
public static ResultCode GetExternalRtcValue(out ulong rtcValue)
|
||||||
{
|
{
|
||||||
// TODO: emulate MAX77620/MAX77812
|
// TODO: emulate MAX77620/MAX77812
|
||||||
DateTime UnixEpoch = new DateTime(1970, 1, 1, 0, 0, 0, DateTimeKind.Utc);
|
DateTime unixEpoch = new DateTime(1970, 1, 1, 0, 0, 0, DateTimeKind.Utc);
|
||||||
|
|
||||||
rtcValue = (ulong)(DateTime.Now.ToUniversalTime() - UnixEpoch).TotalSeconds;
|
rtcValue = (ulong)(DateTime.Now.ToUniversalTime() - unixEpoch).TotalSeconds;
|
||||||
|
|
||||||
return ResultCode.Success;
|
return ResultCode.Success;
|
||||||
}
|
}
|
||||||
|
|
|
@ -29,7 +29,7 @@ namespace Ryujinx.HLE.HOS.Services.Time.Clock
|
||||||
_steadyClockCore = steadyClockCore;
|
_steadyClockCore = steadyClockCore;
|
||||||
_context = new SystemClockContext();
|
_context = new SystemClockContext();
|
||||||
|
|
||||||
_context.SteadyTimePoint.ClockSourceId = steadyClockCore.GetClockSourceId();
|
_context.SteadyTimePoint.ClockSourceId = steadyClockCore.GetClockSourceId();
|
||||||
_standardNetworkClockSufficientAccuracy = new TimeSpanType(0);
|
_standardNetworkClockSufficientAccuracy = new TimeSpanType(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -61,8 +61,7 @@ namespace Ryujinx.HLE.HOS.Services.Time.Clock
|
||||||
|
|
||||||
public bool IsStandardNetworkSystemClockAccuracySufficient(KThread thread)
|
public bool IsStandardNetworkSystemClockAccuracySufficient(KThread thread)
|
||||||
{
|
{
|
||||||
SteadyClockCore steadyClockCore = GetSteadyClockCore();
|
SteadyClockCore steadyClockCore = GetSteadyClockCore();
|
||||||
|
|
||||||
SteadyClockTimePoint currentTimePoint = steadyClockCore.GetCurrentTimePoint(thread);
|
SteadyClockTimePoint currentTimePoint = steadyClockCore.GetCurrentTimePoint(thread);
|
||||||
|
|
||||||
bool isStandardNetworkClockSufficientAccuracy = false;
|
bool isStandardNetworkClockSufficientAccuracy = false;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue