time: Implement GetStandardUserSystemClock, GetCurrentTime.

This commit is contained in:
bunnei 2018-01-14 21:42:23 -05:00
parent d81a984d4a
commit 7bedea73a8
6 changed files with 121 additions and 1 deletions

View file

@ -25,6 +25,7 @@
#include "core/hle/service/service.h"
#include "core/hle/service/sm/controller.h"
#include "core/hle/service/sm/sm.h"
#include "core/hle/service/time/time.h"
#include "core/hle/service/vi/vi.h"
using Kernel::ClientPort;
@ -79,7 +80,8 @@ Kernel::SharedPtr<Kernel::ClientPort> ServiceFrameworkBase::CreatePort() {
ASSERT(port == nullptr);
Kernel::SharedPtr<Kernel::ServerPort> server_port;
Kernel::SharedPtr<Kernel::ClientPort> client_port;
std::tie(server_port, client_port) = Kernel::ServerPort::CreatePortPair(max_sessions, service_name);
std::tie(server_port, client_port) =
Kernel::ServerPort::CreatePortPair(max_sessions, service_name);
port = MakeResult<Kernel::SharedPtr<Kernel::ServerPort>>(std::move(server_port)).Unwrap();
port->SetHleHandler(shared_from_this());
return client_port;
@ -170,6 +172,7 @@ void Init() {
LM::InstallInterfaces(*SM::g_service_manager);
NVDRV::InstallInterfaces(*SM::g_service_manager);
PCTL::InstallInterfaces(*SM::g_service_manager);
Time::InstallInterfaces(*SM::g_service_manager);
VI::InstallInterfaces(*SM::g_service_manager);
LOG_DEBUG(Service, "initialized OK");