summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/core/CMakeLists.txt2
-rw-r--r--src/core/hle/service/eupld/eupld.cpp52
-rw-r--r--src/core/hle/service/eupld/eupld.h16
-rw-r--r--src/core/hle/service/service.cpp2
4 files changed, 72 insertions, 0 deletions
diff --git a/src/core/CMakeLists.txt b/src/core/CMakeLists.txt
index 755a8a7ee..856abc97e 100644
--- a/src/core/CMakeLists.txt
+++ b/src/core/CMakeLists.txt
@@ -140,6 +140,8 @@ add_library(core STATIC
140 hle/service/erpt/erpt.h 140 hle/service/erpt/erpt.h
141 hle/service/es/es.cpp 141 hle/service/es/es.cpp
142 hle/service/es/es.h 142 hle/service/es/es.h
143 hle/service/eupld/eupld.cpp
144 hle/service/eupld/eupld.h
143 hle/service/fatal/fatal.cpp 145 hle/service/fatal/fatal.cpp
144 hle/service/fatal/fatal.h 146 hle/service/fatal/fatal.h
145 hle/service/fatal/fatal_p.cpp 147 hle/service/fatal/fatal_p.cpp
diff --git a/src/core/hle/service/eupld/eupld.cpp b/src/core/hle/service/eupld/eupld.cpp
new file mode 100644
index 000000000..2df30acee
--- /dev/null
+++ b/src/core/hle/service/eupld/eupld.cpp
@@ -0,0 +1,52 @@
1// Copyright 2018 yuzu emulator team
2// Licensed under GPLv2 or any later version
3// Refer to the license.txt file included.
4
5#include <memory>
6
7#include "core/hle/service/eupld/eupld.h"
8#include "core/hle/service/service.h"
9#include "core/hle/service/sm/sm.h"
10
11namespace Service::EUPLD {
12
13class ErrorUploadContext final : public ServiceFramework<ErrorUploadContext> {
14public:
15 explicit ErrorUploadContext() : ServiceFramework{"eupld:c"} {
16 // clang-format off
17 static const FunctionInfo functions[] = {
18 {0, nullptr, "SetUrl"},
19 {1, nullptr, "ImportCrt"},
20 {2, nullptr, "ImportPki"},
21 {3, nullptr, "SetAutoUpload"},
22 };
23 // clang-format on
24
25 RegisterHandlers(functions);
26 }
27};
28
29class ErrorUploadRequest final : public ServiceFramework<ErrorUploadRequest> {
30public:
31 explicit ErrorUploadRequest() : ServiceFramework{"eupld:r"} {
32 // clang-format off
33 static const FunctionInfo functions[] = {
34 {0, nullptr, "Initialize"},
35 {1, nullptr, "UploadAll"},
36 {2, nullptr, "UploadSelected"},
37 {3, nullptr, "GetUploadStatus"},
38 {4, nullptr, "CancelUpload"},
39 {5, nullptr, "GetResult"},
40 };
41 // clang-format on
42
43 RegisterHandlers(functions);
44 }
45};
46
47void InstallInterfaces(SM::ServiceManager& sm) {
48 std::make_shared<ErrorUploadContext>()->InstallAsService(sm);
49 std::make_shared<ErrorUploadRequest>()->InstallAsService(sm);
50}
51
52} // namespace Service::EUPLD
diff --git a/src/core/hle/service/eupld/eupld.h b/src/core/hle/service/eupld/eupld.h
new file mode 100644
index 000000000..6eef2c15f
--- /dev/null
+++ b/src/core/hle/service/eupld/eupld.h
@@ -0,0 +1,16 @@
1// Copyright 2018 yuzu emulator team
2// Licensed under GPLv2 or any later version
3// Refer to the license.txt file included.
4
5#pragma once
6
7namespace Service::SM {
8class ServiceManager;
9}
10
11namespace Service::EUPLD {
12
13/// Registers all EUPLD services with the specified service manager.
14void InstallInterfaces(SM::ServiceManager& sm);
15
16} // namespace Service::EUPLD
diff --git a/src/core/hle/service/service.cpp b/src/core/hle/service/service.cpp
index 1f17ee7c8..84340a40b 100644
--- a/src/core/hle/service/service.cpp
+++ b/src/core/hle/service/service.cpp
@@ -23,6 +23,7 @@
23#include "core/hle/service/bcat/bcat.h" 23#include "core/hle/service/bcat/bcat.h"
24#include "core/hle/service/erpt/erpt.h" 24#include "core/hle/service/erpt/erpt.h"
25#include "core/hle/service/es/es.h" 25#include "core/hle/service/es/es.h"
26#include "core/hle/service/eupld/eupld.h"
26#include "core/hle/service/fatal/fatal.h" 27#include "core/hle/service/fatal/fatal.h"
27#include "core/hle/service/filesystem/filesystem.h" 28#include "core/hle/service/filesystem/filesystem.h"
28#include "core/hle/service/friend/friend.h" 29#include "core/hle/service/friend/friend.h"
@@ -191,6 +192,7 @@ void Init(std::shared_ptr<SM::ServiceManager>& sm) {
191 Audio::InstallInterfaces(*sm); 192 Audio::InstallInterfaces(*sm);
192 ERPT::InstallInterfaces(*sm); 193 ERPT::InstallInterfaces(*sm);
193 ES::InstallInterfaces(*sm); 194 ES::InstallInterfaces(*sm);
195 EUPLD::InstallInterfaces(*sm);
194 Fatal::InstallInterfaces(*sm); 196 Fatal::InstallInterfaces(*sm);
195 FileSystem::InstallInterfaces(*sm); 197 FileSystem::InstallInterfaces(*sm);
196 Friend::InstallInterfaces(*sm); 198 Friend::InstallInterfaces(*sm);