diff options
author | Liam <byteslice@airmail.cc> | 2022-10-16 07:53:56 +0200 |
---|---|---|
committer | Liam <byteslice@airmail.cc> | 2022-10-31 22:44:06 +0100 |
commit | 983f2b70741f17f30fe2321451f10cabecc013d2 (patch) | |
tree | c1ac3c1033fdeefaabe76590ca204c4c1b2a98cd /src/core/hle/kernel/kernel.h | |
parent | Merge pull request #9159 from liamwhite/kbork (diff) | |
download | yuzu-983f2b70741f17f30fe2321451f10cabecc013d2.tar yuzu-983f2b70741f17f30fe2321451f10cabecc013d2.tar.gz yuzu-983f2b70741f17f30fe2321451f10cabecc013d2.tar.bz2 yuzu-983f2b70741f17f30fe2321451f10cabecc013d2.tar.lz yuzu-983f2b70741f17f30fe2321451f10cabecc013d2.tar.xz yuzu-983f2b70741f17f30fe2321451f10cabecc013d2.tar.zst yuzu-983f2b70741f17f30fe2321451f10cabecc013d2.zip |
Diffstat (limited to 'src/core/hle/kernel/kernel.h')
-rw-r--r-- | src/core/hle/kernel/kernel.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/core/hle/kernel/kernel.h b/src/core/hle/kernel/kernel.h index 266be2bc4..670f93ee3 100644 --- a/src/core/hle/kernel/kernel.h +++ b/src/core/hle/kernel/kernel.h @@ -45,6 +45,7 @@ class KPort; class KProcess; class KResourceLimit; class KScheduler; +class KServerPort; class KServerSession; class KSession; class KSessionRequest; @@ -63,6 +64,8 @@ class TimeManager; using ServiceInterfaceFactory = std::function<KClientPort&(Service::SM::ServiceManager&, Core::System&)>; +using ServiceInterfaceHandlerFn = std::function<void(Service::SM::ServiceManager&, KServerPort*)>; + namespace Init { struct KSlabResourceCounts; } @@ -192,9 +195,15 @@ public: /// Registers a named HLE service, passing a factory used to open a port to that service. void RegisterNamedService(std::string name, ServiceInterfaceFactory&& factory); + /// Registers a setup function for the named HLE service. + void RegisterInterfaceForNamedService(std::string name, ServiceInterfaceHandlerFn&& handler); + /// Opens a port to a service previously registered with RegisterNamedService. KClientPort* CreateNamedServicePort(std::string name); + /// Accepts a session on a port created by CreateNamedServicePort. + void RegisterNamedServiceHandler(std::string name, KServerPort* server_port); + /// Registers a server session or port with the gobal emulation state, to be freed on shutdown. /// This is necessary because we do not emulate processes for HLE sessions and ports. void RegisterServerObject(KAutoObject* server_object); |